curl -H "Authorization: Basic BASE64_ENCODED_PUBLIC_KEY_AND_PRIVATE_KEY" -X POST "trackdrive.com/api/v1/text_messages?message=Thanks+for+your+inquiry&to=%2B16053334444"
{
"status": 200,
"errors": {},
"text_message": {
"id": 812904581,
"from": "+18554550000",
"to": "+17190000000",
"message": "Thanks for your submission! A representative call in 60 seconds.",
"number_id": 147690000,
"lead_id": 11000635,
"provider_configuration_id": 12093,
"message_uuid": "SM42efa83003ab41f9977ff292f48375cc",
"ring_pool_id": null,
"schedule_id": 192840,
"status": "queued",
"error_code": null,
"created_at": "2019-08-29T15:58:21.850-04:00"
},
"checksum": "8e0fcaa8b1cc805d2323759e39a1a1ba",
"metadata": {
"root": "text_message"
}
}
Param name |
Description
Validations
|
---|---|
from Optional Blank Value Allowed |
Sending address (+E.164 formatted phone number.) Example: +18665550001 Validations:
|
to Optional Blank Value Allowed |
Receiving address (+E.164 formatted phone number.) Example: +18665550001 Validations:
|
lead_id Optional Blank Value Allowed |
Optional. Associate this text message with this lead. The lead's telephone number will be used as the Receiving address if “to” is not provided. Validations:
|
message Required |
Message body (i.e., content) as non-empty string. Example: Hello! Validations:
|
delivery_webhook_url Optional Blank Value Allowed |
Webhook to call when the message's status changes. Validations:
|
manual Optional Blank Value Allowed |
Pass true if this message is manually initiated by a human being in your application. When this is set to true Trackrive will skip checking if the “to” destination is on the DNC. Validations:
|
number_id Optional Blank Value Allowed |
Provide the sending address as an internal Trackdrive telephone number ID. Validations:
|
schedule_id Optional Blank Value Allowed |
Optional. If a lead exists on this schedule, this text message will be associated with it. If no lead currently exists, one will be created, and it will be added to this schedule. Validations:
|
offer_id Optional Blank Value Allowed |
Optional. Associate this text message with a matching lead on this offer. If no lead currently exists, one will be created on this offer. Validations:
|