Create a channel within matlab | MATLAB | 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
Create a channel within matlab
No permission to create posts
July 18, 2016
3:34 pm
Avatar
jemapel
New Member
Members
Forum Posts: 4
Member Since:
October 23, 2014
sp_UserOfflineSmall Offline

Is this possible? I'm able to do so outside of Matlab by sending a POST request to 

But I'd like to do so within Matlab so I'm seeking another method. 

July 18, 2016
4:56 pm
Avatar
jvasudev

MathWorks
Members
Forum Posts: 12
Member Since:
April 29, 2016
sp_UserOfflineSmall Offline

Hi ,

 

You can use the following MATLAB code as a template to send a POST request to create a channel from within MATLAB, 

UserApiKey = 'xxxxxxxxx'; % This is your account API key found on the Account -> My Account Page
url = 'https://api.thingspeak.com/channels.json'; 
data = ['api_key=',UserApiKey, '&name=test channel']; % These are the parameters for the POST request
response = webwrite(url,data) % Using webwrite command to send a POST request

 

You can visit the https://www.mathworks.com/help/thingspeak/queue-commands-using-the-talkback-app-from-matlab.html for an example as how to use MATLAB commands to send GET and POST requests. 

 

Forum Timezone: America/New_York

Most Users Ever Online: 114

Currently Online: samdavies
13 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

rw950431: 261

Vinod: 196

piajola: 85

turgo: 70

vespapierre: 63

Adarsh_Murthy: 62

Member Stats:

Guest Posters: 1

Members: 5703

Moderators: 0

Admins: 2

Forum Stats:

Groups: 4

Forums: 17

Topics: 1313

Posts: 4565

Newest Members:

Lakshmanaprakash S B, bettetj60, ronnievw3, bessiesj18, Pavan kumar, Williampup

Administrators: Hans: 387, lee: 457