Product

Returns a single product or component, identified by its Sodtrack id or by its SKU, together with its catalog price and every area pricing configuration it has: each configuration carries the price,…

GET/api/integration/product

Request

cURL
curl -X GET "https://dev.integration.cl.sodtrack-shared.sodtrack.com/api/integration/product" \
  -H "Authorization: Bearer $SODTRACK_TOKEN"

Base URL: https://dev.integration.cl.sodtrack-shared.sodtrack.com · other environments

Responses

GET Product
{
  "id": "5",
  "sku": "MOTO-SUZ-GN125",
  "name": "Suzuki GN 125",
  "description": "Motocicleta urbana 125cc",
  "category": "Motocicletas Urbanas",
  "brand": "Suzuki",
  "type": "product",
  "price": 2100,
  "areaPricingItems": [
    {
      "id": 38,
      "price": 2600,
      "cost": 1600,
      "currency": {
        "id": 8,
        "name": "USD",
        "symbol": "$"
      },
      "areas": [
        {
          "id": 15,
          "name": "Ciudad de Guatemala",
          "reference": "AREA-GT-CITY"
        }
      ]
    },
    {
      "id": 39,
      "price": 2400,
      "cost": 1500,
      "currency": {
        "id": 8,
        "name": "USD",
        "symbol": "$"
      },
      "areas": [
        {
          "id": 9,
          "name": "San Salvador",
          "reference": "AREA-SV-SS"
        },
        {
          "id": 10,
          "name": "Santa Ana",
          "reference": "AREA-SV-SA"
        }
      ]
    },
    {
      "id": 40,
      "price": 39999,
      "cost": 25000,
      "currency": {
        "id": 3,
        "name": "MXN",
        "symbol": "$"
      },
      "areas": [
        {
          "id": 21,
          "name": "Ciudad de México",
          "reference": "AREA-MX-CDMX"
        }
      ]
    }
  ]
}

Error responses for this endpoint follow the shared error reference.

Purpose

Returns a single product or component, identified by its Sodtrack id or by its SKU, together with its catalog price and every area pricing configuration it has: each configuration carries the price, the cost, the areas it applies to and the currency of those areas.

Use it to know how a product is priced in each geographic area before creating bookings, work orders or quotes that reference it.


Field Definitions

🔎 Query parameters

ParameterTypeRequiredDescription
idnumber✅ when sku not sentProduct id in Sodtrack. Positive integer (minimum 1).
skustring✅ when id not sentProduct SKU.

Send exactly one of id or sku. Sending none, or both, is rejected with 400 Bad Request.


Example Request

code
GET /api/integration/product?id=5
GET /api/integration/product?sku=MOTO-SUZ-GN125

Response Example

json
{
  "id": "5",
  "sku": "MOTO-SUZ-GN125",
  "name": "Suzuki GN 125",
  "description": "Motocicleta urbana 125cc",
  "category": "Motocicletas Urbanas",
  "brand": "Suzuki",
  "type": "product",
  "price": 2100,
  "areaPricingItems": [
    {
      "id": 38,
      "price": 2600,
      "cost": 1600,
      "currency": {
        "id": 8,
        "name": "USD",
        "symbol": "$"
      },
      "areas": [
        {
          "id": 15,
          "name": "Ciudad de Guatemala",
          "reference": "AREA-GT-CITY"
        }
      ]
    },
    {
      "id": 39,
      "price": 2400,
      "cost": 1500,
      "currency": {
        "id": 8,
        "name": "USD",
        "symbol": "$"
      },
      "areas": [
        {
          "id": 9,
          "name": "San Salvador",
          "reference": "AREA-SV-SS"
        },
        {
          "id": 10,
          "name": "Santa Ana",
          "reference": "AREA-SV-SA"
        }
      ]
    },
    {
      "id": 40,
      "price": 39999,
      "cost": 25000,
      "currency": {
        "id": 3,
        "name": "MXN",
        "symbol": "$"
      },
      "areas": [
        {
          "id": 21,
          "name": "Ciudad de México",
          "reference": "AREA-MX-CDMX"
        }
      ]
    }
  ]
}

Product without any area pricing configured:

json
{
  "id": "2",
  "sku": "MOTO-HND-WAVE110",
  "name": "Honda Wave 110",
  "description": "Motocicleta urbana 110cc",
  "category": "Motocicletas Urbanas",
  "brand": "Honda",
  "type": "product",
  "price": 1800,
  "areaPricingItems": []
}

Response Fields

FieldTypeDescription
idstringProduct id in Sodtrack.
skustringProduct SKU.
namestringProduct name.
descriptionstringProduct description.
categorystringCategory name. Omitted when the product has no category.
brandstringBrand name. Omitted when the product has no brand.
typestring"product" or "component".
pricenumbernull
areaPricingItemsarrayArea pricing configurations of the product (see Area pricing item). Empty when none is configured.

Area pricing item (areaPricingItems[])

FieldTypeDescription
idnumberConfiguration id.
pricenumbernull
costnumbernull
currencyobjectnull
areasarrayAreas the configuration applies to (see Area).

Area (areaPricingItems[].areas[])

FieldTypeDescription
idnumberArea id.
namestringArea name.
referencestringnull

Error Responses

HTTP StatusErrorDescription
400 Bad RequestExactly one of `id` or `sku` must be providedNeither or both identifiers were sent.
400 Bad Requestid must be an integer number / id must not be less than 1id is not a positive integer.
404 Not FoundProduct with id {id} not found / Product with sku '{sku}' not foundNo product matches the identifier.
403 ForbiddenThe request origin is not allowed.
500 Internal Server ErrorUnexpected server error. Contact Sodtrack support.

Business Rules & Constraints

Product identification

  • id and sku identify the same product through different fields; exactly one must be sent.
  • Both products (type = "product") and components (type = "component") are supported and return the same structure.
  • SKU matching is exact.

Catalog price

price is the product price stored in the Sodtrack catalog, independent of any area. A catalog price of 0 means no price was loaded and is returned as null. The catalog price has no currency associated.

Area pricing items

  • Each entry in areaPricingItems is one price/cost configuration valid for all the areas listed in its areas. An area belongs to at most one configuration of the same product.
  • All the areas of a configuration share the same currency, which is exposed once as currency.
  • areaPricingItems lists every configuration stored for the product, including those whose area pricing is currently inactive and those without a price. When resolving the price of a booking or work order, Sodtrack only applies active configurations with a price; inactive or priceless configurations fall back to the catalog price.

Data and format

  • Query parameter values are passed as strings in the URL; id is coerced to an integer before validation.
  • Unknown query parameters are ignored.