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

# Cancel a booking

> Cancel a booking or pickup by booking ID or pickup number.



## OpenAPI

````yaml openapi.json post /book/cancel
openapi: 3.0.0
info:
  title: ShipPeek API
  version: 1.0.0
  description: Multi-carrier shipping rate aggregation, booking, and tracking API.
  contact:
    name: ShipPeek API Support
    email: yash@shippeek.com
  license:
    name: Apache 2.0
    url: https://www.apache.org/licenses/LICENSE-2.0.html
  termsOfService: https://shippeek.com/terms
servers:
  - url: https://api.shippeek.dev
    description: Sandbox
  - url: https://api.shippeek.com
    description: Production
security:
  - bearerAuth: []
tags:
  - name: Rates
    description: Get shipping rates from multiple carriers
  - name: Booking
    description: Book shipments and manage pickups
  - name: Tracking
    description: Track shipments by PRO or tracking number
  - name: Shipments
    description: Retrieve and search shipment data
paths:
  /book/cancel:
    post:
      tags:
        - Booking
      summary: Cancel a booking
      description: Cancel a booking or pickup by booking ID or pickup number.
      operationId: cancelBooking
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                bookingId:
                  type: string
                  description: The booking ID to cancel
                pickupNumber:
                  type: string
                  description: The pickup number to cancel
      responses:
        '200':
          description: Booking cancelled successfully
        '400':
          description: Bad request
        '404':
          description: Booking not found
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Your ShipPeek API token in the format `client_id.client_secret`.

````