Send Correspondence (v1)
Description
Use this endpoint to send an email or SMS to a customer or lead, using a notice template already configured in Storman.
Unlike Create Correspondence, this API will actually send the email or sms using the facility SMS account or SMTP settings
HTTP Request
POST YOUR_STORMAN_CLOUD_URi/api/v1/facility/YOUR_FACILITY_CODE/correspondence/send
Request parameters
Parameter | Type | Description | Required |
---|---|---|---|
source_system | text | The source system/your integration that triggered the send, of this correspondence: website or online store | Yes |
record_type | text | The entity you want to send something to: lead or reservation or AGREEMENT or recurring_sale | Yes |
reference_no | text | The reference nuumber of the entity you would like to send this to:
| Yes |
type | text | The type of correspondence to send: email or sms | Yes |
notice_name | text | The name of the notice to send to the Storman customer:
For a list of valid notices, please see List Correspondence (v1) | Yes |
Request example
// sending an email notice to an agreement
{
"source_system": "MOBILE APP",
"record_type": "AGREEMENT",
"reference_no": "000002392",
"notice_name": "Late 45 - Notice to vacate",
"type": "EMAIL"
}
// sending an sms notice to a reservation
{
"source_system": "MOBILE APP",
"record_type": "RESERVATION",
"reference_no": "00003699",
"notice_name": "Thank you for your enquiry",
"type": "SMS"
}
Response parameters
Parameter | Type | Description |
---|---|---|
success | boolean | Whether the request was processed successfully or not |
message | text | A custom message for this action |
data | object |
|
Response example
{
"success": true,
"message": "Correspondence successfully sent",
"data": {
"correspondence_id": -827
}
}