Submit a new message to the delivery chat.
Request
Method : POST
URI : https:
Header
{
"Content-Type": "application/json",
"Accept": "application/json",
"api_key": "your-api-key",
"api_aceess": "your-api-access",
"api_pass": "your-api-password"
}
Key | Required | Type | Details |
api_key | Yes | String | Your API key generated from the user portal |
api_access | Yes | String | Your API access generated from the user portal |
api_password | Yes | String | Your API password generated from the user portal |
Body
{
"message": "Hello world!",
"type" : "text"
}
Key | Required | Type | Default | Details |
message | Yes | String | - | The message to be shared on the delivery chat |
type | Yes | String | text | The type of the message 'text', 'image', 'audio', 'video' |
Expected Response
Success
{
code: 200,
status: 'success',
message: 'Message saved!'
}
Failure
This response is just a sample, the content may differ based on the type of error
{
code: 400,
err_code: "1x00101-039",
status: "fail",
message: "Bad request",
errors: [
"No chat was found for the provided delivery uuid"
]
}
Code | Error | Details |
400 | 1x00101-019 | Input errors |
400 | 1x00101-025 | API input errors |
400 | 1x00101-039 | Delivery not found |
403 | 1x00101-031 | Unauthorized to preform the request |
500 | 1x00101-029 | Server side error |
500 | 1x00101-035 | Server sdie error |