Skip to main content

How it works

The Texting endpoints let you send one-off SMS messages, either from templates we configure for your account or as free-form text you write yourself. Your account is identified by your collectwise_key API key, sent in the header on every request.
Texting must be enabled for your organization before these endpoints will respond. If you receive a 403 on every call, contact us to have your organization enabled.
A typical integration is:
1

Discover templates

Call List SMS Templates to see the templates available to your account and the placeholder variables each one expects.
2

(Optional) Preview segments

Call Calculate SMS Segments to see how many SMS segments a message or rendered template will use, before sending.
3

Send

Call Send a Text with a destination, a debtorId, and either a templateId plus a variables object filling in every placeholder, or a free-form message. A 200 means the message was accepted and queued, and returns a messageId.
4

Check status

Poll Get Text Status with the messageId. Delivery reports arrive asynchronously, so check after a short delay.
5

Receive replies

Register the Communications webhook to have every reply pushed to you in real time, or poll List Text Messages for the thread.

Free-form texts

Instead of a templateId and variables, you can send a free-form message of up to 1600 characters, delivered exactly as written. Send exactly one of the two. A request with both, or with neither, is rejected with 400. Free-form is enabled per organization and off by default; without it, message returns 403 Free-form texts are not enabled for this organization.
Free-form text bypasses the carrier’s pre-approved template copy, so compliance wording is entirely your responsibility. Include your opt-out language (for example, “Reply STOP to opt out”) and any agency identification your messages require. We do not append anything to a free-form message.

Templates and variables

Each template has a templateId and a message body containing {placeholder} tokens. The placeholders array on a template lists exactly which keys you must supply in variables when sending. If any placeholder is left unresolved, the send fails with 400 rather than texting a literal {placeholder} to the recipient. Placeholders use single curly braces and are matched exactly first, then normalized (case-insensitive, ignoring # and spaces), so {FirstName}, {#FileNumber}, and {Variable Name} all work.

Segments and encoding

SMS messages are billed and split into segments by character count and encoding, matching the Twilio segment calculator:
  • GSM-7: 160 characters in a single segment, 153 per segment when the message spans multiple segments.
  • UCS-2: 70 characters single, 67 per segment when multi-part. Any character outside the GSM-7 set (emoji, smart quotes, most CJK) forces the entire message to UCS-2.
  • The extended GSM-7 characters { } [ ] ~ \ | ^ € cost two units each.

Delivery status

A message moves through QueuedSentDelivered, or ends in Rejected / Failed / Undelivered. For failed messages, failureClassification indicates whether a retry is worthwhile:

Receiving replies

Consumer replies arrive through the Communications webhook, which carries the reply text and the id of the message being answered. You can also read the thread on demand with List Text Messages.

Rate limits

  • Send: 10 requests per minute per organization.
  • Reads (templates, segments, status, messages): 60 requests per minute per organization.
Exceeding a limit returns 429 with a Retry-After header.