POST /v1/sms/test
POST
/v1/sms/test
const url = 'https://seu-endereco-da-api/v1/sms/test';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"to":"example","body":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://seu-endereco-da-api/v1/sms/test \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "to": "example", "body": "example" }'Permissão que a Chave de acesso precisa: Criar e disparar campanhas (campaigns:manage).
Authorizations
Seção intitulada “Authorizations”Request Bodyrequired
Seção intitulada “Request Bodyrequired”Media typeapplication/json
object
to
required
string
body
required
string
Example generated
{ "to": "example", "body": "example"}Responses
Seção intitulada “Responses”Media typeapplication/json
object
segments
required
number
costMicros
required
What the test cost, in millionths of a real
number
Example generated
{ "segments": 1, "costMicros": 1}The sms balance does not cover the message
The sms channel is not connected
No price is published for sms
The sms provider refused the message