Public API reference
Delivery Gateway provides a public GraphQL API for storefront and checkout integrations. You can use it to create and manage delivery sessions, search and select pickup points, set customer addresses, and return delivery options in real time.
This API is intended for customer-facing flows where a lightweight, session-based integration is needed.
Authentication
Public API calls are session-based.
- Use
merchantIdto create a new session withcreateSession. - Use the returned
session.idfor subsequent queries and mutations in the same checkout flow.
Unlike the Merchant API, Public API requests do not require a Merchant Bearer token. Keep Merchant API credentials server-side, and only use the Public API in browser/client checkout flows.
Endpoints and queries
GraphQL queries are executed by sending POST HTTP requests to the endpoint:
https://api.sandbox.deliverygateway.io/graphql/publicin the sandbox environment andhttps://api.deliverygateway.io/graphql/publicin the production environment.
You can use cURL or an HTTP client such as Postman or Insomnia to query the API.
cURL example
curl -X POST https://api.sandbox.deliverygateway.io/graphql/public \
-H "Content-Type: application/json" \
-d '{"query":"query Session($id: ID!) { session(id: $id) { id mode currency } }","variables":{"id":"<SESSION_ID>"}}'
query Session($id: ID!) {
session(id: $id) {
id
mode
currency
}
}
Status and error codes
Public API follows standard GraphQL response conventions.
- A request can return
200 OKeven when business or validation errors exist. - GraphQL-level errors are returned in the
errorsarray. - Successful payloads are returned in the
dataobject.