GET
/
affiliate
/
products
cURL
curl --request GET \
  --url https://api-beta.lomadee.com.br/affiliate/products \
  --header 'x-api-key: <api-key>'
{
  "data": [
    {
      "organizationId": "<string>",
      "id": "<string>",
      "available": true,
      "createdAt": "2023-11-07T05:31:56Z",
      "updatedAt": "2023-11-07T05:31:56Z",
      "name": "<string>",
      "description": "<string>",
      "url": "<string>",
      "images": [
        {
          "url": "<string>"
        }
      ],
      "options": [
        {
          "id": "<string>",
          "ean": "<string>",
          "name": "<string>",
          "available": true,
          "seller": "<string>",
          "images": [
            {
              "url": "<string>"
            }
          ],
          "categories": [
            "<any>"
          ],
          "brands": [
            "<any>"
          ],
          "pricing": [
            {
              "listPrice": 123,
              "price": 123,
              "metadata": [
                "<any>"
              ]
            }
          ],
          "stocks": [
            {
              "value": 123,
              "metadata": [
                "<any>"
              ]
            }
          ],
          "metadata": [
            "<any>"
          ]
        }
      ],
      "metadata": [
        "<any>"
      ]
    }
  ],
  "meta": {
    "total": 123,
    "page": 123,
    "limit": 123,
    "totalPages": 123
  }
}

Get all Products

Retrieve a comprehensive list of products available across all affiliate brands. This endpoint provides detailed product information including pricing, availability, images, and specifications.

HTTP Request

GET https://api-beta.lomadee.com.br/affiliate/products

Query Parameters

page
integer
Page number for pagination. Starts at 1. Default: 1 Example: 2
limit
integer
Number of products per page. Maximum 100. Default: 10 Maximum: 100 Example: 25
Search term to filter products by name or description. Example: “smartphone”
price
string
Price range filter in cents. Format: from:to Format: {minPrice}: {maxPrice} (in cents) Example: “7400:8000” (R74,00toR 74,00 to R 80,00)
organizationIds
string
Filter products by specific brand organization IDs. Multiple IDs separated by commas. Format: UUID separated by commas Example: “e36f5bbb-3e5f-42e2-be4c-6c32dac101c2,12345678-1234-1234-1234-123456789012”

Example Requests

Basic Request

curl -X GET "https://api-beta.lomadee.com.br/affiliate/products" \
  -H "x-api-key: your-api-key"

With Pagination

curl -X GET "https://api-beta.lomadee.com.br/affiliate/products?page=1&limit=20" \
  -H "x-api-key: your-api-key"

With Search and Price Filter

curl -X GET "https://api-beta.lomadee.com.br/affiliate/products?search=ar%20condicionado&price=5000:6000" \
  -H "x-api-key: your-api-key"

Filter by Specific Brands

curl -X GET "https://api-beta.lomadee.com.br/affiliate/products?organizationIds=e36f5bbb-3e5f-42e2-be4c-6c32dac101c2" \
  -H "x-api-key: your-api-key"

Response Format

data
array
Array of product objects
meta
object
Pagination metadata

Product Object Structure

organizationId
string
Brand organization UUID
id
string
Product identifier
available
boolean
Product availability status
createdAt
string
Product creation timestamp (ISO 8601)
updatedAt
string
Last update timestamp (ISO 8601)
name
string
Product name/title
description
string
Product description (HTML format)
url
string
Product page URL
images
array
Product images
options
array
Product variants/options
metadata
array
Additional product data

Example Response

