Skip to main content

Documentation

List Products

Retrieve a list of all products.

Use the optional query parameters to filter the results. You can filter the results further by specifying one or more Product fields as additional query parameters.

    • ending_before

    • The ID of the product created after the last product you want to retrieve.

    • limit

    • The maximum number of products to return. Range: 1-100. Default is 10.

    • starting_after

    • The ID of the product created before the first product you want to retrieve.

Code Samples
    • .NET

      • using System;
        
        namespace RapydApiRequestSample
        {
            class Program
            {
                static void Main(string[] args)
                {
                    try
                    {
                        int limit = 2;
        
                        string result = RapydApiRequestSample.Utilities.MakeRequest("GET", $"/v1/products?limit={limit}");
        
                        Console.WriteLine(result);
                    }
                    catch (Exception e)
                    {
                        Console.WriteLine("Error completing request: " + e.Message);
                    }
                }
            }
        }
    • JavaScript

      • const makeRequest = require('<path-to-your-utility-file>/utilities').makeRequest;
        
        async function main() {
          try {
            const result = await makeRequest(
              'GET',
              '/v1/products&limit=2'
            );
        
            console.log(result);
          } catch (error) {
            console.error('Error completing request', error);
          }
        }
    • PHP

      • <?php
        $path = $_SERVER['DOCUMENT_ROOT'];
        $path .= "/<path-to-your-utility-file>/utilities.php";
        include($path);
        
        try {
            $object = make_request('get', '/v1/products&limit=2');
            var_dump($object);
        } catch(Exception $e) {
            echo "Error: $e";
        }
        ?>
    • Python

      • from pprint import pprint
        
        from utilities import make_request
        
        result = make_request(method='get', path=f'/v1/products&limit=2')
        pprint(result)
  • /v1/products

  • List Products

  • curl -X get 'https://sandboxapi.rapyd.net/v1/products?limit=2' \
    -H 'access_key: your-access-key-here' \
    -H 'Content-Type: application/json' \
    -H 'salt: your-random-string-here' \
    -H 'signature: your-calculated-signature-here' \
    -H 'timestamp: your-unix-timestamp-here'
  • {
      "status": {
        "error_code": "",
        "status": "SUCCESS",
        "message": "",
        "response_code": "",
        "operation_id": "e293b63e-b94a-49c3-bde8-714a1b6629b2"
      },
      "data": [
        {
          "id": "product_21df183b1dc8e8a1dca65fca477cc4ed",
          "active": true,
          "attributes": [
            "arm rest",
            "color"
          ],
          "created_at": 1752756148,
          "description": "The ultimate in comfort for the dedicated gamer.",
          "images": [],
          "metadata": {
            "merchant_defined": true
          },
          "name": "Gamer's Chair",
          "package_dimensions": {
            "height": 10,
            "length": 20,
            "weight": 30,
            "width": 40
          },
          "shippable": true,
          "skus": [],
          "statement_descriptor": "",
          "type": "goods",
          "unit_label": "",
          "updated_at": 1752756148
        },
        {
          "id": "product_b34eedb1d7cd6e5ae3f1b20c3a83fa21",
          "active": true,
          "attributes": [],
          "created_at": 1700140346,
          "description": "Monthly parking plus - covered area, compact car",
          "images": [],
          "metadata": {
            "merchant_defined": true
          },
          "name": "Monthly parking plus car",
          "package_dimensions": {
            "height": 0,
            "length": 0,
            "weight": 0,
            "width": 0
          },
          "shippable": true,
          "skus": [],
          "statement_descriptor": "",
          "type": "goods",
          "unit_label": "",
          "updated_at": 1700140346
        }
      ]
    }