Contents |
URL
https://api.geoloqi.com/1/layer/subscribe/:layer_id
Description
Subscribe the user to a specified layer.
Supported Request Methods
POST
Parameters
- user_id OptionalIf no user ID is provided, then the authenticating user will subscribe to the layer. If you provide an application access token, you can get your application to subscribe users it has created to the layer.
Example Request
Subscribe the current user to the layer:
curl -s -H "Content-Type: application/json" \ -H "Authorization: OAuth YOUR_USER_ACCESS_TOKEN" \ -X POST https://api.geoloqi.com/1/layer/subscribe/12345
curl -s -H "Content-Type: application/json" \ -H "Authorization: OAuth YOUR_APPLICATION_ACCESS_TOKEN" \ -X POST https://api.geoloqi.com/1/layer/subscribe/12345?user_id=54321
Example Response
{ "subscribed": "1", "date_subscribed": "2012-05-25 13:00:00" }