Send Integration SMS invite

This method allows you to send a single SMS invite.

Resource

https://api.infobip.com/omnichat/1/applications/{applicationKey}/integrations/{integrationType}/invite

Parameters

Property name Type Description
applicationKey string (application key) Phone number.
integrationType string (integration type) Phone number.
to string Phone number to which invite will be sent. Must be in international format (Example: 41793026727).
linkPlaceholder string Link placeholder. This value should be part of a message text and it will be replaced with generated invite link.
message* string Text of a message that will be sent. Message should contain link placeholder.

Request Example

					POST /omnichat/1/applications/0F3C3F29829FAB88714BA205BEC6D28F/integrations/FACEBOOK/invite HTTP/1.1
Host: api.infobip.com
Authorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==
Content-Type: application/json
Accept: application/json

{
  "to":"41793026727",
  "linkPlaceholder":"<link>",
  "message":"Hello, if you'd like to hear more about Foo, follow us at <link>"
}
					
				

Response

					{
  "to": "41793026727",
  "messageCount": 1,
  "messageId": "1215f543ab19-345f-adbd-12ad31451ed25f35",
  "status": {
    "groupId": 1,
    "groupName": "PENDING",
    "id": 7,
    "name": "PENDING_ENROUTE",
    "description": "Message sent to next instance"
  }
}
					
				
					{
  "requestError": {
    "serviceException": {
      "messageId": "BAD_REQUEST",
      "text": "Bad request"
    }
  }
}
					
				
					{
  "requestError": {
    "serviceException": {
      "messageId": "UNAUTHORIZED",
      "text": "Invalid login details"
    }
  }
}
					
				

Response format

If successful, the response header HTTP status code will be 200 OK and the message will be sent. If you try to send the message without authorization, you will receive a 401 Unauthorized error. In case of an incorrectly formatted request, the HTTP status code will be 400 Bad Request.

Response

Parameter Type Description
to String Phone number to which link was sent.
status Status Indicates whether the message is sent successfully, not sent, delivered, not delivered, waiting for delivery or any other possible status.
messageCount int The number of sent message segments.
messageId String The ID that uniquely identifies the sent message.

Status

Parameter Type Description
groupId int Status group ID.
groupName String Status group name.
id int Status ID.
name String Status name.
description String Human-readable description of the status.
action String Action that should be taken to eliminate the error.