Skip to content
English
  • There are no suggestions because the search field is empty.

Pisano Campaing Sharing APIs - SMS - SMS Sharing

Create a New SMS Sharing

Create a new SMS Sharing.

POST /v1/sms_campaigns/{campaign_id}/sms_sharings

Authentication

Authentication Method Token token=<API_TOKEN>

Request

Path Parameters

Parameter Type Required Description Example
campaign_id string (uuid) Yes Campaign ID campaign_id

Headers

Header Required Description Example
Content-Type Yes Request content type. application/json
Authorization Yes Pisano API token. Token token=<API_TOKEN>

Request Body

{
  "phone_numbers": [
    "<phone_number>"
  ],
  "custom_attributes": {
    "<phone_number>": {
      "name": "<name>",
      "external_id": "<external_id>",
      "email": "<email>"
    }
  },
  "built_in_responses": {
    "<phone_number>": {
      "customerDetailInfo1": "<customerDetailInfo1>",
      "customerDetailInfo2": "<customerDetailInfo2>"
    }
  }
}

Request Body Fields

Field Type Required Description
phone_numbers array Yes Phone numbers.
phone_numbers[] string Phone number.
custom_attributes object No Custom attributes.
custom_attributes.<phone>.name string Customer name.
custom_attributes.<phone>.external_id string External customer identifier.
custom_attributes.<phone>.email string Customer email address.
built_in_responses object No Built-in responses.
built_in_responses.<phone>.customerDetailInfo1 string Built-in response value.
built_in_responses.<phone>.customerDetailInfo2 string Built-in response value.

Request Example

cURL Request Example
curl --location 'https://<pisanoEnvironment>/v1/sms_campaigns/<campaignID>/sms_sharings' \
--header 'Authorization: Token token=<API_TOKEN>' \
--header 'Content-Type: application/json' \
--data '{
  "phone_numbers": [
    "<phone_number>"
  ],
  "custom_attributes": {
    "<phone_number>": {
      "name": "<name>",
      "external_id": "<external_id>",
      "email": "<email>"
    }
  },
  "built_in_responses": {
    "<phone_number>": {
      "customerDetailInfo1": "<customerDetailInfo1>",
      "customerDetailInfo2": "<customerDetailInfo2>"
    }
  }
}'

Responses

200 OK

OK (Successful)

Response Fields

Field Type Required Description
status string Processing status returned for the SMS sharing request.
delivery_time string Delivery time returned for the request.
sidekiq_job_id string Identifier of the background job.
correlation_id string Identifier used to track and correlate the request.

Response Example

JSON Response Example
{
  "status": "enqueued",
  "delivery_time": "<delivery_time>",
  "sidekiq_job_id": "<sidekiq_job_id>",
  "correlation_id": "<correlation_id>"
}
400 Bad Request

An error occured.

Error Code
13000
Error Message
An error occured.
{"error_message":"An error occured","data":"An error occured","code":13000}
401 Unauthorized

Wrong authentication token.

Error Code
13001
Error Message
Wrong authentication token.
{"error_message":"Wrong authentication token","data":"Wrong authentication token","code":13001,"errors":null}
403 Forbidden

Permission denied.

Error Code
13013
Error Message
Permission denied.
{"error_message":"Permission denied","data":"Permission denied","code":13013,"errors":null}
404 Requested resource not found!

Additional Information

Rate Limits 20 requests/5 sec; 40/25 sec; 80/125 sec; 160/625 sec. On-premise throttle rules can be adjusted or removed.
Usage Limitations Best practice: trigger no more than 5,000 customers in a single request.