Customers

Get Customers

Retrieves the customers.

get/v1/shops/{shopId}/customers

Request body

pageinteger

Page number.

perPageinteger

Items per page, 1-100. Must be at least 1. Must not be greater than 100.

orderColumn'id' | 'email' | 'discord_id' | 'discord_username' | 'balance' | 'total_completed' | 'total_spent_usd' | 'last_completed_at' | 'newsletter_at' | 'affiliate_code'
orderDirection'asc' | 'desc'
idstring

Filter by customer ID.

emailstring

Filter by email.

discord_idstring
discord_usernamestring
subscribedstring

Only newsletter subscribers.

affiliate_codestring

Filter by affiliate code.

affiliate_referrer_emailstring

Filter by referring affiliate email.

Example request

{
  "page": 1
}

Response

current_pageinteger
first_page_urlstring
frominteger
last_pageinteger
last_page_urlstring
next_page_urlstring
pathstring
per_pageinteger
prev_page_urlstring
tointeger
totalinteger

Example response

{
  "current_page": 1,
  "data": [
    {
      "id": 3,
      "email": "reseller@sellauth.test",
      "discord_id": null,
      "discord_username": null,
      "balance": "100.00",
      "total_completed": 0,
      "total_spent_usd": "0.00",
      "last_completed_at": null,
      "newsletter_at": null,
      "affiliate_code": null,
      "affiliate_referrer_id": null,
      "affiliate_referrer": null
    },
    {
      "id": 2,
      "email": "customer-240@sellauth.test",
      "discord_id": null,
      "discord_username": null,
      "balance": "0.00",
      "total_completed": 0,
      "total_spent_usd": "0.00",
      "last_completed_at": null,
      "newsletter_at": null,
      "affiliate_code": null,
      "affiliate_referrer_id": null,
      "affiliate_referrer": null
    },
    {
      "id": 1,
      "email": "customer@sellauth.test",
      "discord_id": null,
      "discord_username": null,
      "balance": "0.00",
      "total_completed": 0,
      "total_spent_usd": "0.00",
      "last_completed_at": null,
      "newsletter_at": null,
      "affiliate_code": "PARTNER10",
      "affiliate_referrer_id": null,
      "affiliate_referrer": null
    }
  ],
  "first_page_url": "http://api.sellauth.test/v1/shops/1/customers?page=1",
  "from": 1,
  "last_page": 1,
  "last_page_url": "http://api.sellauth.test/v1/shops/1/customers?page=1",
  "links": [
    {
      "url": null,
      "label": "« Previous",
      "active": false
    },
    {
      "url": "http://api.sellauth.test/v1/shops/1/customers?page=1",
      "label": "1",
      "active": true
    },
    {
      "url": null,
      "label": "Next »",
      "active": false
    }
  ],
  "next_page_url": null,
  "path": "http://api.sellauth.test/v1/shops/1/customers",
  "per_page": 20,
  "prev_page_url": null,
  "to": 3,
  "total": 3
}

Changes

No recorded changes to this endpoint across all 1 revision of this API.