Skip to content
GiftUdevelopers
GuidesAPI referencev1.0.1

Get started / GiftU Partner API

Make your first request

Verify connectivity in TEST, then complete a purchase with a reference you can safely reuse.

1. Prepare your TEST access

Obtain your pk_test_ key through the agreed secure channel. Store it on your server as GIFTU_PARTNER_API_KEY. If IP allowlisting is enabled, ask GiftU to allow your server’s outbound IP address.

2. Send a ping

Call GET /ping. A successful response includes status: "ok" and mode: "TEST". Both environments use the same API base URL; the key selects the environment.

3. Choose a product and check the balance

Read GET /products and use a SKU returned by your eligible catalog. Read GET /products/{sku}/price and GET /balance before purchasing. Example SKUs in this reference are illustrative; replace them with catalog values.

4. Purchase and reconcile

Send POST /orders with exactly partnerReference and sku. Use a unique literal reference such as TEST-SUCCESS:order-001. A timeout does not mean the purchase failed: look up the reference or resend the identical body.

A purchase response nests the summary at data.order.order. Order lookup returns the summary at data.order. When status is PROCESSING, wait pollAfterSeconds before polling again.

Prefer Postman?

Import the TEST collection. Set partnerApiKey in a private environment, set sku, and replace partnerReference with a unique literal value. Keep the reference and SKU unchanged for retries. Choose a new reference only when you intend another purchase.

Up nextAuthentication & environments
Need help with your integration?Talk to the GiftU team