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

# List Pairs

> Endpoint to retrieve pairs of professional padel players that have played at least one match together, ordered by the date of their most recent match together by default.



## OpenAPI

````yaml https://padelapi.org/docs/api.json get /pairs
openapi: 3.1.0
info:
  title: Padel API – API Reference
  version: '1.0'
  description: padelapi.org
servers:
  - url: https://padelapi.org/api
security:
  - http: []
paths:
  /pairs:
    get:
      tags:
        - Pair
      summary: List Pairs
      description: >-
        Endpoint to retrieve pairs of professional padel players that have
        played at least one match together, ordered by the date of their most
        recent match together by default.
      operationId: listPairs
      parameters:
        - name: category
          in: query
          description: Category of the pair, either `men` or `women`.
          schema:
            type:
              - string
              - 'null'
            enum:
              - men
              - women
        - name: after_date
          in: query
          description: >-
            Date after which the pair has played a match in `YYYY-MM-DD` format.
            Pairs without matches in the range are excluded.
          schema:
            type:
              - string
              - 'null'
            format: date
        - name: before_date
          in: query
          description: >-
            Date before which the pair has played a match in `YYYY-MM-DD`
            format.
          schema:
            type:
              - string
              - 'null'
            format: date
        - name: sort_by
          in: query
          description: >-
            Name of the parameter to sort the pairs by. Defaults to
            `last_match_at` (date of their most recent match together, desc).
          schema:
            type:
              - string
              - 'null'
            enum:
              - last_match_at
              - first_match_at
        - name: page
          in: query
          schema:
            type: integer
            default: 1
      responses:
        '200':
          description: Paginated set of `PairResource`
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/PairResource'
                  links:
                    type: object
                    properties:
                      first:
                        type:
                          - string
                          - 'null'
                      last:
                        type:
                          - string
                          - 'null'
                      prev:
                        type:
                          - string
                          - 'null'
                      next:
                        type:
                          - string
                          - 'null'
                    required:
                      - first
                      - last
                      - prev
                      - next
                  meta:
                    type: object
                    properties:
                      current_page:
                        type: integer
                      from:
                        type:
                          - integer
                          - 'null'
                      last_page:
                        type: integer
                      links:
                        type: array
                        description: Generated paginator links.
                        items:
                          type: object
                          properties:
                            url:
                              type:
                                - string
                                - 'null'
                            label:
                              type: string
                            active:
                              type: boolean
                          required:
                            - url
                            - label
                            - active
                      path:
                        type:
                          - string
                          - 'null'
                        description: Base path for paginator generated URLs.
                      per_page:
                        type: integer
                        description: Number of items shown per page.
                      to:
                        type:
                          - integer
                          - 'null'
                        description: Number of the last item in the slice.
                      total:
                        type: integer
                        description: Total number of items being paginated.
                    required:
                      - current_page
                      - from
                      - last_page
                      - links
                      - path
                      - per_page
                      - to
                      - total
                required:
                  - data
                  - links
                  - meta
        '401':
          $ref: '#/components/responses/AuthenticationException'
        '422':
          $ref: '#/components/responses/ValidationException'
components:
  schemas:
    PairResource:
      type: object
      properties:
        id:
          type: string
        self:
          type: string
        name:
          type: string
        category:
          type: string
        status:
          type: string
        points:
          type:
            - integer
            - 'null'
        first_match_at:
          type: string
        last_match_at:
          type: string
        players:
          type: array
          items:
            $ref: '#/components/schemas/PlayerResource'
        connections:
          type: string
      required:
        - id
        - self
        - name
        - category
        - status
        - points
        - first_match_at
        - last_match_at
        - players
        - connections
      title: PairResource
    PlayerResource:
      type: object
      properties:
        id:
          type: integer
        self:
          type: string
        name:
          type: string
        short_name:
          type: string
        url:
          type:
            - string
            - 'null'
        photo_url:
          type:
            - string
            - 'null'
        category:
          type: string
        nationality:
          type: string
        ranking:
          type: string
        points:
          type: integer
        height:
          type:
            - integer
            - 'null'
        side:
          type: string
        hand:
          anyOf:
            - type: 'null'
            - type: string
              enum:
                - left
                - right
        birthplace:
          type:
            - string
            - 'null'
        birthdate:
          type:
            - string
            - 'null'
        age:
          type:
            - string
            - 'null'
        links:
          type: string
        updated_at:
          type: string
        connections:
          type: object
          properties:
            matches:
              type: string
            pairs:
              type: string
              description: '''rankings'' => "/api/players/{$this->id}/rankings",'
            stats:
              type: string
          required:
            - matches
            - pairs
            - stats
      required:
        - id
        - self
        - name
        - short_name
        - url
        - photo_url
        - category
        - nationality
        - ranking
        - points
        - height
        - side
        - hand
        - birthplace
        - birthdate
        - age
        - links
        - updated_at
        - connections
      title: PlayerResource
  responses:
    AuthenticationException:
      description: Unauthenticated
      content:
        application/json:
          schema:
            type: object
            properties:
              message:
                type: string
                description: Error overview.
            required:
              - message
    ValidationException:
      description: Validation error
      content:
        application/json:
          schema:
            type: object
            properties:
              message:
                type: string
                description: Errors overview.
              errors:
                type: object
                description: A detailed description of each field that failed validation.
                additionalProperties:
                  type: array
                  items:
                    type: string
            required:
              - message
              - errors
  securitySchemes:
    http:
      type: http
      scheme: bearer

````