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

# Best available contiguous seats for a ticket type

> Suggests seats without reserving them: same row, front rows first, never leaving a single orphan seat. Send the ids on the hold to claim them.



## OpenAPI

````yaml /api-reference/openapi.json post /api/events/public/{slug}/seating/best-available
openapi: 3.0.0
info:
  title: UnderPass Public API
  version: 1.3.0
  description: >-
    Public API for browsing events and selling tickets on the UnderPass
    platform. Build a custom event landing or checkout on your own domain: list
    events, reserve tickets at selection, sell numbered seats, run a waiting
    room, start a checkout and poll the order. Everything added since 1.0 is
    optional and opt-in per event; a storefront built against 1.0 keeps working.
  contact:
    name: UnderPass Engineering
    email: developers@underpass.com.co
    url: https://underpass.com.co
servers:
  - url: https://api.underpass.com.co
    description: Production
  - url: https://api-dev.underpass.com.co
    description: Development
security: []
paths:
  /api/events/public/{slug}/seating/best-available:
    post:
      tags:
        - Events
      summary: Best available contiguous seats for a ticket type
      description: >-
        Suggests seats without reserving them: same row, front rows first, never
        leaving a single orphan seat. Send the ids on the hold to claim them.
      operationId: bestAvailableSeats
      parameters:
        - name: slug
          in: path
          required: true
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BestAvailableDto'
      responses:
        '200':
          description: Seats
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/SeatDto'
        '400':
          description: >-
            `INSUFFICIENT_TICKETS`: not enough free seats;
            `TICKET_TYPE_HAS_NO_ZONE`
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorDto'
        '404':
          description: '`EVENT_NOT_FOUND` / `SEATING_CHART_NOT_FOUND`'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorDto'
components:
  schemas:
    BestAvailableDto:
      type: object
      required:
        - ticket_type_id
        - count
      properties:
        ticket_type_id:
          type: string
        count:
          type: integer
          minimum: 1
          maximum: 50
        performance_id:
          type: string
          description: Required on multi-date events.
    SeatDto:
      type: object
      properties:
        id:
          type: string
        section_id:
          type: string
        row_label:
          type: string
        seat_label:
          type: string
        x:
          type: number
          description: Chart units on a width × height canvas
        'y':
          type: number
        zone_key:
          type: string
          nullable: true
          description: Overrides the section's zone when set.
        accessible:
          type: boolean
        restricted_view:
          type: boolean
        state:
          type: string
          enum:
            - AVAILABLE
            - BLOCKED
            - HOUSE
    ErrorDto:
      type: object
      properties:
        statusCode:
          type: integer
        code:
          type: string
          description: Stable identifier to match on.
        message:
          type: string
        detail:
          type: object
          additionalProperties: true
        timestamp:
          type: string
          format: date-time

````

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