Introduction

This documentation aims to provide all the information you need to work with our API. Please refer to our documentation How to start with the Magnetis API ?

Authenticating requests

To authenticate requests, include a x-api-key header with the value "{YOUR_AUTH_KEY}".

All authenticated endpoints are marked with a requires authentication badge in the documentation below.

You can retrieve your token by visiting your dashboard and clicking Generate API token.

Alerts

Email alerts


List all email alerts

GET
https://api.magnetis.io
/alerts/email
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX
limit
Optional. Result per page. 250 if not set.
Example:
250
page
Optional. Pagination page. 1 if not set.
Example:
1

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/alerts/email" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [
        {
            "id": "ale-b098cb40-c57b-4a2b-bf5c-70348741ed91",
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "created_at": "2024-03-04 09:06:09",
            "enabled": 1,
            "less_than": 23,
            "more_than": null,
            "recipients": [
                "example@email.fr"
            ],
            "title": "Alerte sur appel personnalisé",
            "type": "custom_calls"
        },
        {
            "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
            "account": {
                "id": "acc-6a29eed8-af46-4a4c-bd4b-e4d44f7b345f",
                "name": "Immobilier tertiaire"
            },
            "created_at": "2024-03-04 09:06:10",
            "enabled": 1,
            "less_than": null,
            "more_than": null,
            "recipients": [
                "example@email.fr"
            ],
            "title": "Alerte sur appel manqué",
            "type": "lost_calls"
        },
        {
            "id": "ale-5f695e85-1508-4365-9ade-56ab6d9b861a",
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "created_at": "2024-03-04 09:06:10",
            "enabled": 1,
            "less_than": null,
            "more_than": null,
            "recipients": [
                "example@email.fr"
            ],
            "title": "Alerte sur tous les appels",
            "type": "all_calls"
        }
    ],
    "links": {
        "first": "https://api.magnetis.io/alerts/email?page=1",
        "last": "https://api.magnetis.io/alerts/email?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "path": "https://api.magnetis.io/alerts/email",
        "per_page": 250,
        "to": 3,
        "total": 3,
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        }
    }
}

Create an email alert

POST
https://api.magnetis.io
/alerts/email
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Response Fields

Example request:
curl --request POST \
    "https://api.magnetis.io/alerts/email" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"account_id\": \"acc-6e64b651-026a-46de-ab3e-944a193945a9\",
    \"title\": \"Alerte sur appel manqué\",
    \"type\": \"custom_calls\",
    \"more_than\": 20,
    \"less_than\": \"\",
    \"enabled\": false,
    \"recipients\": [
        \"amazingemail@email.com\",
        \"thebestemail@email.com\"
    ],
    \"anonymized\": true
}"
Example response:
{
    "data": {
        "id": "ale-b098cb40-c57b-4a2b-bf5c-70348741ed91",
        "account": {
            "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
            "name": "Immobilier tertiaire"
        },
        "created_at": "2024-03-04 09:06:09",
        "enabled": 1,
        "less_than": 23,
        "more_than": null,
        "recipients": [
            "example@email.fr"
        ],
        "title": "Alerte sur appel personnalisé",
        "type": "custom_calls"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2024-03-04 09:12:08",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 3
    }
}

Fetch an email alert

GET
https://api.magnetis.io
/alerts/email/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The id of the alert.

Example:
ale-06529b90-73e1-4f8d-b654-aa1f8116ab41

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/alerts/email/ale-06529b90-73e1-4f8d-b654-aa1f8116ab41" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "id": "ale-b098cb40-c57b-4a2b-bf5c-70348741ed91",
        "account": {
            "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
            "name": "Immobilier tertiaire"
        },
        "created_at": "2024-03-04 09:06:09",
        "enabled": 1,
        "less_than": 23,
        "more_than": null,
        "recipients": [
            "example@email.fr"
        ],
        "title": "Alerte sur appel personnalisé",
        "type": "custom_calls"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2024-03-04 09:12:08",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 3
    }
}

Update an email alert

PUT
PATCH
https://api.magnetis.io
/alerts/email/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The ID of the alert.

Example:
ale-06529b90-73e1-4f8d-b654-aa1f8116ab41

Body Parameters

Response Fields

Example request:
curl --request PUT \
    "https://api.magnetis.io/alerts/email/ale-06529b90-73e1-4f8d-b654-aa1f8116ab41" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"Alerte sur appel manqué\",
    \"type\": \"custom_calls\",
    \"more_than\": 20,
    \"less_than\": \"\",
    \"enabled\": false,
    \"recipients\": [
        \"amazingemail@email.com\",
        \"thebestemail@email.com\"
    ],
    \"anonymized\": false
}"
Example response:
{
    "data": {
        "id": "ale-b098cb40-c57b-4a2b-bf5c-70348741ed91",
        "account": {
            "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
            "name": "Immobilier tertiaire"
        },
        "created_at": "2024-03-04 09:06:09",
        "enabled": 1,
        "less_than": 23,
        "more_than": null,
        "recipients": [
            "example@email.fr"
        ],
        "title": "Alerte sur appel personnalisé",
        "type": "custom_calls"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2024-03-04 09:12:08",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 3
    }
}

Delete an email alert

DELETE
https://api.magnetis.io
/alerts/email/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The ID of the alert.

Example:
ale-06529b90-73e1-4f8d-b654-aa1f8116ab41

Response Fields

Example request:
curl --request DELETE \
    "https://api.magnetis.io/alerts/email/ale-06529b90-73e1-4f8d-b654-aa1f8116ab41" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [],
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 0
    }
}

SMS alerts


List all SMS alerts

GET
https://api.magnetis.io
/alerts/sms
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX
limit
Optional. Result per page. 250 if not set.
Example:
250
page
Optional. Pagination page. 1 if not set.
Example:
1

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/alerts/sms" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [
        {
            "id": "als-cccd40bf-3e4d-42fb-ad5a-76040aa03171",
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "additional_recipients": [
                "rcp-bde9497b-ffe6-45db-8ffc-cd62b4260a59"
            ],
            "all_tracked_numbers": 0,
            "created_at": "2024-03-01 14:52:44",
            "enabled": 1,
            "landing_page": null,
            "less_than": null,
            "more_than": null,
            "notification_emails": [],
            "notification_recipients": [],
            "numbers": [],
            "pools": [],
            "send_to": "caller",
            "sms_template": {
                "id": "sds-a1cc1722-271e-4eb4-b66a-012cb7f3f244",
                "account": {
                    "id": "acc-51ce00db-b50b-4b3d-ad4d-9b19155d46b5",
                    "name": "Immobilier tertiaire"
                },
                "created_at": "2024-03-01 14:52:46",
                "entity": null,
                "from": "InfoAppel",
                "network": null,
                "nb_characters": null,
                "nb_sms": null,
                "text": "Bonjour, merci pour votre appel. Nous sommes actuellement indisponibles, mais vous pouvez nous joindre via notre site internet, www.monsite.fr. A très vite!",
                "title": "Appel Manqué Appelant",
                "user": {
                    "id": "usr-78a51d97-1bd2-467e-b67c-bb683014e84c",
                    "created_at": "2024-03-01T13:52:43.000000Z",
                    "email": "John.Doe@email.fr",
                    "firstname": "John",
                    "lang": "fr",
                    "lastname": "Doe",
                    "phone": "06 38 39 XX XX"
                }
            },
            "title": "Alerte par sms",
            "type": "lost_calls"
        },
        {
            "id": "als-88530b44-7887-4747-88d7-e5da1955ebac",
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "additional_recipients": [
                "rcp-bde9497b-ffe6-45db-8ffc-cd62b4260a59"
            ],
            "all_tracked_numbers": 0,
            "created_at": "2024-03-01 14:52:44",
            "enabled": 1,
            "landing_page": null,
            "less_than": null,
            "more_than": null,
            "notification_emails": [],
            "notification_recipients": [],
            "numbers": [],
            "pools": [],
            "send_to": "caller",
            "sms_template": {
                "id": "sds-a1cc1722-271e-4eb4-b66a-012cb7f3f244",
                "account": {
                    "id": "acc-51ce00db-b50b-4b3d-ad4d-9b19155d46b5",
                    "name": "Immobilier tertiaire"
                },
                "created_at": "2024-03-01 14:52:46",
                "entity": null,
                "from": "InfoAppel",
                "network": null,
                "nb_characters": null,
                "nb_sms": null,
                "text": "Bonjour, merci pour votre appel. Nous sommes actuellement indisponibles, mais vous pouvez nous joindre via notre site internet, www.monsite.fr. A très vite!",
                "title": "Appel Manqué Appelant",
                "user": {
                    "id": "usr-78a51d97-1bd2-467e-b67c-bb683014e84c",
                    "created_at": "2024-03-01T13:52:43.000000Z",
                    "email": "John.Doe@email.fr",
                    "firstname": "John",
                    "lang": "fr",
                    "lastname": "Doe",
                    "phone": "06 38 39 XX XX"
                }
            },
            "title": "Alerte par sms",
            "type": "lost_calls"
        },
        {
            "id": "als-2a709bdd-f7e2-45bd-a86b-12633de528ec",
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "additional_recipients": [
                "rcp-2765bc4d-9f7f-4324-8c83-11262bb4c0fd"
            ],
            "all_tracked_numbers": 0,
            "created_at": "2024-03-01 14:52:44",
            "enabled": 1,
            "landing_page": null,
            "less_than": null,
            "more_than": null,
            "notification_emails": [],
            "notification_recipients": [],
            "numbers": [],
            "pools": [],
            "send_to": "caller",
            "sms_template": {
                "id": "sds-a1cc1722-271e-4eb4-b66a-012cb7f3f244",
                "account": {
                    "id": "acc-51ce00db-b50b-4b3d-ad4d-9b19155d46b5",
                    "name": "Immobilier tertiaire"
                },
                "created_at": "2024-03-01 14:52:46",
                "entity": null,
                "from": "InfoAppel",
                "network": null,
                "nb_characters": null,
                "nb_sms": null,
                "text": "Bonjour, merci pour votre appel. Nous sommes actuellement indisponibles, mais vous pouvez nous joindre via notre site internet, www.monsite.fr. A très vite!",
                "title": "Appel Manqué Appelant",
                "user": {
                    "id": "usr-78a51d97-1bd2-467e-b67c-bb683014e84c",
                    "created_at": "2024-03-01T13:52:43.000000Z",
                    "email": "John.Doe@email.fr",
                    "firstname": "John",
                    "lang": "fr",
                    "lastname": "Doe",
                    "phone": "06 38 39 XX XX"
                }
            },
            "title": "Alerte par sms",
            "type": "lost_calls"
        },
        {
            "id": "als-f3f2849a-e306-4a00-b539-45bc48b95b61",
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "additional_recipients": [],
            "all_tracked_numbers": 1,
            "created_at": "2024-03-07 10:34:09",
            "enabled": 1,
            "landing_page": {
                "id": "8810c59a-c05c-4801-a3e7-c77308296c9c",
                "account": {
                    "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                    "name": "Immobilier tertiaire"
                },
                "created_at": "2024-01-01 01:00:00",
                "entity": null,
                "network": null,
                "title": "Ma Landing Page",
                "url": "https://www.mywebsite.fr"
            },
            "less_than": null,
            "more_than": null,
            "notification_emails": [],
            "notification_recipients": [],
            "numbers": [],
            "pools": [],
            "send_to": "caller",
            "sms_template": {
                "id": "sds-3712da26-d91e-4d9a-8545-2a6a4023231b32",
                "account": {
                    "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                    "name": "Immobilier tertiaire"
                },
                "created_at": "2024-03-01 14:52:46",
                "entity": null,
                "from": "InfoAppel",
                "network": null,
                "nb_characters": 2121,
                "nb_sms": 2,
                "text": "Nous avons raté votre appel, completer le question ##LIENTRACKEVERSLANDPAGE## pour que nous puissions vous recontacter. A bientôt.",
                "title": "Appel Manqué Appelé",
                "user": {
                    "id": "usr-78a51d97-1bd2-467e-b67c-bb683014e84c",
                    "created_at": "2024-03-01 14:52:43",
                    "email": "John.Doe@email.fr",
                    "firstname": "John",
                    "lang": "fr",
                    "lastname": "Doe",
                    "phone": "06 38 39 XX XX"
                }
            },
            "title": "Sms de landing page",
            "type": "lost_calls"
        }
    ],
    "links": {
        "first": "https://api.magnetis.io/alerts/sms?page=1",
        "last": "https://api.magnetis.io/alerts/sms?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "path": "https://api.magnetis.io/alerts/sms",
        "per_page": 250,
        "to": 4,
        "total": 4,
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        }
    }
}

