Qeersh home
العربية

Qeersh API reference · v1

Download OpenAPI

REST at /api/v1 and GraphQL for the admin and the storefront, on each store's address. This page is built from the live routes and schemas.

Authentication

The store owner creates an API key in Settings → API keys and chooses its scopes. Send it as a bearer token to the store's own address.

curl https://your-store.qeersh.com/api/v1/orders?status=paid \
  -H "Authorization: Bearer qsk_…"

Ground rules

REST /api/v1

EndpointWhat it doesScope
GET /app/data The app's data for this store (apps only) —
PUT /app/data Replace the app's data for this store: a JSON object up to 64 KB, read by the app's blocks and checkout content (apps only) —
GET /collections
?updated_since, limit, cursor
List collections products:read
GET /collections/{id} One collection with its product ids products:read
GET /customers
?email, phone, updated_since, limit, cursor
List customers (personal data) customers:read
GET /customers/{id} One customer (personal data) customers:read
GET /discounts
?updated_since, limit, cursor
List discounts discounts:read
GET /discounts/{id} One discount discounts:read
GET /inventory_levels
?variant_id, location_id, updated_since, limit, cursor
Stock per variant and location inventory:read
POST /inventory_levels/adjust Adjust or set stock at a location inventory:write
GET /locations
?limit, cursor
Stock locations inventory:read
GET /orders
?status, payment_status, created_since, updated_since, limit, cursor
List orders orders:read
GET /orders/{id} One order with items and shipments orders:read
POST /orders/{id}/cancel Cancel an order orders:write
POST /orders/{id}/fulfillments Record a shipment made outside Qeersh orders:write
GET /products
?status, updated_since, limit, cursor
List products with their variants products:read
POST /products Create a product products:write
GET /products/{id} One product products:read
PATCH /products/{id} Update a product (fields left out stay as they are) products:write
DELETE /products/{id} Delete a product (it can be restored from the admin) products:write
GET /shop The store: name, address, language and currency —
GET /webhooks
?limit, cursor
List webhooks webhooks:read
POST /webhooks Add a webhook (the secret is returned once) webhooks:write
DELETE /webhooks/{id} Remove a webhook webhooks:write

GraphQL

The same data in one request, limited by query cost (reported in X-Qeersh-Query-Cost).

  • POST /api/v1/graphql — Admin, with an API key · Schema
  • POST /api/storefront/v1/graphql — Storefront, with the public token (X-Qeersh-Storefront-Token) · Schema

Webhooks

Subscribe from Settings → Webhooks or POST /webhooks. Check the signature with the subscription secret:

orders/created · orders/paid · orders/fulfilled · orders/cancelled · refunds/created · products/created · products/updated · products/deleted · inventory/updated · customers/created · customers/updated · customers/deleted

$expected = base64_encode(hash_hmac('sha256', $rawBody, $secret, true));
hash_equals($expected, $request->header('X-Qeersh-Hmac-Sha256'));

Versions