Quickstart
Create a merchant-scoped API key, make your first authenticated request, and use idempotency safely for writes.
Create an API key in the merchant portal.
Open the merchant portal, navigate to API Keys, choose a label and the scopes your external system needs, then copy the secret shown after creation. The raw secret is not shown again. If the merchant operates multiple fulfillment locations, the key can optionally be restricted to specific locations.
Make your first request with Bearer authentication.
All requests authenticate with a merchant-issued API key. Use the Authorization header by default, or X-API-Key if your integration needs a simpler header shape.
curl -X GET "https://merchants.rarely.co//api/integrations/v1/products?limit=10" \
-H "Authorization: Bearer YOUR_API_KEY"Follow cursors for list endpoints.
List endpoints return a data array plus a meta object with limit and next_cursor. Pass the returned cursor back into the same endpoint to continue paging through results.
{
"data": [],
"request_id": "7d51c637-ea01-4ab7-a66b-a93f5b3843e0",
"meta": {
"limit": 50,
"next_cursor": "MjAyNi0wMy0xNFQxODowMjoxMS4wMDBafDliOWE0MWJjLTJhMTUtNDZiOS1iMjViLTc5YmI0ZDFhMjIyMQ"
}
}Use idempotency keys for POST endpoints.
Inventory adjustments, fulfillment creation, and fulfillment tracking updates all support Idempotency-Key. Reusing the same key with the same payload replays the stored response instead of applying the write twice.
curl -X POST "https://merchants.rarely.co//api/integrations/v1/inventory/adjustments" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Idempotency-Key: inventory-adjustment-001" \
-H "Content-Type: application/json" \
-d '{
"adjustments": [
{
"variant_id": "66f1b765-1fe7-4e3a-98db-d2334f3bcb43",
"fulfillment_location_id": "77a1a4d0-93a9-4cf8-a34c-208e64b0ad4f",
"adjustment": 5,
"reason": "cycle count reconciliation"
}
]
}'