CSQ Docs
    CSQ Docs
    CSQ API Doc
    • CSQ API Doc
    • Dummy Product Usage Guide
    • Back to home
    • Location-based Products
    • Get Labels
      GET
    • Get Countries
      GET
    • Get Categories
      GET
    • Get States
      GET
    • Get Municipalities
      GET
    • Get Deliver Locations
      GET
    • Get Products
      GET
    • Create Cart
      POST
    • Purchase
      POST
    • Get Orders
      GET
    • Get Order Status
      GET

      Get Categories

      GET
      /physical-products/categories/{terminalId}/{levelId}
      This endpoint returns the list of available product categories for a given terminal and location level. It is typically the second step in a dynamic location-based product flow, following country selection.

      šŸ” Description#

      Use this method to:
      Fetch the categories available for the selected country or location level
      Dynamically determine the next step using nextPath and nextField
      Guide the user toward selecting a product type (e.g., groceries, eSIMs, services)
      šŸ“Œ The presence of nextPath and nextField allows the client to adapt the flow based on the product configuration. Some categories may skip intermediate steps.

      šŸ“„ Request Details#

      Method: GET
      Authentication: Required
      Path Parameters:
      terminalId (integer): ID of the requesting terminal
      levelId (integer): level ID from the previous step

      šŸ“¤ Response#

      Returns an array of category objects:
      FieldTypeDescription
      categoryIdintegerUnique identifier of the category
      namestringDisplay name of the category
      nextPathstringPath to the next endpoint in the flow
      nextFieldstringField name required in the next step, as defined in Get Labels

      Example#

      [
        {
          "categoryId": 101,
          "name": "Groceries",
          "nextPath": "/physical-products/states/{terminalId}/101/1",
          "nextField": "stateId"
        },
        {
          "categoryId": 102,
          "name": "eSIM",
          "nextPath": "/physical-products/products/{terminalId}/102/1",
          "nextField": "productId"
        }
      ]

      🧠 Usage Notes#

      Some categories may lead directly to products, skipping location steps.
      Always follow the nextPath and nextField to maintain flow integrity.
      The levelId must match the one received from the previous selection step.

      Request

      Path Params
      terminalId
      integerĀ <int32>
      required
      levelId
      integerĀ <int32>
      required
      Header Params
      U
      stringĀ 
      required
      Default:
      {{U}}
      SH
      stringĀ 
      required
      Default:
      {{SH}}
      ST
      stringĀ 
      required
      Default:
      {{ST}}

      Request samples

      Shell
      JavaScript
      Java
      Swift
      Go
      PHP
      Python
      HTTP
      C
      C#
      Objective-C
      Ruby
      OCaml
      Dart
      R
      Request Request Example
      Shell
      JavaScript
      Java
      Swift
      curl --location --request GET 'https://evsb.csqworld.com/physical-products/categories//' \
      --header 'U;' \
      --header 'SH;' \
      --header 'ST;'

      Responses

      🟢200OK
      application/json
      OK
      Body
      array of:
      categoryId
      integerĀ 
      required
      name
      stringĀ 
      required
      name
      nextPath
      stringĀ 
      required
      nextField
      stringĀ 
      required
      Example
      [
          {
              "categoryId": 2,
              "name": "Category",
              "nextPath": "/physical-products/{{nextPath}}/{{categoryId}}/{{levelId}}",
              "nextField": "{nextField}"
          }
      ]
      Modified atĀ 2025-07-07 10:57:25
      Previous
      Get Countries
      Next
      Get States
      Built with