Skip to content
トレカクラウド
Esc
↑↓navigate↵open⌘Jpreview

List sites and storage locations

Returns every site and storage location of the shop, inactive ones included.

GET/inventory/sites
Authorization
AuthorizationOAuth2 access token · headerrequired

Authorization code flow (PKCE S256 required). Send resource=https://api.toreca-cloud.com/partner/v1 with the authorization, token and refresh requests. Access tokens last 15 minutes; refresh tokens last 90 days and rotate on every refresh.

Scopes:inventory:read
Responses
200

The sites

sitesSite[]required
Show properties
Array of Site
idstring<uuid>
codestring
namestring
kindstring
countryCodestring
timezonestring
isActiveboolean
createdAtstring<date-time>
updatedAtstring<date-time>
locationsLocation[]
Show properties
Array of Location
idstring<uuid>
siteIdstring<uuid>
codestring
namestring
kindstring
isActiveboolean
createdAtstring<date-time>
updatedAtstring<date-time>
401

invalid_token: the token is missing, expired, or for another resource.

errorstringrequired

The error code

scopestring

With insufficient_scope, the missing scope

403

One of insufficient_scope, connection_revoked, client_disabled or forbidden.

errorstringrequired

The error code

scopestring

With insufficient_scope, the missing scope

Try it
Server
Authorization
Request
curl -X GET 'https://api.toreca-cloud.com/partner/v1/inventory/sites' \
  -H 'Authorization: Bearer YOUR_ACCESS_TOKEN'
Response
{
  "sites": [
    {
      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
      "code": "string",
      "name": "string",
      "kind": "string",
      "countryCode": "string",
      "timezone": "string",
      "isActive": true,
      "createdAt": "2019-08-24T14:15:22Z",
      "updatedAt": "2019-08-24T14:15:22Z",
      "locations": [
        {
          "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
          "siteId": "60189e9c-7d12-438c-b9ca-6998d9c364b1",
          "code": "string",
          "name": "string",
          "kind": "string",
          "isActive": true,
          "createdAt": "2019-08-24T14:15:22Z",
          "updatedAt": "2019-08-24T14:15:22Z"
        }
      ]
    }
  ]
}