questionFAQ

Find answers to some frequently asked questions about using the MTA API.

circle-info

Ensure you are authenticated before making the below example requests to the Mobile Text Alerts API.

How can I send a single “Hello World” message to myself?

You can send a message to your personal phone number for testing and verification. To do this, send a request to the /send endpoint with the phone number in the subscribers field and the test message in the message field.

Example request:

curl --location 'https://api.mobile-text-alerts.com/v3/send' \
--data '{"subscribers": [1112223333],"message": "Hello World"}'

See Send a Message to learn more.

Can the MTA API be used to send 2FA/MFA verification codes?

Yes, the Mobile Text Alerts SMS Verification API provides an easy way to manage SMS multi-factor authentication workflows within your application. There are endpoints for verification code generation, SMS message delivery, and validation of user-supplied codes. See Generate and validate 2FA / MFA codes via SMS to learn more.

What information is available in response to an API call to send a message?

A successful request will provide the following information in the response:

  • messageId - the unique ID of the message

  • totalSent - the total number of message recipients

  • totalFailedInternationalRecipients - the total number of failed recipients with non-US phone numbers

  • message - a summary of request results

See How to build a sample request to the API to learn more about the request and response data for the /send endpoint.

How do I schedule a message to be sent in the future?

You can indicate when a message will be sent by including the scheduledDate request field when calling the /send endpoint. This allows you to use ISO 8601 formatarrow-up-right to specify the exact send date and time.

Enter the time to send the message in the scheduledDate field as part of the request.

Example request:

Visit Schedule Message Sends to learn more.

Can I refer to my subscribers by name in the message I send to them?

Yes, you can refer to subscribers by name in your message by using a Liquid template variable in the properties field. The properties field contains a map between individual subscribers and the values assigned to those variables.

In the example request below, the firstName variable references the recipient name. Each recipient name is defined in properties for each subscriber number.

Example request:

Visit Properties field for custom variables in messages to learn more.

How can I be notified when my subscribers reply to a message?

To receive message reply notifications, you must configure a message-reply webhook. Once configured, when MTA receives an inbound message from a provider, it will post the inbound message to this endpoint.

See Receive and Reply to Messages to learn more.

How can I import all of my subscribers?

Subscribers can be added with the Create Subscriber API Endpoint, but for large imports, the Bulk Create Subscribers endpoint is recommended. This reduces request round-trip time and API call volume, which helps avoid rate limits.

How can I see the status of a sent message?

You can check the delivery status of your message sends with Mobile Text Alerts in two different ways:

  • Call the List Deliveries API endpoint

    • This is best for reporting/analytics of settled message data. This only includes the most recent status for a message.

  • Configure the delivery-status webhook

    • This is best for real-time status updates. With this webhook, you can receive the full status history from the moment of send to the final result status (delivered, rejected, etc.).

Can I send iMessages to my subscribers?

Yes, if you're interested in sending iMessages and want to participate in our beta program, please reach out to your account manager to notify them of your interest.

See Send an iMessage to learn more.

Last updated

Was this helpful?