Create a SMS alert

POST
https://api.magnetis.io
/alerts/sms
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The unique ID of the alert.

Example:
als-06529b90-73e1-4f8d-b654-aa1f8116ab41

Body Parameters

Response Fields

Example request:
curl --request POST \
    "https://api.magnetis.io/alerts/sms" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"additional_recipients\": false,
    \"all_tracked_numbers\": false,
    \"enabled\": true,
    \"landing_page_id\": \"ldp-53470c4d-7721-4490-bd22-237066afd5c5\",
    \"less_than\": 15,
    \"more_than\": 17,
    \"notification_emails\": [
        \"amazingemail@email.com\",
        \"thebestemail@email.com\"
    ],
    \"notification_recipients\": [
        \"rcp-8b514c55-f135-48da-83e4-1a1cd3cccb84\",
        \"rcp-75e932ca-6714-4088-b571-e6047a0dd1c6\"
    ],
    \"numbers\": [
        \"num-50700e9e-879e-480a-859a-1db8301bd712\",
        \"num-87b2e273-29c7-41a9-bd7e-66748d9cdf40\"
    ],
    \"pools\": [
        \"pul-50700e9e-879e-480a-859a-1db8301bd712\",
        \"pul-87b2e273-29c7-41a9-bd7e-66748d9cdf40\"
    ],
    \"send_to\": \"caller\",
    \"sms_template_id\": \"sds-8dc0d51c-bd63-4aaf-ab64-6fb46edb17ac\",
    \"title\": \"Alerte avec Landing Page\",
    \"type\": \"custom_calls\",
    \"account_id\": \"acc-6e64b651-026a-46de-ab3e-944a193945a9\"
}"

Fetch a SMS alert

GET
https://api.magnetis.io
/alerts/sms/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The id of the alert.

Example:
als-06529b90-73e1-4f8d-b654-aa1f8116ab41

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/alerts/sms/als-06529b90-73e1-4f8d-b654-aa1f8116ab41" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "id": "als-f3f2849a-e306-4a00-b539-45bc48b95b61",
        "account": {
            "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
            "name": "Immobilier tertiaire"
        },
        "additional_recipients": [],
        "all_tracked_numbers": 1,
        "created_at": "2024-03-07 10:34:09",
        "enabled": 1,
        "landing_page": {
            "id": "8810c59a-c05c-4801-a3e7-c77308296c9c",
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "created_at": "2024-01-01 01:00:00",
            "entity": null,
            "network": null,
            "title": "Ma Landing Page",
            "url": "https://www.mywebsite.fr"
        },
        "less_than": null,
        "more_than": null,
        "notification_emails": [],
        "notification_recipients": [],
        "numbers": [],
        "pools": [],
        "send_to": "caller",
        "sms_template": {
            "id": "sds-3712da26-d91e-4d9a-8545-2a6a4023231b32",
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "created_at": "2024-03-01 14:52:46",
            "entity": null,
            "from": "InfoAppel",
            "network": null,
            "nb_characters": 2121,
            "nb_sms": 2,
            "text": "Nous avons raté votre appel, completer le question ##LIENTRACKEVERSLANDPAGE## pour que nous puissions vous recontacter. A bientôt.",
            "title": "Appel Manqué Appelé",
            "user": {
                "id": "usr-78a51d97-1bd2-467e-b67c-bb683014e84c",
                "created_at": "2024-03-01 14:52:43",
                "email": "John.Doe@email.fr",
                "firstname": "John",
                "lang": "fr",
                "lastname": "Doe",
                "phone": "06 38 39 XX XX"
            }
        },
        "title": "Sms de landing page",
        "type": "lost_calls"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2024-03-04 09:12:08",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Update a SMS alert

PUT
PATCH
https://api.magnetis.io
/alerts/sms/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

Alert ID.

Example:
als-06529b90-73e1-4f8d-b654-aa1f8116ab41

Body Parameters

Response Fields

Example request:
curl --request PUT \
    "https://api.magnetis.io/alerts/sms/als-06529b90-73e1-4f8d-b654-aa1f8116ab41" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"additional_recipients\": false,
    \"all_tracked_numbers\": false,
    \"enabled\": true,
    \"landing_page_id\": \"ldp-53470c4d-7721-4490-bd22-237066afd5c5\",
    \"less_than\": 15,
    \"more_than\": 18,
    \"notification_emails\": [
        \"amazingemail@email.com\",
        \"thebestemail@email.com\"
    ],
    \"notification_recipients\": [
        \"rcp-8b514c55-f135-48da-83e4-1a1cd3cccb84\",
        \"rcp-75e932ca-6714-4088-b571-e6047a0dd1c6\"
    ],
    \"numbers\": [
        \"num-50700e9e-879e-480a-859a-1db8301bd712\",
        \"num-87b2e273-29c7-41a9-bd7e-66748d9cdf40\"
    ],
    \"pools\": [
        \"pul-50700e9e-879e-480a-859a-1db8301bd712\",
        \"pul-87b2e273-29c7-41a9-bd7e-66748d9cdf40\"
    ],
    \"send_to\": \"caller\",
    \"sms_template_id\": \"sds-8dc0d51c-bd63-4aaf-ab64-6fb46edb17ac\",
    \"title\": \"Alerte avec Landing Page\",
    \"type\": \"custom_calls\"
}"
Example response:
{
    "data": {
        "id": "als-f3f2849a-e306-4a00-b539-45bc48b95b61",
        "account": {
            "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
            "name": "Immobilier tertiaire"
        },
        "additional_recipients": [],
        "all_tracked_numbers": 1,
        "created_at": "2024-03-07 10:34:09",
        "enabled": 1,
        "landing_page": {
            "id": "8810c59a-c05c-4801-a3e7-c77308296c9c",
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "created_at": "2024-01-01 01:00:00",
            "entity": null,
            "network": null,
            "title": "Ma Landing Page",
            "url": "https://www.mywebsite.fr"
        },
        "less_than": null,
        "more_than": null,
        "notification_emails": [],
        "notification_recipients": [],
        "numbers": [],
        "pools": [],
        "send_to": "caller",
        "sms_template": {
            "id": "sds-3712da26-d91e-4d9a-8545-2a6a4023231b32",
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "created_at": "2024-03-01 14:52:46",
            "entity": null,
            "from": "InfoAppel",
            "network": null,
            "nb_characters": 2121,
            "nb_sms": 2,
            "text": "Nous avons raté votre appel, completer le question ##LIENTRACKEVERSLANDPAGE## pour que nous puissions vous recontacter. A bientôt.",
            "title": "Appel Manqué Appelé",
            "user": {
                "id": "usr-78a51d97-1bd2-467e-b67c-bb683014e84c",
                "created_at": "2024-03-01 14:52:43",
                "email": "John.Doe@email.fr",
                "firstname": "John",
                "lang": "fr",
                "lastname": "Doe",
                "phone": "06 38 39 XX XX"
            }
        },
        "title": "Sms de landing page",
        "type": "lost_calls"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2024-03-04 09:12:08",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Delete a sms alert

DELETE
https://api.magnetis.io
/alerts/sms/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The id of the alert.

Example:
als-06529b90-73e1-4f8d-b654-aa1f8116ab41

Response Fields

Example request:
curl --request DELETE \
    "https://api.magnetis.io/alerts/sms/als-06529b90-73e1-4f8d-b654-aa1f8116ab41" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [],
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 0
    }
}

Architecture

Organizations


Fetch an organization

GET
https://api.magnetis.io
/organization
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/organization" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "id": "org-206cfd6e-c95e-4aee-9068-164c8539f85a",
    "activity": "Immobilier tertiaire",
    "billing_details": {
        "address": "1 rue de la Mairie",
        "city": "Paris",
        "country": "FRA",
        "billing_email": "comptabilite@mycompany.fr",
        "phone": "0033611223344",
        "siret": "987654321",
        "tva_number": "FR123456789",
        "zipcode": "75001"
    },
    "company": "My company",
    "created_at": "2023-07-25 12:00:00",
    "external_id": "Project ABC",
    "rgpd": 2
}

Update an organization

PUT
PATCH
https://api.magnetis.io
/organization
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Response Fields

Example request:
curl --request PUT \
    "https://api.magnetis.io/organization" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"activity\": \"Automobile\",
    \"external_id\": \"DV-12321\",
    \"rgpd\": 3,
    \"company\": \"Example&Co\",
    \"billing_details\": {
        \"address\": \"691 Impasse Mallet\",
        \"city\": \"Millet-sur-Pires\",
        \"country\": \"FRA\",
        \"billing_email\": \"billing@company.com\",
        \"phone\": \"003393455XXXX\",
        \"siret\": \"123 456 789 00012\",
        \"zipcode\": \"33160\",
        \"tva_number\": \"FR123456789\"
    }
}"
Example response:
{
    "id": "org-206cfd6e-c95e-4aee-9068-164c8539f85a",
    "activity": "Immobilier tertiaire",
    "billing_details": {
        "address": "1 rue de la Mairie",
        "city": "Paris",
        "country": "FRA",
        "billing_email": "comptabilite@mycompany.fr",
        "phone": "0033611223344",
        "siret": "987654321",
        "tva_number": "FR123456789",
        "zipcode": "75001"
    },
    "company": "My company",
    "created_at": "2023-07-25 12:00:00",
    "external_id": "Project ABC",
    "rgpd": 2
}

Get organization architecture

GET
https://api.magnetis.io
/organization/architecture
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/organization/architecture" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:

Networks


List all networks

GET
https://api.magnetis.io
/networks
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

limit
Optional. Result per page. 250 if not set.
Example:
250
page
Optional. Pagination page. 1 if not set.
Example:
1

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/networks" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [
        {
            "id": "net-bd05fbcd-4623-4ba5-b1fd-d586198334f7",
            "activity": "Immobilier tertiaire",
            "created_at": "2323-06-27 10:40:00",
            "name": "Réseau Ile de France",
            "parent_network_id": null,
            "rgpd": 3
        },
        {
            "id": "net-47cd1df6-d252-46af-8c18-32da13aa3d33",
            "activity": "Automobile",
            "created_at": "2323-06-27 10:40:00",
            "name": "Réseau Nord Ouest",
            "parent_network_id": null,
            "rgpd": 3
        },
        {
            "id": "net-204958f3-0665-4205-b08d-b3c300c4e9a2",
            "activity": "Construction",
            "created_at": "2323-06-27 10:40:00",
            "name": "Réseau Sud Est",
            "parent_network_id": null,
            "rgpd": 3
        }
    ],
    "links": {
        "first": "https://api.magnetis.io/networks?page=1",
        "last": "https://api.magnetis.io/networks?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "path": "https://api.magnetis.io/networks",
        "per_page": 250,
        "to": 3,
        "total": 3,
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        }
    }
}

Create a network

