Write Data
Update channel data with HTTP GET or POST
Request
HTTP Method
POST
or GET
URL
https://api.thingspeak.com/update.
<format>
URL Parameters
Name | Description |
---|---|
| (Required) Format for the HTTP response, specified as
blank, |
Example:https://api.thingspeak.com/update.json
Body
Name | Description | Value Type |
---|---|---|
api_key | (Required) Write API Key for this specific channel. You can also send the Write API Key by using a THINGSPEAKAPIKEY HTTP header. The Write API Key is found on the API Keys tab of the channel view. | string |
field<X> | (Optional) Field X data, where X is the field ID | any |
lat | (Optional) Latitude in degrees, specified as a value
between | decimal |
long | (Optional) Longitude in degrees, specified as a value
between | decimal |
elevation | (Optional) Elevation in meters | integer |
status | (Optional) Status update message. | string |
created_at | (Optional) Date when feed entry was created, in ISO
8601 format, for example: | datetime |
Content-Type
Content-Type is required only for the POST method, not for the GET method.
application/x-www-form-urlencoded
for most updates.
application/json
for updates in JSON format.
Response
Error
For the full list, see Error Codes.
Limitations
All timestamps must be unique. You cannot write new data using timestamps that match existing data in the channel.