Deprecated: Function get_magic_quotes_gpc() is deprecated in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 99
Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 619
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 832
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 839
# Messaging API Overview
The Programmable Messaging REST API helps you add robust messaging capabilities to your applications.
Use the REST API to complete the following activities:
* [Send messages](#send-messages)
* [Fetch, list, update, and delete messages](#fetch-list-update-and-delete-messages)
* [Fetch, list, and delete media](#fetch-list-and-delete-media)
* [Manage your short codes](#manage-your-short-codes)
* [Track message feedback](#track-message-feedback)
* [Manage your Messaging Services](#manage-your-messaging-services)
* [Check SMS pricing by country](#check-sms-pricing-by-country)
* [Retrieve a list of deactivated US phone numbers](#retrieve-a-list-of-deactivated-us-phone-numbers)
* [Verify your toll-free number complies with regulations](#verify-if-your-toll-free-number-complies-with-regulations)
## Base URLs
To ensure data privacy, Twilio serves its APIs over HTTPS.
Messaging-related APIs use three base URLs:
### Twilio API base URL
The following API resources that process SMS messages point to the Base URL of `https://api.twilio.com/2010-04-01`.
* [Messages resource](/docs/messaging/api/media-resource)
* [Feedback subresource](/docs/messaging/api/message-feedback-resource)
* [Media subresource](/docs/messaging/api/media-resource)
The following API resources that manage [Messaging Services](/docs/messaging/services) point to `https://messaging.twilio.com/v1`.
* [Services resource](/docs/messaging/api/service-resource)
* [PhoneNumbers subresource](/docs/messaging/api/phonenumber-resource)
* [Shortcodes subresource](/docs/messaging/api/services-shortcode-resource)
* [AlphaSenders subresource](/docs/messaging/api/alphasender-resource)
* [DestinationAlphaSenders subresource](/docs/messaging/api/destination-alphasender-resource)
* [ChannelSenders subresource](/docs/messaging/api/messaging-service-channelsender-resource)
The following API resources that report on deactivated phone numbers and process toll-free verification requests also point to `https://messaging.twilio.com/v1`.
* [Deactivations resource](/docs/messaging/api/deactivations-resource)
* [Verifications resource](/docs/messaging/api/tollfree-verification-resource)
The API resource that reports on [per-country SMS pricing](/docs/messaging/api/pricing) points to the `https://pricing.twilio.com/v1` base URL.
## Authentication
To authenticate requests to the Twilio APIs, Twilio supports [HTTP Basic authentication](https://en.wikipedia.org/wiki/Basic_access_authentication). Use your *API key* as the username and your *API key secret* as the password. You can create an API key either [in the Twilio Console](/docs/iam/api-keys/keys-in-console) or [using the API](/docs/iam/api-keys/key-resource-v1).
**Note**: Twilio recommends using API keys for authentication in production apps. For local testing, you can use your Account SID as the username and your Auth token as the password. You can find your Account SID and Auth Token in the [Twilio Console](https://www.twilio.com/console).
Learn more about [Twilio API authentication](/docs/usage/requests-to-twilio).
```bash
curl -G https://api.twilio.com/2010-04-01/Accounts \
-u $TWILIO_API_KEY:$TWILIO_API_KEY_SECRET
```
## Use the Programmable Messaging API
> \[!NOTE]
>
> Twilio monitors messages to prevent content violating the [Acceptable Use Policy](https://www.twilio.com/en-us/legal/aup) (AUP)*.* This helps to ensure that Twilio Messaging is seen as a trustworthy, high engagement channel and will not slow down the delivery of messages.
>
> If a message you send has violated the AUP, it will be returned and you will receive an error code which identifies the necessary changes you need to make before sending it again.
### Send messages
To send an outbound message, send a `POST` request to the [Messages resource](/docs/messaging/api/message-resource).
* To [send media messages](/docs/messaging/tutorials/how-to-send-sms-messages), use the `MediaUrl` parameter in the request.
* To [schedule an outbound Message](/docs/messaging/features/message-scheduling) to be sent in the future, use the `ScheduleType` and `SendAt` parameters in the request.
* To [send messages with shortened links](/docs/messaging/features/link-shortening), use the `ShortenUrls` parameter in the request.
* **Note:** This feature is available only if you are using [Messaging Services](/docs/messaging/services).
Looking for information on how to receive and reply to messages? [Check out the Receive and Reply to Messages Guide](/docs/messaging/tutorials/how-to-receive-and-reply).
### Fetch, list, update, and delete messages
Use the [Messages resources](/docs/messaging/api/message-resource) to fetch, list, and delete Messages associated with your Account.
Redact messages by updating a Message resource.
### Fetch, list, and delete media
Twilio creates a [Media subresource](/docs/messaging/api/media-resource) when an incoming or outgoing Message resource contains media.
You can fetch, list, and delete Media subresources.
### Manage your short codes
Fetch, list, and update your Account's short codes with the [ShortCodes subresource](/docs/messaging/api/short-code-resource).
### Track message feedback
Track user-reported outcomes of Messages with the [Feedback subresource](/docs/messaging/api/message-feedback-resource).
### Manage your Messaging Services
Create, fetch, read, update, and delete Messaging Services with the [Services resource](/docs/messaging/api/service-resource).
Manage your Messaging Services' senders with:
* [ShortCode subresource](/docs/messaging/api/services-shortcode-resource)
* [AlphaSenders subresource](/docs/messaging/api/alphasender-resource)
* [DestinationAlphaSenders subresource](/docs/messaging/api/destination-alphasender-resource)
* [PhoneNumbers subresource](/docs/messaging/api/phonenumber-resource)
* [ChannelSenders subresource](/docs/messaging/api/messaging-service-channelsender-resource)
### Check SMS pricing by country
Check inbound and outbound SMS message pricing with the [Messaging Countries subresources](/docs/messaging/api/pricing) of the Pricing API.
### Retrieve a list of deactivated US phone numbers
Fetch a list of all US phone numbers that were deactivated on a given day with the [Deactivations resource](/docs/messaging/api/deactivations-resource).
### Verify if your toll-free number complies with regulations
Show your toll-free number complies with US and Canadian SMS regulations. Submit, fix, and remove toll-free verification (TFV) requests with the [Verifications resource][]
[Verifications resource]: /docs/messaging/api/tollfree-verification-resource
## Additional resources
* [SMS developer quickstart](/docs/messaging/quickstart)
* [Check out the Blog for inspiration](https://www.twilio.com/blog/search-results?search=sms) on how you can build Messaging applications with a variety of languages and tools.
* Get started with [toll-free verification][tfv-start].
* For help troubleshooting your Programmable Messaging application, check out the docs on [Debugging Common Issues](/docs/messaging/guides/debugging-common-issues) and [Debugging Tools](/docs/messaging/guides/debugging-tools).
* [Learn more about Twilio's Global Infrastructure](/docs/global-infrastructure), which allows you to control where your application's Twilio-related data is routed, processed, and stored.
[tfv-start]: /docs/messaging/compliance/toll-free/api-onboarding