POST
https://api.magnetis.io
/networks
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Response Fields

Example request:
curl --request POST \
    "https://api.magnetis.io/networks" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"activity\": \"Automobile\",
    \"parent_network_id\": \"net-XXX\",
    \"name\": \"Point de vente N°1\"
}"
Example response:
{
    "data": {
        "id": "net-bd05fbcd-4623-4ba5-b1fd-d586198334f7",
        "activity": "Immobilier tertiaire",
        "created_at": "2323-06-27 10:40:00",
        "name": "Réseau Ile de France",
        "parent_network_id": null,
        "rgpd": 3
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "network",
            "name": "My network"
        },
        "total": 1
    }
}

Fetch a network

GET
https://api.magnetis.io
/networks/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The id of the network.

Example:
net-f3c61104-d94f-4a5f-8fcb-7a63fcc89a6c

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/networks/1" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "id": "net-bd05fbcd-4623-4ba5-b1fd-d586198334f7",
        "activity": "Immobilier tertiaire",
        "created_at": "2323-06-27 10:40:00",
        "name": "Réseau Ile de France",
        "parent_network_id": null,
        "rgpd": 3
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "network",
            "name": "My network"
        },
        "total": 1
    }
}

Update a network

PUT
PATCH
https://api.magnetis.io
/networks/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The id of the network.

Example:
net-f3c61104-d94f-4a5f-8fcb-7a63fcc89a6c

Body Parameters

Response Fields

Example request:
curl --request PUT \
    "https://api.magnetis.io/networks/1" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"activity\": \"Automobile\",
    \"name\": \"Point de vente N°1\"
}"
Example response:
{
    "data": {
        "id": "net-bd05fbcd-4623-4ba5-b1fd-d586198334f7",
        "activity": "Immobilier tertiaire",
        "created_at": "2323-06-27 10:40:00",
        "name": "Réseau Ile de France",
        "parent_network_id": null,
        "rgpd": 3
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "network",
            "name": "My network"
        },
        "total": 1
    }
}

Remove a network

DELETE
https://api.magnetis.io
/networks/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The id of the network.

Example:
net-f3c61104-d94f-4a5f-8fcb-7a63fcc89a6c

Response Fields

Example request:
curl --request DELETE \
    "https://api.magnetis.io/networks/1" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "id": "net-bd05fbcd-4623-4ba5-b1fd-d586198334f7",
        "activity": "Immobilier tertiaire",
        "created_at": "2323-06-27 10:40:00",
        "name": "Réseau Ile de France",
        "parent_network_id": null,
        "rgpd": 3
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "network",
            "name": "My network"
        },
        "total": 1
    }
}

List all networks children of a network

GET
https://api.magnetis.io
/networks/{network}/networks
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The id of the network.

Example:
net-f3c61104-d94f-4a5f-8fcb-7a63fcc89a6c

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/networks/1/networks" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [
        {
            "id": "net-bd05fbcd-4623-4ba5-b1fd-d586198334f7",
            "activity": "Immobilier tertiaire",
            "created_at": "2323-06-27 10:40:00",
            "name": "Réseau Ile de France",
            "parent_network_id": null,
            "rgpd": 3
        },
        {
            "id": "net-47cd1df6-d252-46af-8c18-32da13aa3d33",
            "activity": "Automobile",
            "created_at": "2323-06-27 10:40:00",
            "name": "Réseau Nord Ouest",
            "parent_network_id": null,
            "rgpd": 3
        },
        {
            "id": "net-204958f3-0665-4205-b08d-b3c300c4e9a2",
            "activity": "Construction",
            "created_at": "2323-06-27 10:40:00",
            "name": "Réseau Sud Est",
            "parent_network_id": null,
            "rgpd": 3
        }
    ],
    "links": {
        "first": "https://api.magnetis.io/networks?page=1",
        "last": "https://api.magnetis.io/networks?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "path": "https://api.magnetis.io/networks",
        "per_page": 250,
        "to": 3,
        "total": 3,
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        }
    }
}

Accounts


List all accounts

GET
https://api.magnetis.io
/accounts
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

limit
Optional. Result per page. 250 if not set.
Example:
250
page
Optional. Pagination page. 1 if not set.
Example:
1

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/accounts" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [
        {
            "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
            "activity": "Immobilier tertiaire",
            "address": {
                "zipcode": "75015",
                "city": "Paris",
                "country": "FRA"
            },
            "created_at": "2023-07-20 13:58:30",
            "name": "Immo Paris",
            "parent_network_id": "net-bd05fbcd-4623-4ba5-b1fd-d586198334f7",
            "rgpd": 1
        },
        {
            "id": "acc-f702dcb6-87cf-4bc4-8632-560c43aec1a4",
            "activity": "Automobile",
            "address": {
                "zipcode": "33000",
                "city": "Bordeaux",
                "country": "FRA"
            },
            "created_at": "2023-07-14 11:52:27",
            "name": "Auto Bordeaux",
            "parent_network_id": null,
            "rgpd": 2
        },
        {
            "id": "acc-250ce1bd-237d-4e2d-aa17-51293760a801",
            "activity": "Construction",
            "address": {
                "zipcode": "69000",
                "city": "Lyon",
                "country": "FRA"
            },
            "created_at": "2023-06-25 07:34:12",
            "name": "Artisan Lyon",
            "parent_network_id": null,
            "rgpd": 3
        }
    ],
    "links": {
        "first": "https://api.magnetis.io/accounts?page=1",
        "last": "https://api.magnetis.io/accounts?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "path": "https://api.magnetis.io/accounts",
        "per_page": 250,
        "to": 3,
        "total": 3,
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        }
    }
}

Create an account

POST
https://api.magnetis.io
/accounts
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Response Fields

Example request:
curl --request POST \
    "https://api.magnetis.io/accounts" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"activity\": \"Automobile\",
    \"city\": \"Paris\",
    \"country\": \"FRA\",
    \"name\": \"My account\",
    \"parent_network_id\": \"net-XXX\",
    \"zipcode\": \"75000\"
}"
Example response:
{
    "data": {
        "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
        "activity": "Immobilier tertiaire",
        "address": {
            "zipcode": "75015",
            "city": "Paris",
            "country": "FRA"
        },
        "created_at": "2023-07-20 13:58:30",
        "name": "Immo Paris",
        "parent_network_id": null,
        "rgpd": 1
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Fetch an account

GET
https://api.magnetis.io
/accounts/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The ID of the account.

Example:
acc-6e64b651-026a-46de-ab3e-944a193945a9

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/accounts/1" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
        "activity": "Immobilier tertiaire",
        "address": {
            "zipcode": "75015",
            "city": "Paris",
            "country": "FRA"
        },
        "created_at": "2023-07-20 13:58:30",
        "name": "Immo Paris",
        "parent_network_id": null,
        "rgpd": 1
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Update an account

PUT
PATCH
https://api.magnetis.io
/accounts/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The id of the account.

Example:
acc-6e64b651-026a-46de-ab3e-944a193945a9

Body Parameters

Response Fields

Example request:
curl --request PUT \
    "https://api.magnetis.io/accounts/1" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"activity\": \"Automobile\",
    \"city\": \"Paris\",
    \"country\": \"FRA\",
    \"name\": \"My account\",
    \"parent_network_id\": \"net-XXX\",
    \"rgpd\": \"2\",
    \"zipcode\": \"75000\"
}"
Example response:
{
    "data": {
        "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
        "activity": "Immobilier tertiaire",
        "address": {
            "zipcode": "75015",
            "city": "Paris",
            "country": "FRA"
        },
        "created_at": "2023-07-20 13:58:30",
        "name": "Immo Paris",
        "parent_network_id": null,
        "rgpd": 1
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Delete an account

DELETE
https://api.magnetis.io
/accounts/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The id of the account.

Example:
acc-6e64b651-026a-46de-ab3e-944a193945a9

Response Fields

Example request:
curl --request DELETE \
    "https://api.magnetis.io/accounts/1" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
        "activity": "Immobilier tertiaire",
        "address": {
            "zipcode": "75015",
            "city": "Paris",
            "country": "FRA"
        },
        "created_at": "2023-07-20 13:58:30",
        "name": "Immo Paris",
        "parent_network_id": null,
        "rgpd": 1
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Authentication

Get API key informations

GET
https://api.magnetis.io
/auth
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/auth" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
        "created_at": "2023-07-25 12:00:00",
        "expiration": null,
        "level": "account",
        "name": "My account"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Calls

List all calls

GET
https://api.magnetis.io
/calls
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

actions
Optional. Allows you to display post-call actions when equals to 1.
Example:
1
calling_number
Optional. Calling number filter at international format.
Example:
0033612345678
date_basis
Optional. determine whether the date range is based on the start or end date. Enum: start,end. Default: start
Example:
start
from
Optional. From date. 7 days ago if not set.
Example:
20230601000000
limit
Optional. Result per page. 250 if not set.
Example:
250
number_id
Optional. Filter by number ID.
Example:
num-XXX
page
Optional. Pagination page. 1 if not set.
Example:
1
sort
Optional. Determines in what order calls are returned. Enum: asc, desc. Default: desc
Example:
desc
to
Optional. To date. Now if not set.
Example:
20230607235959
urls
Optional. Allows you to display visitor URLs when equals to 1.
Example:
1

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/calls" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [
        {
            "id": "call-0c5ac87f-6d8b-4e94-9ce2-f4773bced2f5",
            "account": {
                "id": "acc-efd1bbeb-afbb-4895-a6d5-40a13558af49",
                "name": "My account"
            },
            "calling_country": "FRA",
            "calling_number": "0033612345678",
            "calling_type": "mobile",
            "channel_name": "Google Ads",
            "channel_type": "googleads",
            "date": "2023-08-30 13:57:30",
            "duration": 43,
            "end_date": "2023-08-30 13:58:13",
            "end_status": "completed",
            "events": [
                {
                    "date": "2023-08-30 13:57:30",
                    "name": "call:in",
                    "value": null
                },
                {
                    "date": "2023-08-30 13:57:31",
                    "name": "call:out",
                    "value": "0033687654321"
                },
                {
                    "date": "2023-08-30 13:57:33",
                    "name": "call:ringing",
                    "value": "0033687654321"
                },
                {
                    "date": "2023-08-30 13:57:48",
                    "name": "call:answered",
                    "value": "0033687654321"
                },
                {
                    "date": "2023-08-30 13:58:13",
                    "name": "call:completed",
                    "value": "no-answer"
                }
            ],
            "firsttime_caller": true,
            "flow_status": "completed",
            "google_ads_extension": null,
            "missed": false,
            "number_id": "num-18dd0fdb-7f21-4999-9335-a5d50d8c716e",
            "pool_id": "pul-c8c7912c-5e3e-4b19-8769-4daadea66dea",
            "recipient_number": "0033687654321",
            "tracked_country": "FRA",
            "tracked_number": "0033412345678",
            "tracked_type": "geographic",
            "voice_duration": 43,
            "visitor": {
                "condition_name": "Google Ads",
                "condition_type": "google_ads",
                "custom_cookies": [],
                "custom_local_storage": [],
                "custom_params": [],
                "custom_variables": [],
                "ga": "GA1.1.12345678.87654321",
                "gclid": "EAIaIQobChER4_LZnaeJ4gIV3EdFFh2raA5aEAAYAiAAEgKyCF3_BwE",
                "gbraid": null,
                "msclkid": null,
                "utm": [
                    {
                        "key": "utm_source",
                        "value": "googleads"
                    }
                ],
                "valuetrack": [],
                "wbraid": null,
                "3rdparty": []
            }
        },
        {
            "id": "call-a9dec6da-1fdf-4e33-ba0e-e7c8d20e1edb",
            "account": {
                "id": "acc-efd1bbeb-afbb-4895-a6d5-40a13558af49",
                "name": "My account"
            },
            "calling_country": "FRA",
            "calling_number": "0033911774499",
            "calling_type": "geographic",
            "channel_name": "SEO",
            "channel_type": "seo",
            "date": "2023-08-30 10:05:53",
            "duration": 302,
            "end_date": "2023-08-30 10:10:55",
            "end_status": "completed",
            "events": [
                {
                    "date": "2023-08-30 10:05:53",
                    "name": "call:in",
                    "value": null
                },
                {
                    "date": "2023-08-30 10:05:54",
                    "name": "call:out",
                    "value": "0033687654321"
                },
                {
                    "date": "2023-08-30 10:05:55",
                    "name": "call:ringing",
                    "value": "0033687654321"
                },
                {
                    "date": "2023-08-30 10:06:03",
                    "name": "call:answered",
                    "value": "0033687654321"
                },
                {
                    "date": "2023-08-30 10:10:55",
                    "name": "call:completed",
                    "value": "completed"
                }
            ],
            "firsttime_caller": false,
            "flow_status": "completed",
            "google_ads_extension": null,
            "missed": false,
            "number_id": "num-583a97ac-eeef-4d18-bede-56c67e29c1cb",
            "pool_id": null,
            "recipient_number": "0033687654321",
            "tracked_country": "FRA",
            "tracked_number": "0033488554422",
            "tracked_type": "geographic",
            "voice_duration": 292,
            "visitor": null
        },
        {
            "id": "call-b7831876-641f-43c3-b70f-5f51a2750a14",
            "account": {
                "id": "acc-efd1bbeb-afbb-4895-a6d5-40a13558af49",
                "name": "My account"
            },
            "calling_country": "FRA",
            "calling_number": "0033643215678",
            "calling_type": "mobile",
            "channel_name": "Extensions Google Ads",
            "channel_type": "googleadsextension",
            "date": "2023-08-30 09:30:05",
            "duration": 5,
            "end_date": "2023-08-30 09:30:10",
            "end_status": "no-answer",
            "events": [
                {
                    "date": "2023-08-30 09:30:05",
                    "name": "call:in",
                    "value": null
                },
                {
                    "date": "2023-08-30 09:30:06",
                    "name": "call:out",
                    "value": "0033687654321"
                },
                {
                    "date": "2023-08-30 09:30:07",
                    "name": "call:ringing",
                    "value": "0033687654321"
                },
                {
                    "date": "2023-08-30 09:30:10",
                    "name": "call:completed",
                    "value": "completed"
                }
            ],
            "firsttime_caller": true,
            "flow_status": "completed",
            "google_ads_extension": {
                "customer_id": "123-456-7890",
                "customer_name": "My Google Ads account",
                "campaign_id": "123456789012",
                "campaign_name": "My campaign",
                "ad_group_id": "098765432109",
                "ad_group_name": "My ad group"
            },
            "missed": true,
            "number_id": "num-0c1aa069-896b-44b1-83c9-a41c3ea6daa9",
            "pool_id": null,
            "recipient_number": "0033644332211",
            "tracked_country": "FRA",
            "tracked_number": "0033411223344",
            "tracked_type": "geographic",
            "voice_duration": 5,
            "visitor": null
        }
    ],
    "links": {
        "first": "https://api.magnetis.io/calls?page=1",
        "last": "https://api.magnetis.io/calls?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "path": "https://api.magnetis.io/calls",
        "per_page": 500,
        "to": 3,
        "total": 3,
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        }
    }
}

