Recipients
A recipient is an organization’s customer and a target for a task, that is, whom the task is being delivered to.
Create recipient
Body parameters
Name | Type | Description |
---|---|---|
name | string | The recipient’s complete name. |
phone | string | A unique, valid phone number as per the organization’s country if there's no leading + sign. If a phone number has a leading + sign, it will disregard the organization's country setting. |
notes | string | Optional. Notes for this recipient: these are global notes that should not be task- or destination-specific. For example, "Customer since June 2012, does not drink non-specialty coffee". |
skipSMSNotifications | boolean | Optional. Whether this recipient has requested to not receive SMS notifications. Defaults to false if not provided. |
skipPhoneNumberValidation | boolean | Optional. Whether to skip validation of this recipient's phone number. An E.164-like number is still required (must start with +), however the API will not enforce any country-specific validation rules. |
curl -X POST "https://store.bponi.com/api/v2/recipients" \
-u "cd3b3de84cc1ee040bf06512d233719c:" \
-d '{"name":"Boris Foster","phone":"650-555-1133","notes":"Always orders our GSC special"}'
2
3
{
"id": "VVLx5OdKvw0dRSjT2rGOc6Y*",
"organization": "yAM*fDkztrT3gUcz9mNDgNOL",
"timeCreated": 1455156665000,
"timeLastModified": 1455156665390,
"name": "Boris Foster",
"phone": "+16505551133",
"notes": "Always orders our GSC special",
"skipSMSNotifications": false,
"metadata": []
}
2
3
4
5
6
7
8
9
10
11
Bponi Storeopen in new window utilizes Google's phone number validation library to verify all phone numbers entered. Use skipPhoneNumberValidation in your HTTP request to skip validation.
Update recipient
curl -X PUT "https://store.bponi.com/api/v2/recipients/VVLx5OdKvw0dRSjT2rGOc6Y*" \
-u "cd3b3de84cc1ee040bf06512d233719c:" \
-d '{"name":"Neiman Runtilly"}'
2
3
{
"id": "VVLx5OdKvw0dRSjT2rGOc6Y*",
"organization": "yAM*fDkztrT3gUcz9mNDgNOL",
"timeCreated": 1455156665000,
"timeLastModified": 1455156665741,
"name": "Neiman Runtilly",
"phone": "+16505551133",
"notes": "Always orders our GSC special",
"skipSMSNotifications": false,
"metadata": []
}
2
3
4
5
6
7
8
9
10
11
Find recipient
You can search for recipients by name or phone. Note that finding a recipient requires that there be an exact match for the target property provided. Names are case insensitive and must be properly encoded, while phones will be automatically E.164-formatted prior to performing the lookup as per your organization's country setting.
To find a recipient by name, the endpoint format is /name/:name, for example, /name/jony%20chives. Similarly, to find a recipient by phone, the format is /phone/:phone, for example, /phone/4155521837.
curl -X GET "https://store.bponi.com/api/v2/recipients/name/neiman%20runtilly" \
-u "cd3b3de84cc1ee040bf06512d233719c:"
2
{
"id": "7tuqrtwo75UlcJFCzDk7Clfk",
"organization": "yAM*fDkztrT3gUcz9mNDgNOL",
"timeCreated": 1455142309000,
"timeLastModified": 1455142309695,
"name": "Neiman Runtilly",
"phone": "+16503201133",
"notes": "Always orders our GSC special",
"skipSMSNotifications": false,
"metadata": []
}
2
3
4
5
6
7
8
9
10
11
If the recipient was created without validation, you may provide the query parameter skipPhoneNumberValidation as true in order to bypass validation.
Get single recipient
When attempting to access a recipient endpoint that does not belong to your organization, an error message will be thrown stating that the request is outside of your permission scope.
curl -X GET "https://store.bponi.com/api/v2/recipients/VVLx5OdKvw0dRSjT2rGOc6Y*" \
-u "cd3b3de84cc1ee040bf06512d233719c:"
2
{
"id": "VVLx5OdKvw0dRSjT2rGOc6Y*",
"organization": "yAM*fDkztrT3gUcz9mNDgNOL",
"timeCreated": 1455156665000,
"timeLastModified": 1455156665741,
"name": "Neiman Runtilly",
"phone": "+16505551133",
"notes": "Always orders our GSC special",
"skipSMSNotifications": false,
"metadata": []
}
2
3
4
5
6
7
8
9
10
11