0

Posting data to a feed via browser link
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Posting data to a feed via browser link

by BjarneBurkal on Sat Dec 16, 2017 7:02 am

Hi

I would like to add data to a feed via a browser. I can get the API to return the contents of the feed, but i need help to add a value to the feed.

i tried entering the following in chrome, but it did not add "tester" to my feed.
https://io.adafruit.com/api/v2/USERNAME ... lue=Tester

Can anyone help me in the right direction?

BjarneBurkal
 
Posts: 1
Joined: Sat Dec 16, 2017 5:37 am

Re: Posting data to a feed via browser link

by NIF on Wed Dec 27, 2017 1:29 pm


NIF
 
Posts: 4
Joined: Tue Dec 26, 2017 12:13 pm

Re: Posting data to a feed via browser link

by abachman on Thu Dec 28, 2017 1:45 pm

Hi Bjarne!


First off, be extremely careful publishing your Adafruit IO key anywhere, even as part of a URL on a webpage you control. Sharing your key with someone means they can access your Adafruit IO account to create or delete feeds, data, groups, triggers, dashboards, etc. That's probably not something you want. Right now, making a feed "public" will only allow anonymous users to read from it, not write to it.

Unfortunately, to avoid leaking your IO key, you'll have to build a tiny web service to keep the key secret and do the actual publishing for you. I have an example written in Ruby here: https://github.com/abachman/adafruit-io-shared-client if you want to take a look. That lets you keep your IO key secret on the server that you control, which is where the actual requests to IO will originate from.

What kind of project are you working on?


- Adam

abachman
 
Posts: 131
Joined: Mon Feb 01, 2010 12:48 pm

Please be positive and constructive with your questions and comments.