Skip to main content

Overview

GPS coordinates in Partoo are critical for accurate business location representation across platforms like Google Business Profile, Apple Maps, and other location services. Understanding how coordinates are handled helps ensure proper location data management.

Coordinate Fields

Business coordinates are managed through two main fields in the API:
FieldTypeDescription
latnumber | nullLatitude coordinate (decimal degrees)
longnumber | nullLongitude coordinate (decimal degrees)
Decimal coordinates should use dots (.) as separators, not commas. Example: 47.870341, not 47,870341.

Coordinate Behavior

The way coordinates are handled depends on how the business is created and whether GPS data is provided:

When GPS Coordinates Are Provided

If you provide GPS coordinates when:
  • Creating a business
  • Updating an existing business
Result: The provided coordinates are:
  • ✅ Stored in Partoo’s database
  • ✅ Sent to Google Business Profile
  • ✅ Returned via API responses

When GPS Coordinates Are Not Provided

If you don’t provide GPS coordinates via the API: Result:
  • ❌ No coordinate data is sent from Partoo to Google Business Profile
  • Google Business Profile automatically generate coordinates based on the business address, which we save for each business
  • ✅ Auto-generated coordinates are returned in API responses
  • ⚠️ Auto-generated coordinates may not be perfectly accurate
Auto-generated coordinates are computed based on the business address. While generally accurate, they may not represent the exact entrance or specific location within a building.

Updating the Coordinates in the App

You can also update business coordinates directly in the Partoo app. Navigate to the business page for the business you want to update, and click on your business address, which in turn opens a form where you can edit your address, as well as your GPS coordinates.
Editing business coordinates in the Partoo app

In this screenshot, we can see that our adress for the Eiffel Tower doesn't put the map pin exactly in the right position.

To update the coordinates on this page, simple drag and drop the map pin to the correct location, and save your changes.
Editing business coordinates in the Partoo app

After dragging the map pin to the correct location, we can see that it better aligns with reality!

REST API Examples

Creating a Business with Coordinates

When creating a business, include the lat and long fields:
curl -X POST 'https://api.partoo.co/v2/business' \
  -H 'x-APIKey: YOUR_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Downtown Coffee Shop",
    "address_full": "123 Main Street, Springfield, IL",
    "city": "Springfield",
    "zipcode": "62701",
    "country": "US",
    "lat": 39.7817,
    "long": -89.6501,
    "categories": ["gcid:coffee_shop"]
  }'

Updating Business Coordinates

You can update coordinates for an existing business:
curl -X POST 'https://api.partoo.co/v2/business/5409c35a97bbc544d8e26737' \
  -H 'x-APIKey: YOUR_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{
    "lat": 39.7825,
    "long": -89.6495
  }'

Retrieving Business Coordinates

When fetching business information, coordinates are included in the response:
curl -X GET 'https://api.partoo.co/v2/business/5409c35a97bbc544d8e26737' \
  -H 'x-APIKey: YOUR_API_KEY'
Response structure:
{
  "id": "5409c35a97bbc544d8e26737",
  "name": "Downtown Coffee Shop",
  "address_full": "123 Main Street, Springfield, IL",
  "city": "Springfield",
  "lat": 39.7817,
  "long": -89.6501
  // ... other business fields
}