Help, I cant get the examples for thingspeak to work | GitHub Installation | Forum

Avatar

Please consider registering
Guest

sp_LogInOut Log In sp_Registration Register

Register | Lost password?
Advanced Search

— Forum Scope —






— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Feed sp_TopicIcon
Help, I cant get the examples for thingspeak to work
No permission to create posts
April 7, 2014
5:37 am
Avatar
chrisjmears

Gold
Members
Forum Posts: 54
Member Since:
April 26, 2013
sp_UserOfflineSmall Offline

when i post

https://api.thingspeak.com/talkbacks/122/commands/?api_key=MYAPIKEY&command_string=testing

I would expect upon refreshing the talkback page to se a command called testing but nothing appears. I get no confirmation message when making my post from the address bar. Have I got something wrong with the URL?

April 7, 2014
10:50 am
Avatar
lee

Admin
Forum Posts: 457
Member Since:
March 14, 2011
sp_UserOfflineSmall Offline

Hi,

Your URL looks fine, but your HTTP method will be GET if you enter that URL in the browser's address bar. You need to use the POST method for this to work properly.

lee

April 7, 2014
3:36 pm
Avatar
chrisjmears

Gold
Members
Forum Posts: 54
Member Since:
April 26, 2013
sp_UserOfflineSmall Offline

Thanks lee but the instructions seemed to suggest its a Get

From the documentation

List All TalkBack Commands
To show all of a TalkBack's commands, send an HTTP GET to https://api.thingspeak.com/talkbacks/TALKBACK_ID/commands, replacing TALKBACK_ID with the actual ID of your TalkBack.

Am I wrong or do the docs need revising.

April 7, 2014
4:31 pm
Avatar
lee

Admin
Forum Posts: 457
Member Since:
March 14, 2011
sp_UserOfflineSmall Offline

Hi,

The documentation is correct, if you are trying to add a command then you should use HTTP POST, but if you are trying to list all of your commands then you should use HTTP GET. The URLs for both of these actions are the same, which may be a little confusing, but we wanted to make this fully REST compliant: https://en.wikipedia.org/wiki/Representational_State_Transfer#Applied_to_web_services .

lee

April 8, 2014
3:35 am
Avatar
chrisjmears

Gold
Members
Forum Posts: 54
Member Since:
April 26, 2013
sp_UserOfflineSmall Offline

Sorry lee, I see now. I read it wrong thanks

Forum Timezone: America/New_York

Most Users Ever Online: 166

Currently Online:
13 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

rw950431: 272

Vinod: 240

piajola: 95

turgo: 70

vespapierre: 63

Adarsh_Murthy: 62

Member Stats:

Guest Posters: 1

Members: 8665

Moderators: 1

Admins: 2

Forum Stats:

Groups: 3

Forums: 14

Topics: 1600

Posts: 5760

Newest Members:

khanhNguyen_CT, susyburr, quijano__, meosuckhoe, briskpanda, Dejw0089

Moderators: cstapels: 460

Administrators: Hans: 405, lee: 457