Create or fetch a container
Méthode POST https://client-api.v5.livstick.com/api/v3/containers
Use this endpoint to initialize a container by business reference (crid).
Contact values can be supplied for server-side message prefill. Recipient
first and last names are optional. Without recipient.channel, email is
selected whenever recipient.email is available, even if a phone is also
supplied. A phone-only recipient must explicitly use channel: sms.
If the container already exists for the platform, the API returns existing
links without mutating it. Use PATCH /containers/{crid} for corrections.
Autorisation
Scope requis
containers:write
Use Authorization: Bearer liv_<prefix>_<secret>.
Corps de la requête
| Nom | Type | Requis | Description |
|---|---|---|---|
crid |
string
|
Requis | |
emailObsolète |
string
|
Facultatif |
Deprecated alias of sender.email.
Contraintes
format email
|
sender |
SenderInput
|
Facultatif | Optional sender identity and contact values. |
recipient |
RecipientInput
|
Facultatif |
Optional recipient identity and contact values. With no channel, email is
selected when present. A phone-only recipient must set channel to sms.
|
language |
string
|
Facultatif | |
codeGroup |
string
|
Facultatif | |
mode |
ContainerMode
|
Facultatif |
Container mode. single (default) holds one message; gallery accepts
multiple messages. Ignored when the container already exists.
Valeurs
single
gallery
|
additionalData |
object
|
Facultatif |
Arbitrary metadata, preserved unchanged. Historical contact aliases
remain recognized: email, senderEmail, sender first/last-name
variants, receiverEmail, receiverPhone, and messageNotified.
|
Réponses
Container created or reused.
Request rejected due to invalid payload or business precondition.
{
"error": {
"code": "DATA_INVALID",
"message": "Invalid request data"
}
}
Authentication failed or missing bearer token.
{
"error": {
"code": "UNAUTHORIZED",
"message": "Missing API key"
}
}
Authenticated but not allowed by scope or key constraints.
{
"error": {
"code": "FORBIDDEN",
"message": "Insufficient permissions"
}
}