API Data Provider - Online Help

Connecting to Foursquare

Using API Key Authentication

Foursquare Places API uses Service Key (Bearer token) authentication. To obtain a Service Key:

  1. Go to the Foursquare Developer Console at https://foursquare.com/developers/
  2. Create a new project or select an existing one
  3. Navigate to the API Keys section
  4. Generate a new Service Key for the Places API

After setting the following connection properties, you are ready to connect:

  • AuthScheme: Set this to APIKey.
  • ServiceKey: Set this to your Foursquare Service Key obtained from the Developer Console.
  • XPlacesApiVersion: (Optional) Set this to the API version date. Defaults to 2025-06-17.

Example APIKey connection string

Profile=C:\profiles\Foursquare.apip;AuthScheme=APIKey;ProfileSettings='APIKey=your_personal_access_token';

Available Tables

The Foursquare API Profile provides access to the following tables:

  • Places: Search and retrieve place information including location, categories, ratings, and business details.
  • PlacePhotos: Photos associated with Foursquare places.
  • PlaceTips: Tips and reviews associated with Foursquare places.
  • GeotaggingCandidates: Nearby place candidates for geotagging based on device location.
  • Autocomplete: Autocomplete suggestions for places, addresses, searches, and geographic locations.
  • SuggestionStatus: Status tracking for place edit suggestions submitted via Placemaker.

API Rate Limits

Foursquare Places API has the following rate limits:

  • Pay-as-you-go: 50 queries per second (QPS)
  • Enterprise: 100 queries per second (QPS)

Usage Examples

Autocomplete:

SELECT * FROM Autocomplete WHERE Query = 'abc'

GeotaggingCandidates:

SELECT * FROM GeotaggingCandidates WHERE Ll = '41.8781,87.6298'

PlacePhotos:

SELECT * FROM PlacePhotos WHERE PlaceId = '4d806d0e551ea1cd3d1d1ac5'

Places:

SELECT * FROM Places

PlaceTips:

SELECT * FROM PlaceTips WHERE PlaceId = '4d806d0e551ea1cd3d1d1ac5'

SuggestionStatus:

SELECT * FROM SuggestionStatus

Connection Properties

The connection string properties are the various options that can be used to establish a connection. This section provides a complete list of the options you can configure in the connection string for this provider.


Property Description
APIKey The Foursquare Service Key for API authentication.
AuthScheme The scheme used for authentication. Accepted entries are APIKey or None.
Allowed values are: BASIC, NONE, NTLM, OAUTH, APIKEY, OAUTH_CLIENT
XPlacesApiVersion The API version date for the X-Places-Api-Version header.

Copyright (c) 2026 CData Software, Inc. - All rights reserved.
Build 26.0.9655.0