Fetch a call

GET
https://api.magnetis.io
/calls/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The ID of the call.

Example:
call-50e4003c-e072-4b3d-b0db-ef8dd9a2949a
actions
Optional. Allows you to display post-call actions when equals to 1.
Example:
1

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/calls/call-50e4003c-e072-4b3d-b0db-ef8dd9a2949a" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "id": "call-0c5ac87f-6d8b-4e94-9ce2-f4773bced2f5",
        "account": {
            "id": "acc-efd1bbeb-afbb-4895-a6d5-40a13558af49",
            "name": "My account"
        },
        "calling_country": "FRA",
        "calling_number": "0033612345678",
        "calling_type": "mobile",
        "channel_name": "Google Ads",
        "channel_type": "googleads",
        "date": "2023-08-30 13:57:30",
        "duration": 43,
        "end_date": "2023-08-30 13:58:13",
        "end_status": "completed",
        "events": [
            {
                "date": "2023-08-30 13:57:30",
                "name": "call:in",
                "value": null
            },
            {
                "date": "2023-08-30 13:57:31",
                "name": "call:out",
                "value": "0033687654321"
            },
            {
                "date": "2023-08-30 13:57:33",
                "name": "call:ringing",
                "value": "0033687654321"
            },
            {
                "date": "2023-08-30 13:57:48",
                "name": "call:answered",
                "value": "0033687654321"
            },
            {
                "date": "2023-08-30 13:58:13",
                "name": "call:completed",
                "value": "no-answer"
            }
        ],
        "firsttime_caller": true,
        "flow_status": "completed",
        "google_ads_extension": null,
        "missed": false,
        "number_id": "num-18dd0fdb-7f21-4999-9335-a5d50d8c716e",
        "pool_id": "pul-c8c7912c-5e3e-4b19-8769-4daadea66dea",
        "recipient_number": "0033687654321",
        "tracked_country": "FRA",
        "tracked_number": "0033412345678",
        "tracked_type": "geographic",
        "voice_duration": 43,
        "visitor": {
            "condition_name": "Google Ads",
            "condition_type": "google_ads",
            "custom_cookies": [],
            "custom_local_storage": [],
            "custom_params": [],
            "custom_variables": [],
            "ga": "GA1.1.12345678.87654321",
            "gclid": "EAIaIQobChER4_LZnaeJ4gIV3EdFFh2raA5aEAAYAiAAEgKyCF3_BwE",
            "gbraid": null,
            "msclkid": null,
            "utm": [
                {
                    "key": "utm_source",
                    "value": "googleads"
                }
            ],
            "valuetrack": [],
            "wbraid": null,
            "3rdparty": []
        }
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Google Ads Conversions


Create conversion action

POST
https://api.magnetis.io
/calls/conversion_action
requires authentication

This endpoint allows you to create a conversion action in your Google Ads account. The category of the conversion action will be CONVERTED_LEAD. The type of the conversion action depends on the type you chose. UPLOAD_CLICKS if visitor, UPLOAD_CALLS if extension.

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Response Fields

Example request:
curl --request POST \
    "https://api.magnetis.io/calls/conversion_action" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"email\": \"john.doe@gmail.com\",
    \"google_ads_account_id\": \"123-456-7890\",
    \"conversion_action_name\": \"Rendez-vous qualifié\",
    \"type\": \"visitor\"
}"
Example response:
{
    "error": "Confirmation message",
    "data": []
}

Upload extension call conversion

POST
https://api.magnetis.io
/calls/{id}/extension_conversion
requires authentication

This endpoint allows you to upload a call coming from your tracked call extension numbers in Google Ads.

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The ID of the call.

Example:
call-50e4003c-e072-4b3d-b0db-ef8dd9a2949a

Body Parameters

Response Fields

Example request:
curl --request POST \
    "https://api.magnetis.io/calls/call-50e4003c-e072-4b3d-b0db-ef8dd9a2949a/extension_conversion" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"conversion_action\": \"Rendez-vous qualifié\",
    \"value\": \"0\"
}"
Example response:
{
    "error": "Confirmation message",
    "data": []
}

Upload visitor call conversion

POST
https://api.magnetis.io
/calls/{id}/visitor_conversion
requires authentication

This endpoint allows you to upload a call coming from a visitor of your website in Google Ads.

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The ID of the call.

Example:
call-50e4003c-e072-4b3d-b0db-ef8dd9a2949a

Body Parameters

Response Fields

Example request:
curl --request POST \
    "https://api.magnetis.io/calls/call-50e4003c-e072-4b3d-b0db-ef8dd9a2949a/visitor_conversion" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"conversion_action\": \"Rendez-vous qualifié\",
    \"value\": \"0\"
}"
Example response:
{
    "error": "Confirmation message",
    "data": []
}

Update visitor call conversion

PUT
https://api.magnetis.io
/calls/{id}/visitor_conversion
requires authentication

This endpoint allows you to update the value of a conversion having been uploaded previously.

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The ID of the call.

Example:
call-50e4003c-e072-4b3d-b0db-ef8dd9a2949a

Body Parameters

Response Fields

Example request:
curl --request PUT \
    "https://api.magnetis.io/calls/call-50e4003c-e072-4b3d-b0db-ef8dd9a2949a/visitor_conversion" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"conversion_action\": \"Rendez-vous qualifié\",
    \"value\": \"0\"
}"
Example response:
{
    "error": "Confirmation message",
    "data": []
}

Delete visitor call conversion

DELETE
https://api.magnetis.io
/calls/{id}/visitor_conversion
requires authentication

This endpoint allows you to remove a conversion having been uploaded previously.

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The ID of the call.

Example:
call-50e4003c-e072-4b3d-b0db-ef8dd9a2949a

Body Parameters

Response Fields

Example request:
curl --request DELETE \
    "https://api.magnetis.io/calls/call-50e4003c-e072-4b3d-b0db-ef8dd9a2949a/visitor_conversion" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"conversion_action\": \"Rendez-vous qualifié\"
}"
Example response:
{
    "error": "Confirmation message",
    "data": []
}

Email-tracking

Emails


List all received emails

GET
https://api.magnetis.io
/emails
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

from
Optional. From date. 7 days ago if not set.
Example:
20230601000000
limit
Optional. Result per page. 250 if not set.
Example:
250
page
Optional. Pagination page. 1 if not set.
Example:
1
to
Optional. To date. Now if not set.
Example:
20230607235959
type
Optional. Email filter: match, unmatch, all. Match if not set.
Example:
match

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/emails" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [
        {
            "id": "etm-4908be34-1489-4806-85f6-11bf12ea13ce",
            "account": {
                "id": "acc-250ce1bd-237d-4e2d-aa17-51293760a801",
                "name": "Artisan Lyon"
            },
            "channel_name": "LeBonCoin",
            "channel_type": "leboncoin",
            "date": "2023-09-25 14:50:12",
            "from_email": "jane.doe@gmail.com",
            "from_name": "Jane Doe",
            "is_spam": false,
            "lead": {
                "id": "lead-9c6187a3-9865-418d-be80-e45d5990f039",
                "call_id": null,
                "created_at": "2023-09-25 14:50:12",
                "email_id": "etm-4908be34-1489-4806-85f6-11bf12ea13ce",
                "fields": {
                    "firstname": "Jane",
                    "lastname": "Doe",
                    "phone": null,
                    "email": "jane.doe@gmail.com",
                    "zipcode": null
                },
                "landing_page": {
                    "title": null,
                    "url": null
                },
                "source": "email"
            },
            "subject": "Nouveau message sur votre annonce",
            "tracked_email": "acc.99999.track@mgtmail.fr",
            "to": "entreprise@monemail.com"
        },
        {
            "id": "etm-1775b79c-95b0-41f3-844a-3bb2437b25d1",
            "account": {
                "id": "acc-66db2b07-073e-40ca-ab82-cc9b7e652bd0",
                "name": "Artisan Lille"
            },
            "channel_name": "Se Loger",
            "channel_type": "seloger",
            "date": "2023-09-25 14:50:12",
            "from_email": "john@gmail.com",
            "from_name": "John Doe",
            "is_spam": false,
            "lead": null,
            "subject": "Nouveau prospect",
            "tracked_email": "acc.99998.track@mgtmail.fr",
            "to": "entreprise@monemail.com"
        }
    ],
    "links": {
        "first": "https://api.magnetis.io/emails?page=1",
        "last": "https://api.magnetis.io/emails?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "path": "https://api.magnetis.io/emails",
        "per_page": 250,
        "to": 2,
        "total": 2,
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        }
    }
}