{
  "data": [
    {
      "_id": "6851c116cd2fe4fb974f9351",
      "organizationId": "e36f5bbb-3e5f-42e2-be4c-6c32dac101c2",
      "id": "1027452",
      "available": true,
      "createdAt": "2025-06-17T19:25:06.152Z",
      "updatedAt": "2025-08-18T12:26:02.179Z",
      "name": "Ar Condicionado Split Hi Wall Philco Inverter 24000 BTU/h Frio Monofásico PAC24000IFM15 - 220 Volts",
      "description": "<h2>Ar Condicionado Split Hi Wall Philco Inverter...</h2>",
      "url": "https://www.friopecas.com.br/split-philco-hw-24k-220-1-f-in-1027452/p",
      "integration": "vtex",
      "images": [
        {
          "url": "https://friopecas.vteximg.com.br/arquivos/ids/241735/17.png.png?v=638663374020100000"
        }
      ],
      "options": [
        {
          "id": "1027452",
          "ean": "7899963913617",
          "name": "Ar Condicionado Split Hi Wall Philco Inverter 24000 BTU/h Frio Monofásico PAC24000IFM15 - 220 Volts",
          "available": true,
          "seller": "friopecas",
          "images": [
            {
              "url": "https://friopecas.vteximg.com.br/arquivos/ids/241735/17.png.png?v=638663374020100000"
            }
          ],
          "categories": [],
          "brands": [],
          "pricing": [
            {
              "listPrice": 5098,
              "price": 5098,
              "metadata": []
            }
          ],
          "stocks": [
            {
              "value": 99999,
              "metadata": []
            }
          ],
          "metadata": []
        }
      ],
      "metadata": []
    }
  ],
  "meta": {
    "total": 1500,
    "page": 1,
    "limit": 10,
    "totalPages": 150
  }
}

Error Responses

400 Bad Request

{
  "message": "Invalid price range format. Expected format: from:to",
  "error": "BadRequest",
  "statusCode": 400
}

401 Unauthorized

{
  "message": "API key is required",
  "error": "Unauthorized",
  "statusCode": 401
}

500 Internal Server Error

{
  "message": "Internal server error",
  "error": "InternalServerError",
  "statusCode": 500
}

Usage Examples

JavaScript/Node.js

const axios = require("axios");

async function getProducts() {
  try {
    const response = await axios.get(
      "https://api-beta.lomadee.com.br/affiliate/products",
      {
        headers: {
          "x-api-key": "your-api-key",
        },
        params: {
          page: 1,
          limit: 20,
          search: "smartphone",
          price: "5000:10000",
        },
      }
    );

    console.log("Products:", response.data.data);
    console.log("Pagination:", response.data.meta);
  } catch (error) {
    console.error("Error:", error.response.data);
  }
}

Python

import requests

def get_products():
    url = 'https://api-beta.lomadee.com.br/affiliate/products'
    headers = {'x-api-key': 'your-api-key'}
    params = {
        'page': 1,
        'limit': 20,
        'search': 'smartphone',
        'price': '5000:10000'
    }

    response = requests.get(url, headers=headers, params=params)

    if response.status_code == 200:
        data = response.json()
        print('Products:', data['data'])
        print('Pagination:', data['meta'])
    else:
        print('Error:', response.json())

PHP

<?php
$url = 'https://api-beta.lomadee.com.br/affiliate/products';
$headers = ['x-api-key: your-api-key'];

$params = [
    'page' => 1,
    'limit' => 20,
    'search' => 'smartphone',
    'price' => '5000:10000'
];

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url . '?' . http_build_query($params));
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

$response = curl_exec($ch);
$httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);

if ($httpCode === 200) {
    $data = json_decode($response, true);
    echo 'Products: ' . print_r($data['data'], true);
    echo 'Pagination: ' . print_r($data['meta'], true);
} else {
    echo 'Error: ' . $response;
}
?>

Best Practices

  1. Pagination: Always implement pagination for large datasets
  2. Caching: Cache product data when appropriate (TTL: 60 seconds)
  3. Search Optimization: Use specific search terms for better results
  4. Price Filtering: Use price ranges to narrow down products
  5. Error Handling: Implement proper error handling for all responses
  6. Rate Limiting: Respect the 10 requests per minute limit

Common Use Cases

  • Product Catalog: Display available products with filtering
  • Price Comparison: Compare prices across different brands
  • Inventory Management: Check product availability and stock levels
  • Search Integration: Implement product search functionality
  • Recommendation Engine: Build product recommendation systems

Authorizations

x-api-key
string
header
required

Query Parameters

page
integer
default:1

Page number for pagination. Starts at 1.

limit
integer
default:10

Number of products per page. Maximum 100.

Required range: x <= 100

Search term to filter products by name or description.

price
string

Price range filter in cents. Format: from:to

organizationIds
string

Filter products by specific brand organization IDs. Multiple IDs separated by commas.

Response

Products response

The response is of type object.