Index of customers

GET customers

Example Request

GET /api/v1/customers HTTP/1.1
Host: tph.io
X-Token: c9c0a840-b5f1-4e0e-84da-e8a4eedfc63b

Response Structure

  • data: array[object]
    • id: int
    • type: string ("business""individual")
    • name: string
    • telephone_number: string
    • mobile_number: string
    • address: string
    • country: string
    • region: string
    • city: string
    • post_code: string
    • billing_address: string
    • billing_country: string
    • billing_region: string
    • billing_city: string
    • billing_post_code: string
    • billing_vat_number: string
    • billing_company_registration_number: string
    • created_at: string ("2020-01-01T00:00:00+00:00")
    • updated_at: string ("2020-01-01T00:00:00+00:00")
  • meta: object
    • first_url: string
    • last_url: string
    • next_url: string
    • previous_url: string
    • total: int
    • per_page: int
    • current_page: int
    • last_page: int
    • from: int
    • to: int

Example Response

{
  "data":[
    {
      "id":1,
      "name":"Example Customer",
      "type":"business",
      "telephone_number":"0123456789",
      "mobile_number":"0987654321",
      "address":"123 Example Address",
      "country":"US",
      "region":"Example Region",
      "city":"Example City",
      "post_code":"123 EXAMPLE",
      "billing_address":"",
      "billing_country":"",
      "billing_region":"",
      "billing_city":"",
      "billing_post_code":"",
      "billing_vat_number":"",
      "billing_company_registration_number":""
    }
  ],
  "meta":{
    "first_url":"https://tph.io/api/v1/customers",
    "last_url":"https://tph.io/api/v1/customers?page=1",
    "next_url":"https://tph.io/api/v1/customers?page=1",
    "previous_url":"https://tph.io/api/v1/customers?page=1",
    "total":1,
    "per_page":25,
    "current_page":1,
    "last_page":1,
    "from":1,
    "to":1
  }
}