Send Alert
Create email alert with HTTP POST
Request
HTTP Method
POST
URL
https://api.thingspeak.com/alerts/send
URL Parameters
No available parameters
Headers
The ThingSpeak-Alerts-API-Key
and Content-Type
headers are required. The Accept
header is
optional.
Name | Priority | Description | Value Type |
---|---|---|---|
ThingSpeak-Alerts-API-Key | Required | Specify the alerts API key, which you can find in your profile. This key is different from the channel API and user API keys. | string |
Content-Type | Required |
| string |
Body Parameters
Name | Priority | Description | Value Type |
---|---|---|---|
subject | Optional | Specify the subject for the email message, up to 60 characters. | string |
body | Optional | Specify the body of the email message, up to 500 characters. | string |
Response
Success
202 Accepted
Error
You can use the Accept
header to control the detail provided
with error messages. Provide the Accept
header with value
application/json,application/problem+json
and the server
returns detailed error messages along with the standard HTTP response code.
For the full list of possible HTTP errors, see Error Codes.
Examples
Limitations
Users are limited to 2 alerts every 30 minutes. The rate limit is applied when the request is made, not when the email is sent. If you exceed the request limit, the API returns the response code 429.