Retrieve customers

Retrieves a list of customers.

SecurityAPI Key: SecretApiKey or HTTP: JWT or HTTP: ApplicationJWT
Request
query Parameters
limit
integer [ 0 .. 1000 ]

Limits the number of collection items to be returned.

offset
integer [ 0 .. 1000 ]

Specifies the starting point within the collection of items to be returned.

filter
string

Filters the collection items. This field requires a special format. Use , for multiple allowed values. Use ; for multiple fields.

For more information, see Using filter with collections.

q
string

Use this field to perform a partial search of text fields.

expand
string

Expands a request to include embedded objects within the _embedded property of the response. This field accepts a comma-separated list of objects.

For more information, see Expand to include embedded objects.

fields
string

Limits the returned fields to the specified list, each field separated by a comma. The ID value is always returned.

sort
Array of strings

Sorts and orders the collection of items. To sort in descending order, prefix with -. Multiple fields can be sorted by separating each with ,.

get
/customers
Request samples
$customers = $client->customers()->search([
    'filter' => 'firstName:John',
]);
Responses

200

List of customers retrieved.

Response Headers
Pagination-Total
integer

Total number of items.

Example: 332
Pagination-Limit
integer

Maximum number of items per page.

Example: 100
Pagination-Offset
integer

Specifies the starting point within the collection of resource results. For example, a request with limit=20 retrieves and displays the first 20 results on a page. A following request with limit=20 and offset=20, retrieves the next page of 20 results.

Example: 2
Response Schema: application/json
Array
id
string <= 50 characters

ID of the customer.

email
string or null <email>

Customer's email address.

firstName
string or null

Customer's first name.

lastName
string or null

Customer's last name.

websiteId
string <= 50 characters
Vaulted payment instrument (object) or Alternative instrument (object) or Cash (object) or Check (object) or null
createdTime
string <date-time> (CreatedTime)

Date and time which is set automatically when the resource is created.

updatedTime
string <date-time> (UpdatedTime)

Date and time which updates automatically when the resource is updated.

customFields
object (ResourceCustomFields)

Use custom fields to extend a resource scheme to include custom data that is not provided as a common field. For more information, see Custom fields.

ContactObject (object) or null

Customer's primary address.

object or null (Company)

Company information that is associated with the customer's primary email address domain.

This is a paid feature, to enable it contact Rebilly.

object (CustomerAverageValue)

Average customer value.

paymentCount
integer

Total number of approved payments made by the customer.

lastPaymentTime
string or null <date-time>

Time and date of the customer's last approved payment.

object (CustomerLifetimeRevenue)

Customer's lifetime revenue.

invoiceCount
integer

Total number of invoices issued to the customer. This value is auto-incrementing. If this value is 0, the record relates to a lead. A lead is a customer who has not made a payment yet. If this value is greater than or equal to 1 the record relates to a customer.

Array of objects (Tag)

List of customer tags.

revision
integer

Number of times the customer's data has been modified.

Use this value when analyzing webhook data to determine if a change must take precedence over the current representation.

isEddRequired
boolean
Default: false

Specifies if Enhanced Due Diligence (EDD) is enabled for this customer. For more information, see Enhanced Due Diligence.

hasFulfilledKyc
boolean

Specifies if the customer has accepted and reviewed identity and address documents, or an accepted credit file document.

organizationId
string <= 50 characters

Unique organization identifier. An organization is an entity that represents a company. For more information, see Obtain an organization ID.

Array of objects or null (TaxNumber)

Tax numbers of the customer.

Array of objects

Related links.

object

Embedded objects that are requested using the expand query string parameter.

401

Unauthorized access. Invalid credentials used.

403

Access forbidden.

Response samples
application/json
[ { "id": "cus_0YV7DDSDD1C8DA64KHH2W33CPF", "email": "user@example.com", "firstName": "string", "lastName": "string", "websiteId": "web_0YV7DE4Z26DQSA1AC92FBJ7SEG", "createdTime": "2019-08-24T14:15:22Z", "updatedTime": "2019-08-24T14:15:22Z", "paymentCount": 0, "lastPaymentTime": "2019-08-24T14:15:22Z", "invoiceCount": 0, "revision": 0, "isEddRequired": false, "hasFulfilledKyc": true, "organizationId": "org_0YVDM8RC7GDADADSBSMW124JA8", } ]