How can we help you?

Popup image
All Categories Developer API How to Access Customer Data Using the Zepio Developer API

How to Access Customer Data Using the Zepio Developer API

Written by Saurabh
Updated 4 months ago

Creating API Key

The Customers API allows you to read customer details from your Zepio store using a secure API key.

Create API Key

  • Login to your Zepio Admin Dashboard.
  • Go to: Settings > Developer API
  • Create a new API key and select this ability: Read customers

Use this API key when making requests to the Customers API.

Base URL

https://yourwebsite.com/api/developer/v1

Replace yourwebsite.com with your store domain.

Authentication

Send your API key as a Bearer Token in the request header.

Authorization: Bearer YOUR_API_KEY
Accept: application/json

Endpoints

Method Endpoint Description
GET /customers Get a paginated list of customers
GET /customers/{id} Get details of a single customer

Get Customers

Returns a list of customers from your store.

GET /api/developer/v1/customers

Query Parameters

Parameter Type Required Description
per_page integer No Number of customers to return per request. Maximum: 100
cursor string No Cursor value for loading the next or previous page
search string No Search customers by name, email, or phone

Example Request

curl -X GET "https://yourwebsite.com/api/developer/v1/customers?per_page=10" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Accept: application/json"

Search Customers

curl -X GET "https://yourwebsite.com/api/developer/v1/customers?search=rahul" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Accept: application/json"

Example Response

{
  "success": true,
  "message": "OK",
  "data": [
    {
      "id": 12,
      "name": "Rahul Sharma",
      "email": "rahul@example.com",
      "phone": "9876543210",
      "created_at": "2026-06-08T10:30:00.000000Z",
      "email_verified_at": null,
      "is_ban": false,
      "is_cod_disabled": false,
      "orders_count": 8,
      "completed_orders_count": 5,
      "customer_wallet": 250,
      "customer_reward": 40,
      "push_tokens": [
        "fMx3Kp9...:APA91bH...",
        "dQ7rTn2...:APA91bG..."
      ]
    }
  ],
  "meta": {
    "per_page": 10,
    "next_page_url": "https://yourwebsite.com/api/developer/v1/customers?per_page=10&cursor=eyJpZCI6MTEsIl9wb2ludHNUb05leHRJdGVtcyI6dHJ1ZX0",
    "prev_page_url": null,
    "has_more": true
  }
}

Pagination

This API uses cursor based pagination.

To load the next page, call the next_page_url from the response. It already has the cursor value in it. When has_more is false, there are no more customers to load.

You can also pass the cursor yourself:

curl -X GET "https://yourwebsite.com/api/developer/v1/customers?per_page=10&cursor=NEXT_CURSOR_VALUE" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Accept: application/json"

Get Single Customer

Returns details of a single customer by customer ID.

GET /api/developer/v1/customers/{id}

Example Request

curl -X GET "https://yourwebsite.com/api/developer/v1/customers/12" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Accept: application/json"

Example Response

{
  "success": true,
  "message": "OK",
  "data": {
    "id": 12,
    "name": "Rahul Sharma",
    "email": "rahul@example.com",
    "phone": "9876543210",
    "created_at": "2026-06-08T10:30:00.000000Z",
    "email_verified_at": null,
    "is_ban": false,
    "is_cod_disabled": false,
    "orders_count": 8,
    "completed_orders_count": 5,
    "cancelled_orders_count": 1,
    "customer_wallet": 250,
    "customer_reward": 40,
    "push_tokens": [
      "fMx3Kp9...:APA91bH..."
    ]
  }
}

Response Fields

Field Description
id Customer ID
name Customer name
email Customer email address
phone Customer phone number
created_at Date and time when the customer account was created
email_verified_at Date and time when email was verified. Can be null
is_ban Shows whether the customer is banned
is_cod_disabled Shows whether Cash on Delivery is disabled for the customer
orders_count Total number of orders placed by the customer
completed_orders_count Total completed orders
cancelled_orders_count Total cancelled orders. Available in single customer API
customer_wallet Customer wallet balance
customer_reward Customer rewards wallet balance
push_tokens Array of push notification tokens, one for each device the customer allowed notifications on. Empty [] if there are none

Notes

  • Only customers are returned from this API.
  • The API key must have Read customers ability.
  • Maximum per_page value is 100.
  • Use cursor pagination for loading more customers.
  • Search works with customer name, email, and phone number.
  • push_tokens are Firebase Cloud Messaging tokens. A customer who uses your store on more than one device can have more than one token.
Did this answer your question?
Sad
Neutral
Happy

Not finding what you are looking for?

Chat with us or send us an email.


Stackcanyon Technologies LLP

© Zepio All rights reserved 2026