> ## Documentation Index
> Fetch the complete documentation index at: https://docs.d-edge.com/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> This site documents the D-EDGE APIs for technology partners (web agencies, OTAs, PMS and RMS vendors, booking and CRM tools). It is written for developers integrating with hotels that use the D-EDGE platform.
> Seven APIs, grouped by domain. Connectivity: Channel Manager API (distribute a hotel's inventory to your channel and send bookings back). Pricing & Availability: Best Price API (best offers to highlight), Quotation API (all bookable offers for a stay), Daily Rates API (daily availability between two dates). Booking: Booking Engine API (a hotel's full direct booking funnel), Gift Shop API (gift vouchers from catalogue to payment). Guest Management: CRM API (guest profiles).
> Pick the API by the need: to display prices, use the Best Price API or the Daily Rates API; to quote a specific stay, use the Quotation API; to book, use the Booking Engine API; to sell gift vouchers, use the Gift Shop API; to manage guest profiles, use the CRM API; to receive hotel inventory and send bookings back as a distribution channel, use the Channel Manager API.
> Base URLs, hotel identifiers, and credentials are delivered by the D-EDGE partnership team during onboarding. Do not invent base URLs, endpoints, parameters, or example credentials that do not appear on these pages.
> Authentication differs per API: OAuth 1.0 for Best Price, Quotation, Daily Rates, and Booking Engine; an X-API-KEY header for Gift Shop; OAuth 2.0 client credentials for CRM; partner-defined credentials carried in the XML message for the Channel Manager API. Read each API's Authentication page before writing code.
> A mock environment returns realistic but fictitious data without credentials. The Postman and Insomnia collections on the API collections page target it by default. Use it for exploration and tests, never for production traffic.
> Use the official names exactly: D-EDGE, D-EDGE platform, Channel Manager API, partnership team. Do not use Back Office or Extranet.
> Each API has a Changelog page. Check it for the current behaviour before relying on an older answer. For questions these pages do not answer, direct the reader to the Contact us page.

# Branded storefront

> Build the hotel's gift shop into its own website

Hotels sell gift vouchers best from their own website, on their own domain and design. The Gift Shop API gives you the full storefront tool set: the shop's visual identity, its catalogue, a cart with gift options, and a payment page hosted by D-EDGE. Your storefront renders the shop; D-EDGE handles the money.

## Prerequisites

* An API key and the shop identifiers, delivered by D-EDGE. See [Authentication](/gift-shop-api/build/guidelines/authentication.md).
* A configured gift shop: the hotelier creates the products and sets their prices in the D-EDGE platform. The API exposes the catalogue; it does not manage it.

## How it works

Open a session for the shop, then build the page from two reads. **Get the gift shop configuration** carries the identity: name, address, contact, rating, time zone, preferred culture, theme, and the accepted payment methods with the cards each of them takes. **Search active products** carries the offer. From there, [Add a cart item](/gift-shop-api/build/reference/cart/post-cart-item.md) and [Confirm the cart](/gift-shop-api/build/reference/cart/post-cart-confirm.md) close the sale, and the guest pays on the D-EDGE-hosted page.

## Hotel shop or group shop

A gift shop is configured at hotel level or at group level in the D-EDGE platform, and the session's `owner` must match that configuration. For a hotel-level shop, send both identifiers delivered by D-EDGE:

```json theme={null}
{
  "owner": { "groupId": 90001, "hotelId": 30001 },
  "culture": "en-GB"
}
```

For a group-level shop, `hotelId` is optional: leave it out, or send `0`.

Everything downstream follows the shop you opened: the configuration carries its identity, the catalogue its products, and the order its owner. For a group-level shop, one storefront serves every property, and a value voucher sold there is spendable on the booking engines of the group's hotels. Open the session in the guest's culture (product and category names follow it); you can switch the culture mid-journey with **Update the session**, without losing the cart.

## Read the shop's identity

> [!NOTE]
>
> The examples send the `X-API-KEY` header introduced in the [Quick start](/gift-shop-api/get-started/quick-start.md). Replace `{sessionId}` with your session.

