Foursquare LogoFoursquare Developers Logo

Postman is a popular tool to help test and develop APIs. To make it more convenient for developers who are integrating with Foursquare's Geofences API, we've created a Postman collection that contains the set of APIs commonly used by our developers.


Set Up

We recommend setting up Postman using the Run in Postman button:

  1. Download and install Postman here.
  2. Sign up for a Foursquare Developer account and follow the instructions to create a new app. Note the Client ID and Client Secret that has been provided to you, and keep these values within your team/organization.
  3. Once you have Postman running, click on this button to immediately import the entire collection and environment into your Postman app:
Run in Postman

After it has been imported, you should be able to see Foursquare Geofences API under Collections and Foursquare Geofences API as the environment.

Note: Using the Geofence API requires an OAuth token. Postman offers a step by step guide on performing the OAuth flow which you can read more about here.

screenshot of Foursquare Places API in the postman environment

Set Up Using GitHub Repo

  1. Download and install Postman here.
  2. Sign up for a Foursquare Developer account and follow the instructions to create a new app. Note the Client ID and Client Secret that has been provided to you, and keep these values within your team/organization.
  3. Download the geofence_collection.json and geofence_environment.json files from the GitHub repo.

Configure

Postman allows us to use a configurable environment using a set of key-value pairs, creating commonly used variables that can be referenced by multiple requests in our collection. More documentation on the Postman environment can be found here.

It is important that you edit and replace some of these variables with your own values. Access the edit dialog by clicking the gray eye button next to the environment dropdown (highlighted in blue below):

screenshot showing gray eye button on top right corner of postman

Then, click edit (highlighted in blue below):

screenshot showing a list of configurations in postman

Replace the client_id and client_secret with your own initial values. You should have obtained these when creating your own Foursquare app. If not, you can get them here.

screenshot showing to add client ID and secret to variables section in postman

Test

You're now set to choose any of the APIs in the collection to start testing.