Skip to main content
POST
Check a campaign message without sending it
Validation checks the key, campaign, template, parameters, media and data limits. For a campaign with Chosen per request, send the same usecase, to, and data as a send, and validation checks the usecase and its data fields. It does not check recipient consent or wallet balance. A usecase that is turned off fails validation with usecase_paused. A passing result does not guarantee that a later send succeeds. Validation is rate limited like a send. Failures use the shared problem format. Successful pricing uses camelCase fields, including quotedUsd.

Authorizations

Authorization
string
header
required

An API key (tars_sk_…) sent as Authorization: Bearer <key>. Each operation names the permission it needs. Create keys in Settings → Integrations → API keys.

Path Parameters

id
string
required

The id.

Required string length: 1 - 128

Body

application/json

One webhook campaign message.

to
string
required

E.164 phone number, or the number encrypted with your organization's incoming-numbers key (Settings → Integrations → Encryption keys), as AES-256-GCM v1.. or AES-256-CBC ciphertext. An encrypted value that can't be decrypted returns validation_failed with recipient_undecryptable.

params
object

Template parameters by name.

media
object

Media for the template's media header.

data
object

Data for the reply conversation, read as {{trigger.data.}}. On a usecase campaign, a key the usecase maps into its template appears in the message; the recipient never sees any other key. Up to 50 top-level keys of letters, digits and underscores that start with a letter or digit, 5 levels of nesting, and 8 KB. Nested keys use printable ASCII and can't start with $.

usecase
string

The usecase to send, for a campaign that defines usecases.

Response

The message would be sent at this price.

The price the message would be charged.

ok
any
required
pricing
object
required

The quote.