Fetch a received email

GET
https://api.magnetis.io
/emails/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The id of the email.

Example:
etm-49a6306b-64c6-4c48-89a1-5ea572231fc3

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/emails/1" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "id": "etm-4908be34-1489-4806-85f6-11bf12ea13ce",
        "account": {
            "id": "acc-250ce1bd-237d-4e2d-aa17-51293760a801",
            "name": "Artisan Lyon"
        },
        "channel_name": "LeBonCoin",
        "channel_type": "leboncoin",
        "date": "2023-09-25 14:50:12",
        "from_email": "jane.doe@gmail.com",
        "from_name": "Jane Doe",
        "is_spam": false,
        "lead": {
            "id": "lead-9c6187a3-9865-418d-be80-e45d5990f039",
            "call_id": null,
            "created_at": "2023-09-25 14:50:12",
            "email_id": "etm-4908be34-1489-4806-85f6-11bf12ea13ce",
            "fields": {
                "firstname": "Jane",
                "lastname": "Doe",
                "phone": null,
                "email": "jane.doe@gmail.com",
                "zipcode": null
            },
            "landing_page": {
                "title": null,
                "url": null
            },
            "source": "email"
        },
        "subject": "Nouveau message sur votre annonce",
        "tracked_email": "acc.99999.track@mgtmail.fr",
        "to": "entreprise@monemail.com"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 3
    }
}

KPI

Get attribution KPIs

GET
https://api.magnetis.io
/kpi/attribution
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX
from
Optional. From date. 7 days ago if not set.
Example:
20240901000000
to
Optional. To date. Now if not set.
Example:
20240901235959

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/kpi/attribution" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "calls_count": 4169,
        "calls_percentage_evolution": -5,
        "leads_count": 2986,
        "leads_percentage": 72,
        "leads_percentage_evolution": -1,
        "duration": 626400,
        "duration_percentage_evolution": -8,
        "first_channel": "GoogleAds",
        "first_channel_previous": "SEO"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Get KPIs per channel

GET
https://api.magnetis.io
/kpi/channels
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX
from
Optional. From date. 7 days ago if not set.
Example:
20240901000000
to
Optional. To date. Now if not set.
Example:
20240901235959

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/kpi/channels" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "byChannel": [
            {
                "name": "Google Ads",
                "nb_calls": 0,
                "nb_leads": 0,
                "leads_percentage": 0,
                "nb_missed": 0,
                "missed_percentage": 0,
                "duration": 0,
                "avg_duration": 0,
                "nb_emails": 0
            },
            {
                "name": "SEO",
                "nb_calls": 0,
                "nb_leads": 0,
                "leads_percentage": 0,
                "nb_missed": 0,
                "missed_percentage": 0,
                "duration": 0,
                "avg_duration": 0,
                "nb_emails": 0
            },
            {
                "name": "GoogleMyBusiness",
                "nb_calls": 0,
                "nb_leads": 0,
                "leads_percentage": 0,
                "nb_missed": 0,
                "missed_percentage": 0,
                "duration": 0,
                "avg_duration": 0,
                "nb_emails": 0
            }
        ],
        "total": {
            "nb_calls": 0,
            "nb_leads": 0,
            "nb_missed": 0,
            "duration": 0,
            "avg_duration": 0,
            "nb_emails": 0,
            "leads_percentage": 0,
            "missed_percentage": 0
        }
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Get acquisition KPIs

GET
https://api.magnetis.io
/kpi/acquisition
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX
from
Optional. From date. 7 days ago if not set.
Example:
20240901000000
to
Optional. To date. Now if not set.
Example:
20240901235959

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/kpi/acquisition" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "calls_count": 4169,
        "calls_missed_count": 383,
        "calls_missed_percentage": 9,
        "calls_missed_points_evolution": 0,
        "calls_qualified_percentage": 26,
        "calls_qualified_points_evolution": -2,
        "duration_average": 150,
        "duration_average_evolution": -3,
        "callers_firsttime_count": 2447,
        "callers_firsttime_percentage": 59,
        "callers_firsttime_percentage_evolution": 0
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Get SMS and landing pages KPIs

GET
https://api.magnetis.io
/kpi/sms
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX
from
Optional. From date. 7 days ago if not set.
Example:
20240901000000
to
Optional. To date. Now if not set.
Example:
20240901235959

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/kpi/sms" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "calls_missed_count": 1507,
        "calls_missed_percentage_evolution": -4,
        "sms_sent_count": 1091,
        "sms_sent_percentage_evolution": -4,
        "clicks_count": 705,
        "clicks_percentage": 65,
        "clicks_percentage_evolution": -5,
        "leads_count": 152,
        "leads_percentage": 22,
        "leads_percentage_evolution": 4
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Get performance KPIs

GET
https://api.magnetis.io
/kpi/performance
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/kpi/performance" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "calls_by_day_average": 150,
        "calls_by_day_average_evolution": 5,
        "best_week_name": "Du 02/09 au 08/09",
        "best_week_value": 250,
        "calls_by_month_average": 3000,
        "calls_by_month_average_percentage_evolution": -8,
        "best_month_name": "September 2024",
        "best_month_value": 4200,
        "7_days_from": "10/10/2024",
        "7_days_to": "16/10/2024",
        "1_month_from": "02/09/2024",
        "1_month_to": "16/10/2024",
        "6_months_from": "01/05/2024",
        "6_months_to": "16/10/2024",
        "1_year_from": "01/11/2023",
        "1_year_to": "16/10/2024"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Get activity KPIs

GET
https://api.magnetis.io
/kpi/activity
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/kpi/activity" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "best_day": "Thursday",
        "best_day_previous": "Wednesday",
        "best_hours": "09h-10h",
        "best_hours_previous": "10h-11h",
        "in_hours_percentage": 90,
        "in_hours_percentage_previous": 85,
        "mobile_percentage": 85,
        "mobile_percentage_previous": 87
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Get Google Ads extensions KPIs

GET
https://api.magnetis.io
/kpi/extensions
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/kpi/extensions" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "calls_count": 0,
        "calls_percentage_evolution": 0,
        "calls_google_count": 0,
        "calls_google_percentage_evolution": 0,
        "impressions_count": 0,
        "impressions_percentage_evolution": 0,
        "clicks_count": 0,
        "clicks_percentage_evolution": 0
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Get Google Ads conversions KPIs

GET
https://api.magnetis.io
/kpi/conversions
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/kpi/conversions" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "conversions_count": 0,
        "conversions_success_count": 0,
        "conversions_inprogress_count": 0,
        "conversions_failed_count": 0
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Get modules KPIs

GET
https://api.magnetis.io
/kpi/modules
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/kpi/modules" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "visitors_count": 0,
        "pageviews_count": 0,
        "calls_count": 1106
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Leads

List all leads

GET
https://api.magnetis.io
/leads
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX
limit
Optional. Result per page. 250 if not set.
Example:
250
page
Optional. Pagination page. 1 if not set.
Example:
1
source
Optional. Source filter. Enum: form,email,call,import,api,interface,gsheet.
Example:
form

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/leads" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [
        {
            "id": "lead-8204460e-82fb-4a18-ac0a-fb3f34231372",
            "account": {
                "id": "acc-250ce1bd-237d-4e2d-aa17-51293760a801",
                "name": "Artisan Lyon"
            },
            "call_id": "call-7384f936-b36f-4305-9350-92e3ed67531b",
            "created_at": "2023-09-25 14:50:12",
            "email_id": null,
            "fields": {
                "firstname": "John",
                "lastname": "Doe",
                "phone": "0033647XXXXXX",
                "email": "john.doe@example.com",
                "zipcode": null
            },
            "landing_page": {
                "title": "Ma landing page",
                "url": "https://www.example.com"
            },
            "outbound": null,
            "source": "call"
        },
        {
            "id": "lead-9c6187a3-9865-418d-be80-e45d5990f039",
            "account": {
                "id": "acc-250ce1bd-237d-4e2d-aa17-51293760a801",
                "name": "Artisan Lyon"
            },
            "call_id": null,
            "created_at": "2023-09-25 14:50:12",
            "email_id": "etm-4908be34-1489-4806-85f6-11bf12ea13ce",
            "fields": {
                "firstname": "Jane",
                "lastname": "Doe",
                "phone": "0033652XXXXXX",
                "email": null,
                "zipcode": null
            },
            "landing_page": {
                "title": null,
                "url": null
            },
            "outbound": {
                "assignment_date": "2024-07-15 10:00:00",
                "events": [
                    {
                        "call_id": null,
                        "date": "2024-07-15 10:00:00",
                        "delay": 0,
                        "duration": null,
                        "name": "assignment"
                    },
                    {
                        "call_id": "call-618c89f8-7eea-455c-8fda-69a6cfaecdad",
                        "date": "2024-07-15 14:45:00",
                        "delay": 17100,
                        "duration": 5,
                        "name": "attempt"
                    },
                    {
                        "call_id": "call-e77c7218-3838-42ef-9aa4-7af980d69663",
                        "date": "2024-07-15 16:30:00",
                        "delay": 0,
                        "duration": 8,
                        "name": "attempt"
                    },
                    {
                        "call_id": "call-c4641926-5d6d-4c7f-86c0-7310361cad94",
                        "date": "2024-07-16 09:30:00",
                        "delay": 84700,
                        "duration": 1536,
                        "name": "call"
                    }
                ],
                "first_attempt": {
                    "call_id": "call-618c89f8-7eea-455c-8fda-69a6cfaecdad",
                    "date": "2024-07-15 14:45:00",
                    "delay": 17100,
                    "duration": 5
                },
                "first_call": {
                    "call_id": "call-c4641926-5d6d-4c7f-86c0-7310361cad94",
                    "date": "2024-07-16 09:30:00",
                    "delay": 84700,
                    "duration": 1536
                },
                "limit_date": "2024-07-20 10:00:00",
                "release_date": null,
                "start_date": "2024-07-15 10:00:00",
                "url": "https://www.example.com/outboundinfo/lead-9c6187a3-9865-418d-be80-e45d5990f039"
            },
            "source": "email"
        }
    ],
    "links": {
        "first": "https://api.magnetis.io/leads?page=1",
        "last": "https://api.magnetis.io/leads?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "path": "https://api.magnetis.io/leads",
        "per_page": 250,
        "to": 2,
        "total": 2,
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        }
    }
}

Create a lead

POST
https://api.magnetis.io
/leads
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Response Fields