```bash cURL theme={null}
curl --request GET \
  --url 'https://{apiBaseUrl}/v1/{sessionId}/Configuration' \
  --header 'X-API-KEY: YOUR_API_KEY'
```

```javascript Node.js theme={null}
const response = await fetch("https://{apiBaseUrl}/v1/{sessionId}/Configuration", {
  headers: { "X-API-KEY": process.env.DEDGE_API_KEY },
});

const configuration = await response.json();
```

```python Python theme={null}
import os
import requests

response = requests.get(
    "https://{apiBaseUrl}/v1/{sessionId}/Configuration",
    headers={"X-API-KEY": os.environ["DEDGE_API_KEY"]},
)

configuration = response.json()
```

```php PHP theme={null}
$response = $client->get('v1/{sessionId}/Configuration', [
    'headers' => ['X-API-KEY' => getenv('DEDGE_API_KEY')],
]);

$configuration = json_decode($response->getBody(), true);
```

```csharp C# theme={null}
var request = new HttpRequestMessage(HttpMethod.Get,
    "/v1/{sessionId}/Configuration");

var response = await client.SendAsync(request);
var configuration = JsonDocument.Parse(
    await response.Content.ReadAsStringAsync()).RootElement;
```

```java Java theme={null}
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("https://{apiBaseUrl}/v1/{sessionId}/Configuration"))
    .header("X-API-KEY", System.getenv("DEDGE_API_KEY"))
    .GET()
    .build();

HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
JsonNode configuration = mapper.readTree(response.body());
```

The response carries everything the page shell needs:

```json theme={null}
{
  "details": {
    "name": "Example Hotel",
    "address": { "city": "Paris", "country": "France" },
    "contact": { "email": "hotel@example.com", "webSite": "https://www.example.com" },
    "picture": "https://cdn.example.com/hotel.jpg"
  },
  "theme": {
    "font": { "fontFamily": "DM Sans, sans-serif" },
    "brand": { "color": "#6172b8", "inverted": true },
    "header": { "color": "#f5f4f0", "inverted": false }
  },
  "paymentMethods": [
    { "name": "OnlinePayment", "cards": ["visa", "mastercard", "americanExpress"] },
    { "name": "ApplePay", "cards": [] }
  ]
}
```

Apply the theme's fonts and colours to your layout, and show the accepted payment methods near the checkout button: guests decide faster when they see their wallet is supported.

## Render the catalogue

**Search active products** returns the shop's live catalogue in the session's culture. Each product carries its pictures, description, [usage](/gift-shop-api/get-started/introduction.md#two-kinds-of-products), price (`Fixed`, or a `Range` the guest picks an amount in), quantity limits, and validity:

```json theme={null}
{
  "products": [
    {
      "id": 80001,
      "name": "Gift card",
      "category": { "id": 70001, "name": "Online" },
      "usage": "Direct",
      "price": {
        "priceType": "Range",
        "minAmount": { "amount": 150.0, "currency": "EUR" },
        "maxAmount": { "amount": 500.0, "currency": "EUR" }
      },
      "quantity": { "min": 1, "max": 10 },
      "validity": "365.00:00:00",
      "pictures": [{ "uri": "https://cdn.example.com/gift-card.jpg" }]
    }
  ]
}
```

For a `Range` price, render an amount picker bounded by `minAmount` and `maxAmount`. For a `Fixed` price, show the amount and send that exact amount when adding to the cart: the `amount` field is required in both cases, and a missing or different amount is rejected with a `400`.

## Tips

* **Cache the shell, not the cart**. The configuration, categories, and localisation lists are stable; cache them. Read the cart from the API whenever you display it, so totals and taxes are always the server's. See [Best practices](/gift-shop-api/build/best-practices.md).
* **Bring the guest home after payment**. Pass a `confirmationUrl` when you confirm the cart: after the D-EDGE-hosted payment, the guest lands back on your storefront.
* **Design for mobile first**. A large share of gift purchases happens on a phone, often days before the occasion.

## Related

> **[Get the gift shop configuration](/gift-shop-api/build/reference/configuration/get-configuration.md)**
>
> Full schema for the configuration endpoint.

> **[Search active products](/gift-shop-api/build/reference/product/post-products-search.md)**
>
> The live catalogue, in the session's culture.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.