> ## 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.

# Provides an ongoing promotion

> Provides an ongoing promotion for a given session

When no promotion is active for the session's hotel, the endpoint answers `204 No Content` with no body. Treat it as "no promotion", not as an error.


## OpenAPI

````yaml booking-engine-api/open-api/booking-engine-api.json GET /v2/{sessionId}/promotion
openapi: 3.0.1
info:
  title: Booking Engine API
  version: v2
servers:
  - url: https://{apiBaseUrl}
    variables:
      apiBaseUrl:
        default: api.example.com
        description: Base URL delivered by D-EDGE during partnership setup
security: []
tags:
  - name: Basket
  - name: Booking
  - name: Configuration
  - name: Description
  - name: Loyalty
  - name: Promotion
  - name: Resources
  - name: Search
  - name: Session
paths:
  /v2/{sessionId}/promotion:
    get:
      tags:
        - Promotion
      summary: Provides an ongoing promotion for a given session.
      description: "Returns the latest active public promotion (offer code) applicable to\r\nthe session's hotel.\r\nReturns 204 No Content if no promotion is currently active."
      operationId: Promotion_GetOngoingPromotion
      parameters:
        - name: X-AVP-Impersonation
          in: header
          description: The session identifier.
          required: false
          schema:
            type: string
        - name: sessionId
          in: path
          required: true
          schema:
            type: string
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/BookingEngine.Hub.Repositories.OfferCode.HubPlanningOfferCode
              examples:
                response:
                  value:
                    id: 00000000-0000-0000-0000-000000000000
                    hotelId: '10133'
                    description: vfsoihfe
                    isPublic: true
                    isMobile: false
                    isFlashSales: true
                    displayCountdown: true
                    endDate: '2026-06-08T00:00:00Z'
                    discount:
                      calculationMode: None
                      percent: 0
                      nominal:
                        amount: 0
                        currency: EUR
            text/json:
              schema:
                $ref: >-
                  #/components/schemas/BookingEngine.Hub.Repositories.OfferCode.HubPlanningOfferCode
              examples:
                response:
                  value:
                    id: 00000000-0000-0000-0000-000000000000
                    hotelId: '10133'
                    description: vfsoihfe
                    isPublic: true
                    isMobile: false
                    isFlashSales: true
                    displayCountdown: true
                    endDate: '2026-06-08T00:00:00Z'
                    discount:
                      calculationMode: None
                      percent: 0
                      nominal:
                        amount: 0
                        currency: EUR
        '204':
          description: No promotion is currently active for the session's hotel
        '400':
          description: The session code is invalid
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/BookingEngine.Hub.Service.Examples.Session.InvalidSessionErrorResponse
              examples:
                response:
                  value:
                    code: InvalidHotelId
            text/json:
              schema:
                $ref: >-
                  #/components/schemas/BookingEngine.Hub.Service.Examples.Session.InvalidSessionErrorResponse
              examples:
                response:
                  value:
                    code: InvalidHotelId
        '401':
          description: >-
            Authentication header is invalid or does not give access to the
            operation
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/BookingEngine.Hub.Service.Controllers.ErrorResponse_BookingEngine.Hub.Service.Config.SecurityErrorType_
            text/json:
              schema:
                $ref: >-
                  #/components/schemas/BookingEngine.Hub.Service.Controllers.ErrorResponse_BookingEngine.Hub.Service.Config.SecurityErrorType_
components:
  schemas:
    BookingEngine.Hub.Repositories.OfferCode.HubPlanningOfferCode:
      required:
        - id
        - hotelId
        - isPublic
        - isMobile
        - isFlashSales
        - displayCountdown
        - endDate
      type: object
      properties:
        id:
          $ref: '#/components/schemas/HotelBusiness.OfferCode.Common.OfferCodeId'
        hotelId:
          $ref: '#/components/schemas/Common.HubHotelId'
        code:
          type: string
        description:
          type: string
        isPublic:
          type: boolean
        isMobile:
          type: boolean
        isFlashSales:
          type: boolean
        displayCountdown:
          type: boolean
        endDate:
          format: date-time
          type: string
        discount:
          $ref: >-
            #/components/schemas/BookingEngine.Hub.Repositories.OfferCode.HubOfferCodeInfoDiscount
    BookingEngine.Hub.Service.Examples.Session.InvalidSessionErrorResponse:
      required:
        - code
      type: object
      properties:
        code:
          default: InvalidSessionId
          type: string
        message:
          type: string
    BookingEngine.Hub.Service.Controllers.ErrorResponse_BookingEngine.Hub.Service.Config.SecurityErrorType_:
      allOf:
        - $ref: >-
            #/components/schemas/BookingEngine.Hub.Service.Controllers.ErrorResponse
        - required:
            - code
          type: object
          properties:
            code:
              $ref: >-
                #/components/schemas/BookingEngine.Hub.Service.Config.SecurityErrorType
    HotelBusiness.OfferCode.Common.OfferCodeId:
      format: uuid
      type: string
    Common.HubHotelId:
      type: string
    BookingEngine.Hub.Repositories.OfferCode.HubOfferCodeInfoDiscount:
      required:
        - calculationMode
        - percent
        - nominal
      type: object
      properties:
        calculationMode:
          $ref: '#/components/schemas/Common.HubDiscountCalculationMode'
        percent:
          $ref: '#/components/schemas/HotelBusiness.Percent'
        nominal:
          $ref: '#/components/schemas/Library.Money'
    BookingEngine.Hub.Service.Controllers.ErrorResponse:
      type: object
      properties:
        message:
          type: string
    BookingEngine.Hub.Service.Config.SecurityErrorType:
      description: >-
        Category of security failure returned when authentication or
        authorization is rejected.
      enum:
        - InvalidUserAuthentication
        - InvalidUserRoles
        - InvalidPermissions
      type: string
    Common.HubDiscountCalculationMode:
      description: >-
        How a discount amount is computed against the base price.


        - **None** — No discount computation applies.

        - **PercentageWithoutExtras** — Percentage discount applied to the rate
        excluding extras.

        - **Percentage** — Percentage discount applied to the whole basket
        including extras.

        - **Nominal** — Flat monetary amount subtracted from the price.
      enum:
        - None
        - PercentageWithoutExtras
        - Percentage
        - Nominal
      type: string
    HotelBusiness.Percent:
      format: decimal
      type: number
    Library.Money:
      required:
        - amount
        - currency
      type: object
      properties:
        amount:
          format: decimal
          type: number
        currency:
          type: string

````

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