You want to start using Mailjet's SMS service and are not sure where to begin? We've got your back - please follow these essential steps to get started.
Having credits in your SMS Wallet is a requirement for sending SMS. If you do not yet have funds in your wallet, you can deposit directly in the Mailjet app.
Accepted currencies are USD, EUR and GBP and the minimum deposit amount is 1 unit in the respective currency.
Keep in mind that due to necessary verification procedures there is a 48-hour waiting period before your wallet is activated. See Payments & Billing for additional information.
When using the Mailjet SMS API, the authentication of your requests is done using Bearer Tokens. Bearer Tokens are a compact, URL-safe means of representing claims to be transferred between two parties.
To generate a new token, please go Mailjet's SMS Dashboard and click on 'Generate a token'.
Keep in mind that for security reasons a token is only displayed once. Make sure to save the token value locally before closing the modal window.
Any additional information can be found in our detailed guide.
Your balance has just been credited and your account activated - now let's send your first SMS.
The endpoint to be called is https://api.mailjet.com/v4/sms-send.
You must be authenticated with a Bearer Token. That's a different method from the one used for Emails - your access token must be included in the Authorization header of your request.
cURL Example:
curl -X POST \
https://api.mailjet.com/v4/sms-send \
-H "Authorization: Bearer $MJ_TOKEN" \
-H 'content-type: application/json' \
-d '{
"From": "InfoSMS",
"To": "+33600000000",
"Text": "Hello World!"
}'
Fill your sending information in the payload. Three properties are required:
From
: the sender of the SMSTo
: the telephone number of the recipientText
: the content of the message