Calculate SMS segments
Changed onReturns how many SMS segments a message will use, matching the Twilio segment calculator. Provide either a raw message, or a templateId with variables (the template is rendered first, then counted). This endpoint does not send anything.
Request
- Base URLhttps://collectwiseapi.com
- URLhttps://collectwiseapi.com/text/segments
- AuthAPI key in header collectwise_key
Headers
Required together with x-cw-signature when signing is enabled for this key or organization. POST /security/verify also requires signing whenever a usable secret exists. Canonical Unix seconds, within ±300 seconds. See API Access for CW1 signing.
CW1 HMAC-SHA256 signature: v1= followed by 64 lowercase hex digits. Use the decoded 32-byte signing secret and exact request bytes. See API Access.
Request body
Response
Segment usage for the message.
Changes
- breaking
the response property
became optional for the status - info
added the new optional
headerrequest parameterx-cw-signature - info
added the new optional
headerrequest parameterx-cw-timestamp
- breaking