Send preview

Text a preview of a campaign message to one phone number.

POST https://cotlet.dev/api/v1/postscript/campaigns/{campaign_id}/previews

write Confirm

Uses Send Preview next to the message in Flow Builder and the phone number you give. It reaches a real phone and counts as usage, so use your own number. Returns sent once Postscript accepts it. By default you confirm each call; you can switch that off for this tool.

Parameters

Parameters: send_preview
NameTypeDescription
campaign_id string required string Campaign from list_campaigns or create_campaign.
phone string required string Phone number to text.

Request

cURL
curl -X POST https://cotlet.dev/api/v1/postscript/campaigns/campaign_8c41d2/previews \
  -H "Authorization: Bearer $COTLET_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"phone":"phone"}'
Python
result = client.call("postscript", "send_preview", {"campaign_id":"campaign_8c41d2","phone":"phone"})
Node.js
const result = await cotlet.call('postscript', 'send_preview', {"campaign_id":"campaign_8c41d2","phone":"phone"});
CLI
cotlet call postscript send_preview --data '{"campaign_id":"campaign_8c41d2","phone":"phone"}'

Example response

JSON

{
  "campaign_id": "f_51877",
  "phone": "+1 555 0100",
  "status": "sent"
}

Sign in once. Your agent does the rest.

Sign up and add the apps you need. Free 7-day trial with 2,000 credits, no card needed.