Skip to main content
New to Corsair? See API access, authentication, and error handling.

Account

balance

account.balance Read the account credit balance Risk: read
Input: empty object Output

pricing

account.pricing List per-destination prices for SMS, number lookup or verify, optionally for one MCC/MNC pair Risk: read
Input Output

Lookup

request

lookup.request Look up a number’s original and current carrier and porting status, paid from prepaid credit; synchronous without a callback URL Risk: read
Input POST /rest/2/nl. Synchronous without mocean_nl_url; with it, Mocean sends the result as a PUT to that URL, which the plugin does not receive. Output

Sms

reportConversion

sms.reportConversion Tell Mocean whether a sent SMS reached the user (conversion tracking for OTP routes) Risk: write
Input Output

send

sms.send Send an SMS to up to 500 receivers, charged per destination; the response has a status and msgid per receiver Risk: destructive
Input POST /rest/2/sms with a form-encoded body. Mocean answers HTTP 202 with { messages: [{ status, receiver, msgid }] }; each row can fail on its own. A request with no receiver answers HTTP 400 with the same shape. Output

status

sms.status Read a sent message’s final status (success, failed, expired, pending or not found) and the credit it took Risk: read
Input GET /rest/2/report/message. message_status is 1 success, 2 failed, 3 expired, 4 pending, 5 not found (an unknown msgid answers 5, not an error). Output

Templates

create

templates.create Create a WhatsApp message template and submit it to Meta for review Risk: write
Input
Output

delete

templates.delete Delete a WhatsApp message template, every language of it or one by ID; cannot be undone Risk: destructive
Input DELETE /template/whatsapp/message_templates?name=...&hsm_id=.... Without hsm_id every language of the template is deleted. Output

edit

templates.edit Edit a WhatsApp message template; Meta reviews it again Risk: write
Input
Output

get

templates.get Read one WhatsApp message template Risk: read
Input Output

list

templates.list List WhatsApp message templates, filtered by name, status, category or language Risk: read
Input Output

Verify

check

verify.check Check the code a user gave you against a verify request; Mocean allows three wrong attempts Risk: write
Input POST /rest/2/verify/check. An expired or unknown reqid answers HTTP 404 with body status 17; a wrong code is status 16. Output

request

verify.request Send a verification code by SMS, charged per attempt; keep the reqid for check and resend Risk: destructive
Input Output

requestTelegram

verify.requestTelegram Send a verification code to a Telegram chat through your bot; keep the reqid for check Risk: destructive
Input Output

resend

verify.resend Resend the code of a verify request by SMS, charged per attempt Risk: destructive
Input Output

Voice

dial

voice.dial Call one or more numbers and run a Mocean Command flow (say, play, collect, record, dial), charged per call Risk: destructive
Input POST /rest/2/voice/dial. mocean_command is sent as one JSON string field, as Mocean expects.
Output

hangup

voice.hangup Hang up a call in progress Risk: destructive
Input Output

recording

voice.recording Download the audio recording of a call Risk: read
Input Output

Whatsapp

downloadMedia

whatsapp.downloadMedia Download media a WhatsApp user sent to your business number Risk: read
Input Output

send

whatsapp.send Send a WhatsApp message (text, media, template, interactive, location or contacts) from your business number Risk: destructive
Input
Output