Triggers

Triggers are geofences. When a user enters or exits a location, or dwells in a place for a period of time, a trigger will activate, sending a message to the user, or a callback to your web server with a provided URL.

This is an example of what the Geoloqi API will send to your URL when a callback is triggered.

Geonotes

Geonotes are location-based messages that are sent to a user when they arrive at a location. These API methods are provided for convenience when developing an app like our Geonotes app. Typically you won't need to use these, and you should use the trigger and place methods instead.

Note: By default, all apps created after August 13, 2013 do not store location history for their users. If you would like to enable this feature, please contact [email protected] to request access. You will need to be able to demonstrate your application's need for storing and retrieving history, and we will work with you to find a paid plan that can accommodate your needs.

Places

Places are objects in the API that represent physical locations. All triggers have a place - when a trigger is created in our system with a latitude and longitude, a place is automatically created for the trigger.

Places allow you to manipulate the location separately from the trigger. You can do things like remove the trigger (but keep the place), or add multiple triggers. You can use the "key" to have a unique ID for your place, ensuring that you won't have duplicate place entries.

Places do not have to be permanently fixed in a specific location - they can move. If you have a place that is moving frequently (such as a vehicle or a food cart), you can update the place's location with a simple call to the API via place/update.

Layers

Layers represent a group of places. They are very helpful for sorting places, and for choosing which users will be subscribed to a set of places, in scenarios where not all users will see the same places.

Layers allow you to create global triggers. If you add a trigger to the layer, the trigger will be attached to every place on a layer. This way, you can have one trigger for multiple places, without having to create a lot of triggers.

In order to have a user receive updates from places on a layer, you need to subscribe the user to the layer with layer/subscribe. This allows you to have a set of places/triggers for one group of users, but not for others.

Layers can be edited in our graphical layer editor (available for personal layers.. coming soon for applications), and can be given a latitude, longitude and radius to assist in finding layers nearby to the user (layer/nearby).

Places and triggers do not necessarily require placement in a layer. However it is strongly recommended that you add places to a layer.

Users

Users represent each installed instance of your mobile application. When you start a new application on your phone with the Geoloqi SDK, it automatically calls user/create_anon on initial load, creating an anonymous user account for the application to use.

Note: All of the user methods require authentication with the application's client ID and secret. See Authentication for more information.

Groups

Groups are a component of our high performance, real-time streaming service. A group is essentially a collections of users. When users are subscribed to a group, you can listen to the group via the Geoloqi streaming Socket.IO/Websockets server, and see location updates from users' phones in real-time. You can also efficiently broadcast a message to all users in a group.

Groups can be created with an application access token, or a user access token. If created using a user access token and set as "public", other users can subscribe to the group using their own user access tokens. Otherwise, an application access token is required to subscribe the user to the group.

Batched Requests

batch/run allows you to run a lot of requests to the API, without making individual requests. This will allow your scripts to run considerably faster, since there will only be one request made to the API. The results of the requests will be returned once they have finished.

This is very helpful for import scripts that have to add a lot of layers, places or triggers, because it will run much more quickly than doing a single request at a time. Here is a real-world example of how to integrate it into an import script.

Retrieves usage information about the number of API calls made by this application

Share Links

Share Links allow you to temporarily (or permanently) share your location with others. When you create a link (link/create), it returns a token that you can use to view the user's location, either with an API call to share/info, or via a web browser using our real-time location streaming service (see Streaming). If you are using a share link privately, be sure to keep the token a secret!

Share links can be de-activated, re-activated, or expired. When expired, the share link is permanently ended, and cannot be re-activated.

Deactivate a link so that it doesn't show the user's location. This is different from expiring, because deactivated links can be reactivated again. Once a link is expired, it will never be accessible again.