Example request:
curl --request POST \
    "https://api.magnetis.io/leads" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"account_id\": \"acc-6e64b651-026a-46de-ab3e-944a193945a9\",
    \"fields\": [
        {
            \"label\": \"Prénom\",
            \"value\": \"François\"
        }
    ],
    \"outbound\": true,
    \"outbound_params\": {
        \"tracking_delay\": 120,
        \"limit_date\": \"2024-08-31 23:59:59\",
        \"start_date\": \"2024-08-31 00:00:00\"
    }
}"
Example response:
{
    "data": {
        "id": "lead-9c6187a3-9865-418d-be80-e45d5990f039",
        "account": {
            "id": "acc-250ce1bd-237d-4e2d-aa17-51293760a801",
            "name": "Artisan Lyon"
        },
        "created_at": "2023-09-25 14:50:12",
        "fields": {
            "firstname": "Jane",
            "lastname": "Doe",
            "phone": "0033652XXXXXX",
            "zipcode": null
        },
        "landing_page": {
            "title": null,
            "url": null
        },
        "outbound": {
            "assignment_date": "2024-07-15 10:00:00",
            "events": [
                {
                    "call_id": null,
                    "date": "2024-07-15 10:00:00",
                    "delay": 0,
                    "duration": null,
                    "name": "assignment"
                },
                {
                    "call_id": "call-618c89f8-7eea-455c-8fda-69a6cfaecdad",
                    "date": "2024-07-15 14:45:00",
                    "delay": 17100,
                    "duration": 5,
                    "name": "attempt"
                },
                {
                    "call_id": "call-e77c7218-3838-42ef-9aa4-7af980d69663",
                    "date": "2024-07-15 16:30:00",
                    "delay": 0,
                    "duration": 8,
                    "name": "attempt"
                },
                {
                    "call_id": "call-c4641926-5d6d-4c7f-86c0-7310361cad94",
                    "date": "2024-07-16 09:30:00",
                    "delay": 84700,
                    "duration": 1536,
                    "name": "call"
                }
            ],
            "first_attempt": {
                "call_id": "call-618c89f8-7eea-455c-8fda-69a6cfaecdad",
                "date": "2024-07-15 14:45:00",
                "delay": 17100,
                "duration": 5
            },
            "first_call": {
                "call_id": "call-c4641926-5d6d-4c7f-86c0-7310361cad94",
                "date": "2024-07-16 09:30:00",
                "delay": 84700,
                "duration": 1536
            },
            "limit_date": "2024-07-20 10:00:00",
            "release_date": null,
            "start_date": "2024-07-15 10:00:00",
            "url": "https://www.example.com/outboundinfo/lead-9c6187a3-9865-418d-be80-e45d5990f039"
        },
        "source": "api"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 3
    }
}

Fetch a lead

GET
https://api.magnetis.io
/leads/{slug}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The id of the lead

Example:
lead-6e64b651-026a-46de-ab3e-944a193945a9

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/leads/lead-6e64b651-026a-46de-ab3e-944a193945a9" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "id": "lead-9c6187a3-9865-418d-be80-e45d5990f039",
        "account": {
            "id": "acc-250ce1bd-237d-4e2d-aa17-51293760a801",
            "name": "Artisan Lyon"
        },
        "created_at": "2023-09-25 14:50:12",
        "fields": {
            "firstname": "Jane",
            "lastname": "Doe",
            "phone": "0033652XXXXXX",
            "zipcode": null
        },
        "landing_page": {
            "title": null,
            "url": null
        },
        "outbound": {
            "assignment_date": "2024-07-15 10:00:00",
            "events": [
                {
                    "call_id": null,
                    "date": "2024-07-15 10:00:00",
                    "delay": 0,
                    "duration": null,
                    "name": "assignment"
                },
                {
                    "call_id": "call-618c89f8-7eea-455c-8fda-69a6cfaecdad",
                    "date": "2024-07-15 14:45:00",
                    "delay": 17100,
                    "duration": 5,
                    "name": "attempt"
                },
                {
                    "call_id": "call-e77c7218-3838-42ef-9aa4-7af980d69663",
                    "date": "2024-07-15 16:30:00",
                    "delay": 0,
                    "duration": 8,
                    "name": "attempt"
                },
                {
                    "call_id": "call-c4641926-5d6d-4c7f-86c0-7310361cad94",
                    "date": "2024-07-16 09:30:00",
                    "delay": 84700,
                    "duration": 1536,
                    "name": "call"
                }
            ],
            "first_attempt": {
                "call_id": "call-618c89f8-7eea-455c-8fda-69a6cfaecdad",
                "date": "2024-07-15 14:45:00",
                "delay": 17100,
                "duration": 5
            },
            "first_call": {
                "call_id": "call-c4641926-5d6d-4c7f-86c0-7310361cad94",
                "date": "2024-07-16 09:30:00",
                "delay": 84700,
                "duration": 1536
            },
            "limit_date": "2024-07-20 10:00:00",
            "release_date": null,
            "start_date": "2024-07-15 10:00:00",
            "url": "https://www.example.com/outboundinfo/lead-9c6187a3-9865-418d-be80-e45d5990f039"
        },
        "source": "api"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 3
    }
}

Update a lead

PUT
PATCH
https://api.magnetis.io
/leads/{slug}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The id of the lead

Example:
lead-6e64b651-026a-46de-ab3e-944a193945a9

Body Parameters

Response Fields

Example request:
curl --request PUT \
    "https://api.magnetis.io/leads/lead-6e64b651-026a-46de-ab3e-944a193945a9" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"fields\": [
        {
            \"label\": \"Prénom\",
            \"value\": \"François\"
        }
    ]
}"
Example response:
{
    "data": {
        "id": "lead-9c6187a3-9865-418d-be80-e45d5990f039",
        "account": {
            "id": "acc-250ce1bd-237d-4e2d-aa17-51293760a801",
            "name": "Artisan Lyon"
        },
        "created_at": "2023-09-25 14:50:12",
        "fields": {
            "firstname": "Jane",
            "lastname": "Doe",
            "phone": "0033652XXXXXX",
            "zipcode": null
        },
        "landing_page": {
            "title": null,
            "url": null
        },
        "outbound": {
            "assignment_date": "2024-07-15 10:00:00",
            "events": [
                {
                    "call_id": null,
                    "date": "2024-07-15 10:00:00",
                    "delay": 0,
                    "duration": null,
                    "name": "assignment"
                },
                {
                    "call_id": "call-618c89f8-7eea-455c-8fda-69a6cfaecdad",
                    "date": "2024-07-15 14:45:00",
                    "delay": 17100,
                    "duration": 5,
                    "name": "attempt"
                },
                {
                    "call_id": "call-e77c7218-3838-42ef-9aa4-7af980d69663",
                    "date": "2024-07-15 16:30:00",
                    "delay": 0,
                    "duration": 8,
                    "name": "attempt"
                },
                {
                    "call_id": "call-c4641926-5d6d-4c7f-86c0-7310361cad94",
                    "date": "2024-07-16 09:30:00",
                    "delay": 84700,
                    "duration": 1536,
                    "name": "call"
                }
            ],
            "first_attempt": {
                "call_id": "call-618c89f8-7eea-455c-8fda-69a6cfaecdad",
                "date": "2024-07-15 14:45:00",
                "delay": 17100,
                "duration": 5
            },
            "first_call": {
                "call_id": "call-c4641926-5d6d-4c7f-86c0-7310361cad94",
                "date": "2024-07-16 09:30:00",
                "delay": 84700,
                "duration": 1536
            },
            "limit_date": "2024-07-20 10:00:00",
            "release_date": null,
            "start_date": "2024-07-15 10:00:00",
            "url": "https://www.example.com/outboundinfo/lead-9c6187a3-9865-418d-be80-e45d5990f039"
        },
        "source": "api"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 3
    }
}

Delete a lead

DELETE
https://api.magnetis.io
/leads/{slug}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The id of the lead

Example:
lead-6e64b651-026a-46de-ab3e-944a193945a9

Response Fields

Example request:
curl --request DELETE \
    "https://api.magnetis.io/leads/lead-6e64b651-026a-46de-ab3e-944a193945a9" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [],
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 0
    }
}

Release an outbound lead

PUT
https://api.magnetis.io
/leads/{lead_slug}/release
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The id of the lead

Example:
lead-6e64b651-026a-46de-ab3e-944a193945a9

Response Fields

Example request:
curl --request PUT \
    "https://api.magnetis.io/leads/1/release" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "id": "lead-9c6187a3-9865-418d-be80-e45d5990f039",
        "account": {
            "id": "acc-250ce1bd-237d-4e2d-aa17-51293760a801",
            "name": "Artisan Lyon"
        },
        "created_at": "2023-09-25 14:50:12",
        "fields": {
            "firstname": "Jane",
            "lastname": "Doe",
            "phone": "0033652XXXXXX",
            "zipcode": null
        },
        "landing_page": {
            "title": null,
            "url": null
        },
        "outbound": {
            "assignment_date": "2024-07-15 10:00:00",
            "events": [
                {
                    "call_id": null,
                    "date": "2024-07-15 10:00:00",
                    "delay": 0,
                    "duration": null,
                    "name": "assignment"
                },
                {
                    "call_id": "call-618c89f8-7eea-455c-8fda-69a6cfaecdad",
                    "date": "2024-07-15 14:45:00",
                    "delay": 17100,
                    "duration": 5,
                    "name": "attempt"
                },
                {
                    "call_id": "call-e77c7218-3838-42ef-9aa4-7af980d69663",
                    "date": "2024-07-15 16:30:00",
                    "delay": 0,
                    "duration": 8,
                    "name": "attempt"
                },
                {
                    "call_id": "call-c4641926-5d6d-4c7f-86c0-7310361cad94",
                    "date": "2024-07-16 09:30:00",
                    "delay": 84700,
                    "duration": 1536,
                    "name": "call"
                }
            ],
            "first_attempt": {
                "call_id": "call-618c89f8-7eea-455c-8fda-69a6cfaecdad",
                "date": "2024-07-15 14:45:00",
                "delay": 17100,
                "duration": 5
            },
            "first_call": {
                "call_id": "call-c4641926-5d6d-4c7f-86c0-7310361cad94",
                "date": "2024-07-16 09:30:00",
                "delay": 84700,
                "duration": 1536
            },
            "limit_date": "2024-07-20 10:00:00",
            "release_date": null,
            "start_date": "2024-07-15 10:00:00",
            "url": "https://www.example.com/outboundinfo/lead-9c6187a3-9865-418d-be80-e45d5990f039"
        },
        "source": "api"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 3
    }
}

Monitoring

Daily monitoring


List all daily monitorings

GET
https://api.magnetis.io
/monitorings/daily
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX
limit
Optional. Result per page. 250 if not set.
Example:
250
page
Optional. Pagination page. 1 if not set.
Example:
1

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/monitorings/daily" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [
        {
            "id": "mdl-67bc8021-08f8-44a7-81e0-5002724ed3e7",
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "created_at": "2024-01-02 08:09:53",
            "enabled": true,
            "last_alert": "2024-02-29 13:44:21",
            "rate": "70",
            "recipients": [
                "example@email.fr"
            ]
        }
    ],
    "links": {
        "first": "https://api.magnetis.io/monitorings/daily?page=1",
        "last": "https://api.magnetis.io/monitorings/daily?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "path": "https://api.magnetis.io/monitorings/daily",
        "per_page": 250,
        "to": 1,
        "total": 1,
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        }
    }
}

Fetch a daily monitoring

GET
https://api.magnetis.io
/monitorings/daily/{account_id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Account ID
required
Example:
acc-67bc8021-08f8-44a7-81e0-5002724ed3e7

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/monitorings/daily/acc-67bc8021-08f8-44a7-81e0-5002724ed3e7" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:

Update a daily monitoring

PUT
https://api.magnetis.io
/monitorings/daily/{account_id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Account ID
required
Example:
acc-67bc8021-08f8-44a7-81e0-5002724ed3e7

Body Parameters

Response Fields

Example request:
curl --request PUT \
    "https://api.magnetis.io/monitorings/daily/acc-67bc8021-08f8-44a7-81e0-5002724ed3e7" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"rate\": 13,
    \"recipients\": [
        \"qui\"
    ],
    \"enabled\": false
}"
Example response:

Recurring monitoring


List all recurring monitorings

GET
https://api.magnetis.io
/monitorings/recurring
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX
limit
Optional. Result per page. 250 if not set.
Example:
250
page
Optional. Pagination page. 1 if not set.
Example:
1

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/monitorings/recurring" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [
        {
            "id": "mrr-6d027ee3-4cff-43a0-84be-1dbc3d7559e5",
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "created_at": "2024-01-02 08:09:53",
            "enabled": true,
            "last_alert": "2024-02-29 13:44:21",
            "level": "10",
            "recipients": [
                "example@email.fr"
            ]
        }
    ],
    "links": {
        "first": "https://api.magnetis.io/monitorings/recurring?page=1",
        "last": "https://api.magnetis.io/monitorings/recurring?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "path": "https://api.magnetis.io/monitorings/recurring",
        "per_page": 250,
        "to": 1,
        "total": 1,
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        }
    }
}

