Skip to content

Overview

The API your web shop’s server calls to show your Petanque AI catalogue, run shopper accounts, place orders and take payment.

Authentication. Send your storefront API key in the x-storefront-token header on every request. Create keys in Petanque AI under Ayarlar → Web Sitesi. The key identifies your company and can place orders, so keep it on your server: call this API from your back end, never from browser JavaScript. A missing, revoked or expired key answers 401.

Shoppers. Signed-in shopper routes also need the session token that Sign in returns, in the x-customer-session header.

Responses. Every answer is { data, error, meta }; on failure error.code names the problem. Amounts are integers in kuruş (1/100 TRY) with VAT included. Lists take page and limit (at most 100) and report meta.total.

Guides: https://docs.petanqueai.com

Information

  • OpenAPI version: 3.0.3

Your storefront API key, psk_<keyId>.<secret>. Server-side only.

Security scheme type: apiKey

Header parameter name: x-storefront-token

The session token that Sign in returned for this shopper.

Security scheme type: apiKey

Header parameter name: x-customer-session