Shoplio REST API
The API has 20 endpoints under one base URL. A key belongs to one shop and carries only the scopes you tick.
On this page
Base URL
https://api.shopl.io/api/v1
Every path in this reference sits under that base. The API is not served on shopl.io: a request there answers 404 with a JSON hint that names the right host.
Your first request
- Create a key under Developer in the dashboard. See API keys and scopes.
- Send it as a bearer token on every request.
curl -H "Authorization: Bearer YOUR_KEY" \ https://api.shopl.io/api/v1/shop
200 OK { "success": true, "data": { "id": "3f2a9c1b-7d44-4e0a-9a3c-1f5b8e2d6c70", "name": "North Keys", "slug": "north-keys", "description": "Game keys and software licences", "is_active": true, "created_at": "2026-04-01T12:00:00Z" } }
The same idea from Node, reading paid orders:
const url = 'https://api.shopl.io/api/v1/orders?status=paid&limit=100';
const res = await fetch(url, {
headers: { Authorization: `Bearer ${process.env.SHOPLIO_KEY}` },
});
if (!res.ok) throw new Error(`Shoplio API answered ${res.status}`);
const { data } = await res.json();
for (const order of data.orders) {
console.log(order.id, order.status, order.amount);
}The response envelope
Every endpoint answers in one shape. success is true and the result is in data, or success is false and error holds a message.
{ "success": true, "data": { "id": "3f2a9c1b-7d44-4e0a-9a3c-1f5b8e2d6c70" } }{ "success": false, "error": "Product not found" }Pagination
The product, order and customer lists take page and limit.
| Parameter | Default | Rule |
|---|---|---|
page | 1 | Counts from 1. A value below 1 is read as 1 |
limit | 20 | Maximum 100. A larger value is lowered to 100 |
Each of those lists returns total, page and limit next to the items. The stock list is not paginated.
Ids, timestamps and amounts
- Ids are UUIDs.
- Timestamps are RFC 3339 strings.
- Amounts are JSON numbers unless a field table says otherwise. Order amounts are in USD and balances are in the coin.
- The samples are abridged. A response can carry more keys than a sample or a field table shows, so ignore the ones you do not use.
What the API does not do
- Nothing is pushed to you. Poll
GET /ordersfor new and changed orders. - It does not create orders or invoices.
- It does not delete products or variants. That stays in the dashboard.
- It takes no file uploads. A product image is a URL you already host.
- It does not refund an order, withdraw a balance or change shop settings.
All endpoints
| Endpoint | What it does | Scope |
|---|---|---|
| GET /shop | Get the shop | read_products |
| GET /balance | Get the balance | read_analytics |
| GET /products | List products | read_products |
| GET /products/:id | Get a product | read_products |
| POST /products | Create a product | write_products |
| PATCH /products/:id | Update a product | write_products |
| POST /products/:id/variants | Add a variant | write_products |
| PATCH /products/:id/variants/:vid | Update a variant | write_products |
| GET /products/:id/stock | List unsold stock | read_stock |
| POST /products/:id/stock | Add stock | write_stock |
| PATCH /products/:id/stock/:sid | Edit a stock item | edit_stock |
| DELETE /products/:id/stock/:sid | Delete a stock item | delete_stock |
| POST /products/:id/stock/delete | Delete stock in bulk | delete_stock |
| GET /orders | List orders | read_orders |
| GET /orders/:id | Get an order | read_orders |
| POST /orders/:id/deliver | Deliver an order | fulfill_orders |
| GET /customers | List customers | read_orders |
| GET /customers/:id | Get a customer | read_orders |
| POST /customers/:id/balance/add | Add store balance | write_orders |
| POST /customers/:id/balance/subtract | Subtract store balance | write_orders |