Create trigger doesn't work
  • We tried creating a trigger from terminal and listing it. Calling trigger/create showed it was correctly created but after calling trigger/list, its empty.

    Please see the following command that was used

    # simulator
    curl -H "Content-Type: application/json" -H "Authorization: OAuth dffc-1043954ec0bdff5db77b3127f2d80b10dd074826" -d '{"type": "message", "text": "Welcome to Powells Books", "latitude": "37.33233261108398", "longitude": "-122.0312194824219", "radius": "3218", "key": "test_key"}' https://api.geoloqi.com/1/trigger/create

    curl -H "Content-Type: application/json" -H "Authorization: OAuth dffc-1043954ec0bdff5db77b3127f2d80b10dd074826"  https://api.geoloqi.com/1/trigger/list


    Token was generated after initializing geoloqi on iOS simulator.


    Thanks
  • 2 Comments sorted by
  • The trigger/list API method will only return a list of triggers for a given place or layer: http://developers.geoloqi.com/api/trigger/list

    I don't believe there is an API method that will currently return triggers created by a specific user. I'll double-check and make sure that's accurate. If not, we can talk about adding that feature.

    In the meantime, you might want to just specify a layer when you're creating your triggers. Then you can call the trigger/list API method with the layer_id to get a list of all triggers on that layer.
  • Thanks. I was able to get the list to display correctly now. 

    I was in the impression that trigger doesn't work after calling run because it wasn't created in the first place.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion