UiPath Documentation
industry-department-solutions
latest
false
Supply Chain & Retail Solutions API guide
  • Overview
  • API Resources

Locations

Locations API resource representing physical and logical nodes in the supply chain network, including distribution centres, retail stores, and factories.

Overview

The Locations resource represents physical or logical nodes in the supply chain network, such as distribution centres, retail stores, and factories. Each location record captures the site's identity, geographic context, and its functional role within the inventory management system.

Resource Endpoint

/api/v2/ingest/object/{prefix}LOCATIONS{suffix}
/api/v2/ingest/object/{prefix}LOCATIONS{suffix}

Supported Methods

MethodReturn TypeDescription
POSTResponseIngest (create/update) Locations records via UPSERT operation

Request Headers

HeaderRequiredDescription
AuthorizationYesYour Personal Access Token (PAT) from platform.peak.ai
Content-TypeYesMust be application/json

Properties

Primary Keys

  • location_id (string) - Unique identifier for the location. Used as the primary key for deduplication and UPSERT operations.

Attributes

AttributeData TypeRequiredDescription
location_idstringYesUnique identifier for the location
location_namestringNoHuman-readable name of the location (for example, "Central Warehouse")
countrystringNoCountry in which the location resides
is_storebooleanYesIndicates whether the location is a retail store
is_dcbooleanYesIndicates whether the location is a distribution centre
is_factorybooleanYesIndicates whether the location is a manufacturing facility

Relationships

Outbound References

The locations resource does not reference any other resource as a foreign key.

Inbound References

The following resources reference locations via location_id:

  • stock_dailylocation_idlocations.location_id
  • pricinglocation_idlocations.location_id
  • order_parameterslocation_idlocations.location_id
  • purchase_orderslocation_idlocations.location_id
  • transferslocation_idlocations.location_id
  • manufacturing_orderslocation_idlocations.location_id
  • sku_calendarlocation_idlocations.location_id
  • sales_dailylocation_idlocations.location_id
  • customer_orderslocation_idlocations.location_id
  • forecastlocation_idlocations.location_id

JSON Representation

{
  "solutionName": "INV_OOTB",
  "data": [
    {
      "location_id": "LOC-001",
      "location_name": "Central Warehouse",
      "country": "United Kingdom",
      "is_store": false,
      "is_dc": true,
      "is_factory": false
    }
  ],
  "operationType": "UPSERT"
}
{
  "solutionName": "INV_OOTB",
  "data": [
    {
      "location_id": "LOC-001",
      "location_name": "Central Warehouse",
      "country": "United Kingdom",
      "is_store": false,
      "is_dc": true,
      "is_factory": false
    }
  ],
  "operationType": "UPSERT"
}

Example Request

curl -X POST \
  'https://ingestion.peak.ai/api/v2/objects/INV_LOCATIONS_OOTB' \
  -H 'Authorization: YOUR_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{
    "solutionName": "INV_OOTB",
    "data": [
      {
        "location_id": "LOC-001",
        "location_name": "Central Warehouse",
        "country": "United Kingdom",
        "is_store": false,
        "is_dc": true,
        "is_factory": false
      }
    ],
    "operationType": "UPSERT"
  }'
curl -X POST \
  'https://ingestion.peak.ai/api/v2/objects/INV_LOCATIONS_OOTB' \
  -H 'Authorization: YOUR_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{
    "solutionName": "INV_OOTB",
    "data": [
      {
        "location_id": "LOC-001",
        "location_name": "Central Warehouse",
        "country": "United Kingdom",
        "is_store": false,
        "is_dc": true,
        "is_factory": false
      }
    ],
    "operationType": "UPSERT"
  }'

Important Notes

  • location_id is the primary key, used for deduplication and UPSERT operations.
  • The boolean flags is_store, is_dc, and is_factory are all required. A location may have more than one flag set to true if it serves multiple roles.
  • Records are ingested via UPSERT: an existing record with matching primary keys will be updated; otherwise a new record is inserted.

Was this page helpful?

Connect

Need help? Support

Want to learn? UiPath Academy

Have questions? UiPath Forum

Stay updated