2

What is the best method for searching for and reading other users' public feeds? What API_KEYs to use?

I'm using WinInet on Windows to do HTTPS and call the "Search Feeds" and read "Historical Data" APIs. The API docs for both of these say they need an API_KEY.

"Search Feeds" doesn't seem to work if I just supply any old key from one of my devices. I seem to need a Master key with read permission. It also seems to work without a key if I give my login details to InternetConnect, but this doesn't seem like the way to go.

It seems odd to me that with a master key with read permission and no private access, the "Search Feeds" API lists my private feeds.

The list returned by "Search Feed" doesn't give any keys. Is there a way to discover read keys for a particular feed in the list?

I have the feeling I'm missing something!

a4o
  • 81
  • 4

1 Answers1

0

a4o, It sounds like you are getting the basics of it. You do need a Master API Key as opposed to a device specific one in order to use the global feed search function.

I just tested and you are correct that a non "private access" key will return private feeds that you own. It won't let you do anything with the feed with that key, but it does return the info. I will bring this bug to the attention of the Xively developers so they can sort it out.

To answer your question, as far as I can tell there is no way to get a device's read API key using a master key. The only time a key is returned is during the activation process for a device: https://xively.com/dev/docs/api/product_management/devices/activate_device/

Alternatively, you can list all of your feeds, but they will not return a feed or device that is associated with them: https://xively.com/dev/docs/api/security/keys/list_all_keys/

calumb
  • 1,051
  • 2
  • 10
  • 24