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

# List customers

> Retrieve a paginated list of customers.



## OpenAPI

````yaml api-reference/schema.yaml get /customers/
openapi: 3.0.3
info:
  title: ''
  version: 0.0.0
servers:
  - url: https://api.parceltracer.com/v1/external/
    description: Parcel Tracer api endpoint
security: []
paths:
  /customers/:
    get:
      tags:
        - Customers
      summary: List customers
      description: Retrieve a paginated list of customers.
      operationId: list_customers
      parameters:
        - in: query
          name: include_locations
          schema:
            type: boolean
            default: false
          description: If true, includes locations data for each customer.
        - name: page
          required: false
          in: query
          description: A page number within the paginated result set.
          schema:
            type: integer
        - name: page_size
          required: false
          in: query
          description: Number of results to return per page.
          schema:
            type: integer
        - in: query
          name: phone_number
          schema:
            type: string
            default: ''
          description: >-
            Filter result by a specific phone number. Given that customer's
            phone numbers are unique, the result will contain at most a single
            customer object
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaginatedCustomerList'
              examples:
                CustomerListExample:
                  value:
                    count: 123
                    next: http://api.example.org/accounts/?page=4
                    previous: http://api.example.org/accounts/?page=2
                    results:
                      - - id: 1
                          name: John Doe
                          phone_number: '+1234567890'
                          secondary_phone_number: ''
                          email: john@example.com
                          locations:
                            - id: 10
                              area:
                                name_en: Aaiyat
                                name_ar: عيات
                                lat: 34.53534
                                long: 36.19682
                                district: Akkar
                                maps_link: >-
                                  http://maps.google.com/maps?q=34.53534,36.19682
                              directions: ''
                        - id: 2
                          name: Jane Smith
                          phone_number: '+1987654321'
                          secondary_phone_number: ''
                          email: jane@example.com
                          locations: []
                  summary: A sample list of customers
          description: ''
      security:
        - MerchantAPIKey: []
components:
  schemas:
    PaginatedCustomerList:
      type: object
      required:
        - count
        - results
      properties:
        count:
          type: integer
          example: 123
        next:
          type: string
          nullable: true
          format: uri
          example: http://api.example.org/accounts/?page=4
        previous:
          type: string
          nullable: true
          format: uri
          example: http://api.example.org/accounts/?page=2
        results:
          type: array
          items:
            $ref: '#/components/schemas/Customer'
    Customer:
      type: object
      properties:
        id:
          type: integer
          readOnly: true
        name:
          type: string
          maxLength: 255
        phone_number:
          type: string
        secondary_phone_number:
          type: string
        email:
          type: string
          format: email
      required:
        - id
        - name
        - phone_number
  securitySchemes:
    MerchantAPIKey:
      type: apiKey
      in: header
      name: X-Api-Key

````