Update TalkBack Command

Update command in TalkBack queue

Request

HTTP Method

PUT

URL

https://api.thingspeak.com/talkbacks/<talkback_id>/commands/<command_id>.<format>

Input Arguments

NameDescription

<talkback_id>

(Required) TalkBack ID, specified as a positive integer.

<command_id>

(Required) Command ID for the command of interest, specified as a positive integer.

<format>

Format for the HTTP response, specified as blank, json, or xml.

Example: https://api.thingspeak.com/talkbacks/12345/commands/23456.json

Body Parameters

NameDescriptionValue Type
api_key

(Required) API key for this specific instance of TalkBack. The TalkBack key is different from the channel and user API keys.

string

Content-Type

application/x-www-form-urlencoded

Response

Success

HTTP Status Code

200 OK

Body

The example responses are based on this change in a sample TalkBack queue.

 Text Example

 JSON Example

 XML Example

Error

For the full list, see Error Codes.

Examples

collapse all

You can use POSTMAN to try out your HTTP requests using the RESTful API for ThingSpeak. This example shows how to add a TalkBack command to an existing queue using POSTMAN.

Change the TalkBack command BUCKLESHOE to an existing TalkBack queue with the TalkBack ID 15200362.

PUT https://api.thingspeak.com/talkbacks/23341/commands/15200362.xml
    api_key=XXXXXXXXXXXXXXXX
    command_string=CLOSEDOOR
    

  1. In POSTMAN, select PUT from the drop-down list of HTTP verbs, and enter https://api.thingspeak.com/talkbacks/TALKBACK_ID/commands/ in the address bar. Change TALKBACK_ID to your TalkBack ID.

  2. Enter the parameter api_key and your TalkBack API key, which is found in Apps > TalkBack> YOUR TALKBACK NAME.

  3. Enter the additional parameters and values:

    • api_key, Value: XXXXXXXXXXXXXXXX

    • command_string, Value: CLOSEDOOR

The response is in XML format. Note the server response value of 200 OK, which indicates successful update of your TalkBack command.

The updated command is now available in your TalkBack queue.