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

# Confirm Partial Cancel

Finalize the partial cancellation of specific passengers or flight segments.

### Provider Integration Details (GDS/NDC/LCC)

Under the hood, Travomatrix orchestrates the complex logic of PNR modification across all providers.

* **PNR Splitting (Partial Pax)**: For traditional GDS carriers (Amadeus, Travelport), we issue a `DivideReservation` command to split the cancelled passengers into a new PNR, which is then cancelled. The remaining passengers stay in the original `BOOKED` or `TICKETED` PNR.
* **Segment Removal (Partial Segment)**: For LCCs and NDCs, we execute a direct segment removal and request the partial refund using the cached `Cancel Quote` rules.

### Prerequisite

A successful `POST /flight/booking/partial-cancel/quote` must be generated right before confirmation. Travomatrix pulls the target passengers and segments directly from your latest cached quote event to ensure atomic processing.


## OpenAPI

````yaml POST /flight/booking/partial-cancel/confirm
openapi: 3.0.3
info:
  title: Travomatrix B2B Travel API
  version: 1.0.0
  description: >
    Travomatrix is a high-performance multi-vertical travel booking engine
    designed for B2B enterprises.


    ### Verticals Supported

    - **Flights**: Unified interface for global GDS and NDC providers.

    - **Hotels**: Coming Soon.

    - **Rail**: Coming Soon.

    - **Cabs**: Coming Soon.


    ### Key Security & Reliability Headers

    - **X-API-Key**: Your primary server-to-server API key.

    - **Idempotency-Key**: Required for financial operations. Prevents duplicate
    actions on retries.

    - **X-Request-ID**: Optional but recommended. Used for tracing requests
    through the Travomatrix infrastructure.
servers:
  - url: https://api.travomatrix.com/api/v1
    description: Production Environment
  - url: http://uat.travomatrix.com/api/v1
    description: UAT Environment
  - url: http://localhost:80/api/v1
    description: Localhost (Port 80)
  - url: http://localhost:8080/api/v1
    description: Localhost (Port 8080)
security: []
paths:
  /flight/booking/partial-cancel/confirm:
    post:
      tags:
        - Flights - Post-Booking
      summary: Confirm Partial Cancellation
      parameters:
        - $ref: '#/components/parameters/IdempotencyHeader'
        - $ref: '#/components/parameters/RequestIDHeader'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PartialCancelConfirmRequest'
      responses:
        '200':
          description: Partial cancellation confirmed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CancelBookingResponse'
      security:
        - ApiKeyAuth: []
components:
  parameters:
    IdempotencyHeader:
      name: Idempotency-Key
      in: header
      description: >-
        A unique string to identify this request. Retrying a request with the
        same key will return the cached response.
      required: false
      schema:
        type: string
    RequestIDHeader:
      name: X-Request-ID
      in: header
      description: Unique correlation ID for tracing.
      required: false
      schema:
        type: string
  schemas:
    PartialCancelConfirmRequest:
      type: object
      required:
        - booking_id
        - passengers_to_cancel
        - segments_to_cancel
      properties:
        booking_id:
          type: string
        passengers_to_cancel:
          type: array
          items:
            type: string
        segments_to_cancel:
          type: array
          items:
            type: integer
        reason_code:
          type: string
    CancelBookingResponse:
      type: object
      properties:
        booking_id:
          type: string
        status:
          type: string
          enum:
            - CANCELLED
            - REFUNDED
            - PENDING_WITH_AIRLINE
        refund_amount_paise:
          type: integer
        airline_penalty_paise:
          type: integer
        ota_fee_paise:
          type: integer
        currency:
          type: string
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key

````