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

# List customers

> Returns the organization's non-archived customers, most recently updated first.



## OpenAPI

````yaml https://api.trama.so/v1/openapi.json get /v1/customers
openapi: 3.1.0
info:
  description: >-
    Trama's REST API. Authenticate with an organization API key, created under
    Settings → Developers, and send it as `Authorization: Bearer <key>` (or in
    the `x-api-key` header).


    Every key is bound to ONE organization: everything this API returns and
    everything it writes stays inside that organization, and no request ever
    names it.


    Errors always come back as `{ "error": { "code", "message" } }`. Branch on
    `code` — it is stable; the `message` text is not.
  title: Trama API
  version: 1.0.0
servers:
  - url: https://api.trama.so
security:
  - bearerAuth: []
  - apiKeyHeader: []
paths:
  /v1/customers:
    get:
      tags:
        - Customers
      summary: List customers
      description: >-
        Returns the organization's non-archived customers, most recently updated
        first.
      parameters:
        - schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 25
            description: How many items to return. Maximum 100.
            example: 25
          required: false
          description: How many items to return. Maximum 100.
          name: limit
          in: query
        - schema:
            type:
              - integer
              - 'null'
            minimum: 0
            default: 0
            description: How many items to skip from the beginning.
            example: 0
          required: false
          description: How many items to skip from the beginning.
          name: offset
          in: query
        - schema:
            type: string
            minLength: 1
            description: >-
              Matches against the name, the summary, and the identifier of any
              of their contacts (phone number, Instagram handle, email).
          required: false
          description: >-
            Matches against the name, the summary, and the identifier of any of
            their contacts (phone number, Instagram handle, email).
          name: query
          in: query
        - schema:
            type: string
            minLength: 1
          required: false
          name: tag
          in: query
      responses:
        '200':
          description: The requested page.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CustomerList'
        '400':
          description: The request is not valid.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: The API key is missing or not valid.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: The resource does not exist in this organization.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '409':
          description: Conflict with the current state of the resource.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '429':
          description: The API key exceeded its request limit. Retry later.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
components:
  schemas:
    CustomerList:
      type: object
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/Customer'
        pagination:
          $ref: '#/components/schemas/Pagination'
      required:
        - data
        - pagination
    ErrorResponse:
      type: object
      properties:
        error:
          $ref: '#/components/schemas/ApiError'
      required:
        - error
    Customer:
      type: object
      properties:
        city:
          type:
            - string
            - 'null'
        contacts:
          type: array
          items:
            $ref: '#/components/schemas/CustomerContact'
        country:
          type:
            - string
            - 'null'
        createdAt:
          type: string
          format: date-time
        displayName:
          type:
            - string
            - 'null'
          description: >-
            First and last name joined. Null when the person has not said their
            name yet — an anonymous lead is still a valid lead.
        firstName:
          type:
            - string
            - 'null'
        id:
          type: string
        lastName:
          type:
            - string
            - 'null'
        preferredLanguage:
          type:
            - string
            - 'null'
        summary:
          type:
            - string
            - 'null'
        tags:
          type: array
          items:
            type: string
        updatedAt:
          type: string
          format: date-time
      required:
        - city
        - contacts
        - country
        - createdAt
        - displayName
        - firstName
        - id
        - lastName
        - preferredLanguage
        - summary
        - tags
        - updatedAt
    Pagination:
      type: object
      properties:
        limit:
          type: integer
        offset:
          type: integer
        total:
          type: integer
      required:
        - limit
        - offset
        - total
    ApiError:
      type: object
      properties:
        code:
          type: string
          description: >-
            A stable, machine-readable code. Branch on this — the `message` text
            may change, the code will not.
          example: CATALOG_PRODUCT_NOT_FOUND
        message:
          type: string
          example: The catalog product does not exist.
      required:
        - code
        - message
    CustomerContact:
      type: object
      properties:
        displayName:
          type:
            - string
            - 'null'
        id:
          type: string
        identifierType:
          type: string
          enum:
            - whatsapp
            - instagram
            - messenger
            - email
            - telefono
            - web
        identifierValue:
          type: string
          description: >-
            The identifier within its channel: an E.164 phone number for
            whatsapp/telefono, the handle for instagram, the address for email.
        phoneNumber:
          type:
            - string
            - 'null'
      required:
        - displayName
        - id
        - identifierType
        - identifierValue
        - phoneNumber
  securitySchemes:
    bearerAuth:
      bearerFormat: API key
      description: 'The organization API key, sent as `Authorization: Bearer <key>`.'
      scheme: bearer
      type: http
    apiKeyHeader:
      description: The same API key, sent in the `x-api-key` header.
      in: header
      name: x-api-key
      type: apiKey

````