Fetch a recurring monitoring

GET
https://api.magnetis.io
/monitorings/recurring/{account_id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Account ID
required
Example:
acc-6d027ee3-4cff-43a0-84be-1dbc3d7559e5

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/monitorings/recurring/acc-6d027ee3-4cff-43a0-84be-1dbc3d7559e5" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:

Update a recurring monitoring

PUT
https://api.magnetis.io
/monitorings/recurring/{account_id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Account ID
required
Example:
acc-6d027ee3-4cff-43a0-84be-1dbc3d7559e5

Body Parameters

Response Fields

Example request:
curl --request PUT \
    "https://api.magnetis.io/monitorings/recurring/acc-6d027ee3-4cff-43a0-84be-1dbc3d7559e5" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"level\": 7,
    \"recipients\": \"nesciunt\",
    \"enabled\": true,
    \"mailees\": [
        \"qui\"
    ]
}"
Example response:

Recipient monitoring


Fetch the recipient monitoring

GET
https://api.magnetis.io
/monitorings/recipient
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/monitorings/recipient" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "id": "mrp-2e25425a-26b2-455e-a51b-0693af0f3081",
        "organization_id": "org-6d0aff3d-3141-45bb-8b2b-2d6e2d8dc18e",
        "created_at": "2024-01-02 08:09:53",
        "enabled": false,
        "last_alert": "2024-02-29 13:44:21",
        "level": "5",
        "recipients": [
            "example@email.fr"
        ]
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My Account"
        },
        "total": 1
    }
}

Update the recipient monitoring

PUT
https://api.magnetis.io
/monitorings/recipient
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Response Fields

Example request:
curl --request PUT \
    "https://api.magnetis.io/monitorings/recipient" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"level\": 3,
    \"recipients\": [
        \"voluptatem\"
    ],
    \"enabled\": false
}"
Example response:
{
    "data": {
        "id": "mrp-2e25425a-26b2-455e-a51b-0693af0f3081",
        "organization_id": "org-6d0aff3d-3141-45bb-8b2b-2d6e2d8dc18e",
        "created_at": "2024-01-02 08:09:53",
        "enabled": false,
        "last_alert": "2024-02-29 13:44:21",
        "level": "5",
        "recipients": [
            "example@email.fr"
        ]
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My Account"
        },
        "total": 1
    }
}

Numbers

List all tracked numbers

GET
https://api.magnetis.io
/numbers
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX
limit
Optional. Result per page. 250 if not set.
Example:
250
page
Optional. Pagination page. 1 if not set.
Example:
1

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/numbers" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [
        {
            "id": "num-a81cf765-0e48-4797-b315-f702c783996e",
            "account": {
                "id": "acc-f702dcb6-87cf-4bc4-8632-560c43aec1a4",
                "name": "Auto Bordeaux"
            },
            "channel_name": "Google Ads",
            "channel_type": "googleads",
            "country": "FRA",
            "created_at": "2023-07-14 13:52:27",
            "functionalities": {
                "recording": {
                    "deactivation": 1,
                    "terms": "custom",
                    "terms_audio": "sda-e66b21e0-2064-4175-8fa2-2f7a60e64da4"
                },
                "whisper": {
                    "audio": "sda-ef617d12-528a-40fe-a997-da4cda4e4ba7"
                }
            },
            "is_premium": false,
            "number": "0033522334455",
            "recipient": {
                "id": "rcp-3921328c-5966-4df9-a9a9-5f2a8f383e3a",
                "country": "FRA",
                "created_at": "2023-07-14 13:47:21",
                "name": "Concession Bordeaux",
                "number": "0033698765432",
                "type": "mobile"
            },
            "type": "geographic"
        },
        {
            "id": "num-cdea62a0-05f3-4183-b285-697458cadb9e",
            "account": {
                "id": "acc-f702dcb6-87cf-4bc4-8632-560c43aec1a4",
                "name": "Auto Bordeaux"
            },
            "channel_name": "SEO",
            "channel_type": "seo",
            "country": "FRA",
            "created_at": "2023-07-14 13:52:27",
            "functionalities": {
                "recording": null,
                "whisper": null
            },
            "is_premium": false,
            "number": "0033555443322",
            "recipient": {
                "id": "rcp-3921328c-5966-4df9-a9a9-5f2a8f383e3a",
                "country": "FRA",
                "created_at": "2023-07-14 13:47:21",
                "name": "Concession Bordeaux",
                "number": "0033698765432",
                "type": "mobile"
            },
            "type": "geographic"
        },
        {
            "id": "num-e6075fb2-172a-4acf-bc49-6076bbb0c44f",
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immo Paris"
            },
            "channel_name": "Site Internet",
            "channel_type": "website",
            "country": "FRA",
            "created_at": "2023-07-21 13:58:30",
            "functionalities": {
                "recording": null,
                "whisper": null
            },
            "is_premium": false,
            "number": "0033199887766",
            "recipient": {
                "id": "rcp-b7958038-063d-4c75-b7ec-3baea00c8444",
                "country": "FRA",
                "created_at": "2023-07-21 12:54:07",
                "name": "Agence Paris",
                "number": "0033166778899",
                "type": "geographic"
            },
            "type": "geographic"
        }
    ],
    "links": {
        "first": "https://api.magnetis.io/numbers?page=1",
        "last": "https://api.magnetis.io/numbers?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "path": "https://api.magnetis.io/numbers",
        "per_page": 250,
        "to": 3,
        "total": 3,
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        }
    }
}

Create a tracked number

POST
https://api.magnetis.io
/numbers
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Response Fields

Example request:
curl --request POST \
    "https://api.magnetis.io/numbers" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"account_id\": \"acc-XXX\",
    \"area_code\": \"00339\",
    \"channel_name\": \"My website\",
    \"channel_type\": \"website\",
    \"country\": \"FRA\",
    \"recipient_id\": \"rec-XXX\",
    \"recording\": \"qui\"
}"
Example response:
{
    "data": {
        "id": "num-a81cf765-0e48-4797-b315-f702c783996e",
        "account": {
            "id": "acc-f702dcb6-87cf-4bc4-8632-560c43aec1a4",
            "name": "Auto Bordeaux"
        },
        "channel_name": "Google Ads",
        "channel_type": "googleads",
        "country": "FRA",
        "created_at": "2023-07-14 13:52:27",
        "functionalities": {
            "recording": {
                "deactivation": 1,
                "terms": "custom",
                "terms_audio": "sda-e66b21e0-2064-4175-8fa2-2f7a60e64da4"
            },
            "whisper": {
                "audio": "sda-ef617d12-528a-40fe-a997-da4cda4e4ba7"
            }
        },
        "is_premium": false,
        "number": "0033522334455",
        "recipient": {
            "id": "rcp-3921328c-5966-4df9-a9a9-5f2a8f383e3a",
            "country": "FRA",
            "created_at": "2023-07-14 13:47:21",
            "name": "Concession Bordeaux",
            "number": "0033698765432",
            "type": "mobile"
        },
        "type": "geographic"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Fetch a tracked number

GET
https://api.magnetis.io
/numbers/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

Required. The ID of the call.

Example:
num-50700e9e-879e-480a-859a-1db8301bd712

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/numbers/num-50700e9e-879e-480a-859a-1db8301bd712" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "id": "num-a81cf765-0e48-4797-b315-f702c783996e",
        "account": {
            "id": "acc-f702dcb6-87cf-4bc4-8632-560c43aec1a4",
            "name": "Auto Bordeaux"
        },
        "channel_name": "Google Ads",
        "channel_type": "googleads",
        "country": "FRA",
        "created_at": "2023-07-14 13:52:27",
        "functionalities": {
            "recording": {
                "deactivation": 1,
                "terms": "custom",
                "terms_audio": "sda-e66b21e0-2064-4175-8fa2-2f7a60e64da4"
            },
            "whisper": {
                "audio": "sda-ef617d12-528a-40fe-a997-da4cda4e4ba7"
            }
        },
        "is_premium": false,
        "number": "0033522334455",
        "recipient": {
            "id": "rcp-3921328c-5966-4df9-a9a9-5f2a8f383e3a",
            "country": "FRA",
            "created_at": "2023-07-14 13:47:21",
            "name": "Concession Bordeaux",
            "number": "0033698765432",
            "type": "mobile"
        },
        "type": "geographic"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Update a tracked number

PUT
PATCH
https://api.magnetis.io
/numbers/{slug}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The id of the number.

Example:
num-50700e9e-879e-480a-859a-1db8301bd712

Body Parameters

Response Fields

Example request:
curl --request PUT \
    "https://api.magnetis.io/numbers/1" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"channel_name\": \"My website\",
    \"channel_type\": \"website\",
    \"recipient_id\": \"rec-XXX\",
    \"recording\": \"architecto\"
}"
Example response:
{
    "data": {
        "id": "num-a81cf765-0e48-4797-b315-f702c783996e",
        "account": {
            "id": "acc-f702dcb6-87cf-4bc4-8632-560c43aec1a4",
            "name": "Auto Bordeaux"
        },
        "channel_name": "Google Ads",
        "channel_type": "googleads",
        "country": "FRA",
        "created_at": "2023-07-14 13:52:27",
        "functionalities": {
            "recording": {
                "deactivation": 1,
                "terms": "custom",
                "terms_audio": "sda-e66b21e0-2064-4175-8fa2-2f7a60e64da4"
            },
            "whisper": {
                "audio": "sda-ef617d12-528a-40fe-a997-da4cda4e4ba7"
            }
        },
        "is_premium": false,
        "number": "0033522334455",
        "recipient": {
            "id": "rcp-3921328c-5966-4df9-a9a9-5f2a8f383e3a",
            "country": "FRA",
            "created_at": "2023-07-14 13:47:21",
            "name": "Concession Bordeaux",
            "number": "0033698765432",
            "type": "mobile"
        },
        "type": "geographic"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Delete a tracked number

DELETE
https://api.magnetis.io
/numbers/{slug}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The id of the number.

Example:
num-50700e9e-879e-480a-859a-1db8301bd712

Response Fields

Example request:
curl --request DELETE \
    "https://api.magnetis.io/numbers/num-50700e9e-879e-480a-859a-1db8301bd712" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "id": "num-a81cf765-0e48-4797-b315-f702c783996e",
        "account": {
            "id": "acc-f702dcb6-87cf-4bc4-8632-560c43aec1a4",
            "name": "Auto Bordeaux"
        },
        "channel_name": "Google Ads",
        "channel_type": "googleads",
        "country": "FRA",
        "created_at": "2023-07-14 13:52:27",
        "functionalities": {
            "recording": {
                "deactivation": 1,
                "terms": "custom",
                "terms_audio": "sda-e66b21e0-2064-4175-8fa2-2f7a60e64da4"
            },
            "whisper": {
                "audio": "sda-ef617d12-528a-40fe-a997-da4cda4e4ba7"
            }
        },
        "is_premium": false,
        "number": "0033522334455",
        "recipient": {
            "id": "rcp-3921328c-5966-4df9-a9a9-5f2a8f383e3a",
            "country": "FRA",
            "created_at": "2023-07-14 13:47:21",
            "name": "Concession Bordeaux",
            "number": "0033698765432",
            "type": "mobile"
        },
        "type": "geographic"
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 1
    }
}

Recipients

List all recipients

GET
https://api.magnetis.io
/recipients
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX
limit
Optional. Result per page. 250 if not set.
Example:
250
page
Optional. Pagination page. 1 if not set.
Example:
1

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/recipients" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:

Create a recipient

POST
https://api.magnetis.io
/recipients
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Response Fields

Example request:
curl --request POST \
    "https://api.magnetis.io/recipients" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"account_id\": \"acc-6e64b651-026a-46de-ab3e-944a193945a9\",
    \"country\": \"FRA\",
    \"name\": \"Bruno\",
    \"number\": \"003362345XXXX\",
    \"type\": \"geographic\"
}"

