Send Invite Using SMS

It's possible to send invites via SMS to the phone number of the invitee. Sending invites via SMS can only be done if channel sms is activated.

Add a phone number to an invitee

To send an invite via SMS, it's required to provide the phoneNumber of the invitee (in E.164 format).

POST https://api.cm.com/sign/v1/dossiers

Request headers

Content-Type: application/json
Authorization: Bearer GENERATED_TOKEN_HERE

Request body

{
    "name": "Purchase contract",
    "reminderIn": 604800,
    "invitees": [
        {
            "name": "Invitee",
            "email": "[email protected]",
            "phoneNumber": "+31612345678"
        }
    ]
}

Response

{
    "id": "302935b2-8a22-4e25-bffb-fccda8963bd4",
    "name": "Purchase contract",
    "state": "draft",
    "locale": "en-US",
    "completed": false,
    "reminderIn": 604800,
    "invitees": [
        {
            "id": "f6d1afd5-aa6a-4c5e-8348-bf5a5310b5d2",
            "name": "Invitee",
            "email": "[email protected]",
            "phoneNumber": "+31612345678",
            "authenticationMethods": [],
            "identificationMethods": [],
            "reference": null,
            "readOnly": false,
            "state": null,
            "stateChanged": null,
            "position": null,
            "locale": "nl-NL"
        }
    ],
    "expiresIn": 2592000,
    "expiresAt": "2022-01-31T00:00:00+00:00",
    "createdAt": "2022-01-01T00:00:00+00:00"
}

Sending an invite via SMS

To send an invite via SMS the channel needs to be configured to sms.

POST https://api.cm.com/sign/v1/dossiers/{dossierId}/invites

Request headers

Content-Type: application/json
Authorization: Bearer GENERATED_TOKEN_HERE

Request body

[
    {
        "inviteeId": "80692813-3493-40e9-86c3-d3b6f7378929",
        "channel": "sms",
        "expiresIn": 2592000
    }
]

Response

[
    {
        "id": "22b33b45-bde6-45f4-a45a-ec1fa53ffffa",
        "inviteeId": "80692813-3493-40e9-86c3-d3b6f7378929",
        "inviteUri": null,
        "readOnly": false,
        "authenticationMethods": [],
        "identificationMethods": [],
        "channel": "sms",
        "reminder": false,
        "emailSentAt": null,
        "emailBouncedAt": null,
        "expiresIn": 2592000,
        "expiresAt": "2022-01-31T00:00:00+00:00",
        "createdAt": "2022-01-01T00:00:00+00:00"
    }
]