Create Message

Resource

https://api.infobip.com/ccaas/conversations/{conversationId}/messages

Path Params

Property name Type
conversationId string

 

Body Params

Property name Type Description
from string phoneNumber, messengerId
to string phoneNumber, messengerId
channel string SMS, VIBER, FACEBOOK_MESSENGER, WHATSAPP
content string  

Request Example

					POST /ccaas/1/conversations/9F1F21C198025CC026956A7E2E9C560F/messages HTTP/1.1
Host: api.infobip.com
Authorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==
Accept: application/json

{
    "from": "385951116666",
    "to": "385976333666",
    "channel": "SMS",
    "content": "Dear customer, thank's for everything."
}
					
				

Response

					{
    "id": "107AB921757DEAC9BE79EC6259B31C8A",
  	"from": "385951116666",
  	"to": "385976333666",
    "channel": "SMS",
    "content": "Dear customer, thank's for everything.",
    "direction": "OUTBOUND",
    "conversationId": "9F1F21C198025CC026956A7E2E9C560F",
    "createdAt": "2019-04-30T13:52:27.551+0000",
    "contentType": "TEXT"
}
					
				
					{
  "statusCode": "ERROR",
  "message": "Invalid id '9F1F21C198025CC026956A7E2E9C560F' given! No such entity exists."
}
					
				
					{
    "statusCode": "ERROR",
    "message": "Required request body is missing or not valid"
}
					
				

Use this method to create a new message.

 

 

Body Params

Property name Type Description
conversationId string Required - Conversation Id to set note to
from string Required - Agents telephone number or FacebookMessengerId message is sending from
to string Required - Destination, customers telephone number or FacebookMessengerId message is sending to
channel string Required - Selected channel to send the message (SMS, VIBER, FACEBOOK_MESSENGER, WHATSAPP)
content string Required - Content of message can be any text up to 4000 characters. Content limits are channel dependent. See length info for SMS