Fetch a recipient

GET
https://api.magnetis.io
/recipients/{slug}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The id of the recipient.

Example:
rcp-85ea860d-74ce-4ac9-90fd-b85030eb34c0

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/recipients/rcp-85ea860d-74ce-4ac9-90fd-b85030eb34c0" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:

Update a recipient

PUT
PATCH
https://api.magnetis.io
/recipients/{slug}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The id of the recipient.

Example:
rcp-85ea860d-74ce-4ac9-90fd-b85030eb34c0

Body Parameters

Response Fields

Example request:
curl --request PUT \
    "https://api.magnetis.io/recipients/rcp-85ea860d-74ce-4ac9-90fd-b85030eb34c0" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Bruno\"
}"

Delete a recipient

DELETE
https://api.magnetis.io
/recipients/{slug}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

slug
string
required

The id of the recipient.

Example:
rcp-85ea860d-74ce-4ac9-90fd-b85030eb34c0

Response Fields

Example request:
curl --request DELETE \
    "https://api.magnetis.io/recipients/rcp-85ea860d-74ce-4ac9-90fd-b85030eb34c0" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"

Reports

List all reports

GET
https://api.magnetis.io
/reports
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

account_id
Optional. Filter by account ID.
Example:
acc-XXX
limit
Optional. Result per page. 250 if not set.
Example:
250
page
Optional. Pagination page. 1 if not set.
Example:
1

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/reports" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [
        {
            "id": "rep-7a3501db-5bc4-4161-aba3-d51f3acc288b",
            "accounts": [],
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "all": 0,
            "created_at": "2024-03-04 09:06:09",
            "period": "weekly",
            "day_week": 2,
            "day_month": null,
            "private": 0,
            "network": null,
            "recipients": [
                {
                    "email": "example@email.fr",
                    "type": "to"
                }
            ],
            "sender": "contact@email.fr",
            "subject": "",
            "title": "Rapport d'extraction des appels manqués",
            "type": "lostcall",
            "user": {
                "id": "usr-0ca9023b-b57b-4a5b-867b-e6858287575f",
                "created_at": "2024-03-04T08:06:08.000000Z",
                "email": "example@email.fr",
                "firstname": "John",
                "lang": "fr",
                "lastname": "Doe",
                "phone": "03 62 XX XX XX"
            }
        },
        {
            "id": "rep-4f6dccfb-33cd-43ce-b94e-ff92e791aab3",
            "accounts": [],
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "all": 0,
            "created_at": "2024-03-04 09:06:09",
            "period": "daily",
            "day_week": null,
            "day_month": null,
            "private": 0,
            "network": null,
            "recipients": [
                {
                    "email": "example@email.fr",
                    "type": "to"
                }
            ],
            "sender": "contact@email.fr",
            "subject": "",
            "title": "Rapport de synthèse",
            "type": "synthesis",
            "user": {
                "id": "usr-0ca9023b-b57b-4a5b-867b-e6858287575f",
                "created_at": "2024-03-04T08:06:08.000000Z",
                "email": "example@email.fr",
                "firstname": "John",
                "lang": "fr",
                "lastname": "Doe",
                "phone": "03 62 XX XX XX"
            }
        },
        {
            "id": "rep-ea6476f6-f777-4e3c-923f-712d676f1168",
            "accounts": [],
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "all": 1,
            "created_at": "2024-03-04 09:06:09",
            "period": "monthly",
            "day_week": null,
            "day_month": 8,
            "private": 0,
            "network": null,
            "recipients": [],
            "sender": "contact@email.fr",
            "subject": "",
            "title": "Rapport de synthèse web",
            "type": "web",
            "user": {
                "id": "usr-0ca9023b-b57b-4a5b-867b-e6858287575f",
                "created_at": "2024-03-04T08:06:08.000000Z",
                "email": "example@email.fr",
                "firstname": "John",
                "lang": "fr",
                "lastname": "Doe",
                "phone": "03 62 XX XX XX"
            }
        },
        {
            "id": "rep-5345fd1a-7331-4242-ab5c-71de77e33818",
            "accounts": [],
            "account": {
                "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
                "name": "Immobilier tertiaire"
            },
            "all": false,
            "created_at": "2024-03-04 09:06:09",
            "period": "monthly",
            "day_week": null,
            "day_month": 12,
            "private": 1,
            "network": null,
            "recipients": [
                {
                    "email": "example@email.fr",
                    "type": "to"
                }
            ],
            "sender": "contact@email.fr",
            "subject": "",
            "title": "Rapport d'extraction des appels",
            "type": "extract",
            "user": {
                "id": "usr-0ca9023b-b57b-4a5b-867b-e6858287575f",
                "created_at": "2024-03-04T08:06:08.000000Z",
                "email": "example@email.fr",
                "firstname": "John",
                "lang": "fr",
                "lastname": "Doe",
                "phone": "03 62 XX XX XX"
            }
        }
    ],
    "links": {
        "first": "https://api.magnetis.io/reports?page=1",
        "last": "https://api.magnetis.io/reports?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "path": "https://api.magnetis.io/reports",
        "per_page": 250,
        "to": 4,
        "total": 4,
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        }
    }
}

Create a report

POST
https://api.magnetis.io
/reports
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Response Fields

Example request:
curl --request POST \
    "https://api.magnetis.io/reports" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"account_id\": \"acc-6e64b651-026a-46de-ab3e-944a193945a9\",
    \"network_id\": \"net-6e64b651-026a-46de-ab3e-944a193945a9\",
    \"accounts\": \"[acc-6e64b651-026a-46de-ab3e-944a193945a9, acc-cf162a0f-8ea4-4aad-999c-81f8e85cb033]\",
    \"sender\": \"contact\",
    \"all\": false,
    \"recipients\": [
        {
            \"email\": \"email@test.fr\",
            \"type\": \"to\"
        }
    ],
    \"subject\": \"Call-tracking report\",
    \"title\": \"My statistic report\",
    \"type\": \"synthesis\",
    \"period\": \"weekly\",
    \"day_week\": \"1\",
    \"day_month\": \"null\",
    \"enabled\": false
}"
Example response:
{
    "data": {
        "id": "rep-5345fd1a-7331-4242-ab5c-71de77e33818",
        "accounts": [],
        "account": {
            "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
            "name": "Immobilier tertiaire"
        },
        "all": false,
        "created_at": "2024-03-04 09:06:09",
        "period": "monthly",
        "day_week": null,
        "day_month": 12,
        "private": 1,
        "network": null,
        "recipients": [
            {
                "email": "example@email.fr",
                "type": "to"
            }
        ],
        "sender": "contact@email.fr",
        "subject": "",
        "title": "Rapport d'extraction des appels",
        "type": "extract",
        "user": {
            "id": "usr-0ca9023b-b57b-4a5b-867b-e6858287575f",
            "created_at": "2024-03-04T08:06:08.000000Z",
            "email": "example@email.fr",
            "firstname": "John",
            "lang": "fr",
            "lastname": "Doe",
            "phone": "03 62 XX XX XX"
        }
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2024-03-04 09:12:08",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 4
    }
}

Fetch a report

GET
https://api.magnetis.io
/reports/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
The id of the report
required
Example:
rep-c1e6945d-c21b-4bfb-82f8-b08eb7f8128e

Response Fields

Example request:
curl --request GET \
    --get "https://api.magnetis.io/reports/rep-c1e6945d-c21b-4bfb-82f8-b08eb7f8128e" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": {
        "id": "rep-5345fd1a-7331-4242-ab5c-71de77e33818",
        "accounts": [],
        "account": {
            "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
            "name": "Immobilier tertiaire"
        },
        "all": false,
        "created_at": "2024-03-04 09:06:09",
        "period": "monthly",
        "day_week": null,
        "day_month": 12,
        "private": 1,
        "network": null,
        "recipients": [
            {
                "email": "example@email.fr",
                "type": "to"
            }
        ],
        "sender": "contact@email.fr",
        "subject": "",
        "title": "Rapport d'extraction des appels",
        "type": "extract",
        "user": {
            "id": "usr-0ca9023b-b57b-4a5b-867b-e6858287575f",
            "created_at": "2024-03-04T08:06:08.000000Z",
            "email": "example@email.fr",
            "firstname": "John",
            "lang": "fr",
            "lastname": "Doe",
            "phone": "03 62 XX XX XX"
        }
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2024-03-04 09:12:08",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 4
    }
}

Update a report

PUT
PATCH
https://api.magnetis.io
/reports/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
The id of the report
required
Example:
rep-c1e6945d-c21b-4bfb-82f8-b08eb7f8128e

Body Parameters

Response Fields

Example request:
curl --request PUT \
    "https://api.magnetis.io/reports/rep-c1e6945d-c21b-4bfb-82f8-b08eb7f8128e" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"accounts\": \"[acc-6e64b651-026a-46de-ab3e-944a193945a9, acc-cf162a0f-8ea4-4aad-999c-81f8e85cb033]\",
    \"sender\": \"contact\",
    \"all\": false,
    \"recipients\": [
        {
            \"email\": \"email@test.fr\",
            \"type\": \"to\"
        }
    ],
    \"subject\": \"Call-tracking report\",
    \"title\": \"My statistic report\",
    \"type\": \"synthesis\",
    \"period\": \"weekly\",
    \"day_week\": \"1\",
    \"day_month\": \"null\",
    \"enabled\": false
}"
Example response:
{
    "data": {
        "id": "rep-5345fd1a-7331-4242-ab5c-71de77e33818",
        "accounts": [],
        "account": {
            "id": "acc-f27c03a5-9498-4dd1-aeeb-30722b219f2e",
            "name": "Immobilier tertiaire"
        },
        "all": false,
        "created_at": "2024-03-04 09:06:09",
        "period": "monthly",
        "day_week": null,
        "day_month": 12,
        "private": 1,
        "network": null,
        "recipients": [
            {
                "email": "example@email.fr",
                "type": "to"
            }
        ],
        "sender": "contact@email.fr",
        "subject": "",
        "title": "Rapport d'extraction des appels",
        "type": "extract",
        "user": {
            "id": "usr-0ca9023b-b57b-4a5b-867b-e6858287575f",
            "created_at": "2024-03-04T08:06:08.000000Z",
            "email": "example@email.fr",
            "firstname": "John",
            "lang": "fr",
            "lastname": "Doe",
            "phone": "03 62 XX XX XX"
        }
    },
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2024-03-04 09:12:08",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 4
    }
}

Delete a report

DELETE
https://api.magnetis.io
/reports/{id}
requires authentication

Headers

x-api-key
Example:
{YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
The id of the report
required
Example:
rep-c1e6945d-c21b-4bfb-82f8-b08eb7f8128e

Response Fields

Example request:
curl --request DELETE \
    "https://api.magnetis.io/reports/rep-c1e6945d-c21b-4bfb-82f8-b08eb7f8128e" \
    --header "x-api-key: {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
{
    "data": [],
    "meta": {
        "apiKey": {
            "id": "key-d464804c-61a5-494b-a2ce-db765f5691c2",
            "created_at": "2023-07-25 12:00:00",
            "expiration": null,
            "level": "account",
            "name": "My account"
        },
        "total": 0
    }
}