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

# List locations

> The stores or plants your terminals work from, ordered by `id`. Payra sets them up with you; each terminal names its own in `location`.



## OpenAPI

````yaml /api-reference/openapi-v1.json get /locations
openapi: 3.1.0
info:
  title: Payra API
  version: v1
  description: >-
    The Payra API. Authenticate with a secret key: `Authorization: Bearer
    sk_test_...`. The two payment method session endpoints Payra Elements calls
    also take a publishable key with the session's `client_secret`.
servers:
  - url: https://api-dashboard.payra.com/v1
    description: 'Sandbox and live: the key decides which'
security: []
paths:
  /locations:
    get:
      tags:
        - Locations
      summary: List locations
      description: >-
        The stores or plants your terminals work from, ordered by `id`. Payra
        sets them up with you; each terminal names its own in `location`.
      parameters:
        - schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 20
            example: 20
            description: How many to return, 1 to 100.
          required: false
          description: How many to return, 1 to 100.
          name: limit
          in: query
        - schema:
            type: string
            format: uuid
            description: >-
              The `id` of the last location of the previous page; the page after
              it is returned.
          required: false
          description: >-
            The `id` of the last location of the previous page; the page after
            it is returned.
          name: starting_after
          in: query
      responses:
        '200':
          description: A page of locations
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/LocationList'
        '400':
          description: Invalid parameters
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Missing, invalid or revoked API key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: The API is not enabled for the workspace, or the key lacks the scope
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '429':
          description: Rate limit exceeded; see Retry-After
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '500':
          description: Internal error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - bearerAuth: []
components:
  schemas:
    LocationList:
      type: object
      properties:
        object:
          type: string
          enum:
            - list
        data:
          type: array
          items:
            $ref: '#/components/schemas/Location'
        has_more:
          type: boolean
      required:
        - object
        - data
        - has_more
    Error:
      type: object
      properties:
        error:
          type: object
          properties:
            type:
              type: string
              enum:
                - invalid_request_error
                - authentication_error
                - permission_error
                - rate_limit_error
                - idempotency_error
                - card_error
                - api_error
            code:
              type: string
            message:
              type: string
            param:
              type: string
            request_id:
              type: string
          required:
            - type
            - code
            - message
            - request_id
          additionalProperties:
            type: string
      required:
        - error
    Location:
      type: object
      properties:
        object:
          type: string
          enum:
            - location
        id:
          type: string
          format: uuid
          example: 019f2c4e-6a10-7b2c-8d31-2a4b6c8d0e12
          description: Pass it as `location` to list or move terminals.
        name:
          type: string
          example: Cheyenne plant
        time_zone:
          type:
            - string
            - 'null'
          example: America/Denver
          description: >-
            IANA time zone the nightly release follows for terminals here (2 AM
            local); `null` follows your account's.
        livemode:
          type: boolean
          example: false
      required:
        - object
        - id
        - name
        - time_zone
        - livemode
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        A secret key, `sk_test_...` or `sk_live_...`; a publishable key
        (`pk_...`) on the browser routes only

````

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