Skip to main content
GET
/
wp-json
/
latepoint-api
/
v1
/
customers
List Customers
curl --request GET \
  --url https://your-site.com/wp-json/latepoint-api/v1/customers \
  --header 'X-API-Key: <x-api-key>'
{
  "success": true,
  "data": [
    {
      "id": 123,
      "first_name": "<string>",
      "last_name": "<string>",
      "email": "<string>",
      "phone": "<string>",
      "status": "<string>",
      "is_guest": "<string>",
      "admin_notes": "<string>",
      "created_at": "<string>",
      "updated_at": "<string>",
      "stats": {
        "total_bookings": "<string>",
        "completed_bookings": 123,
        "cancelled_bookings": 123,
        "future_bookings": "<string>",
        "total_spent": "<string>",
        "last_booking_date": "<string>",
        "next_booking_date": "<string>"
      },
      "custom_fields": {}
    }
  ],
  "pagination": {
    "page": 123,
    "per_page": 123,
    "total": 123,
    "total_pages": 123,
    "has_next_page": true,
    "has_previous_page": true
  }
}

Documentation Index

Fetch the complete documentation index at: https://docs-restapi.wplimit.com/llms.txt

Use this file to discover all available pages before exploring further.

Description

This endpoint returns a paginated list of all customers registered in the system. You can filter, search and sort the results according to your needs.

Authentication

X-API-Key
string
required
Your LatePoint API Key with read permissions

Query Parameters

Pagination

page
integer
default:"1"
Page number to retrieve
per_page
integer
default:"20"
Number of customers per page (maximum 100)

Filters

status
string
Filter by customer statusPossible values:
  • active - Active customers
  • inactive - Inactive customers
  • blocked - Blocked customers
created_after
string
Show only customers created after this date (format: YYYY-MM-DD)
created_before
string
Show only customers created before this date (format: YYYY-MM-DD)
has_bookings
boolean
Filter customers who have or don’t have bookings
  • true - Only customers with bookings
  • false - Only customers without bookings

Dynamic Field Filters

first_name
string
Filter by customer’s first name (partial match)
last_name
string
Filter by customer’s last name (partial match)
email
string
Filter by customer’s email address (partial match)
phone
string
Filter by customer’s phone number (partial match)
is_guest
boolean
Filter by guest status
  • true - Only guest customers
  • false - Only registered customers
wordpress_user_id
integer
Filter by WordPress user ID (exact match)
created_at
string
Filter by creation date (partial match, format: YYYY-MM-DD)
updated_at
string
Filter by last update date (partial match, format: YYYY-MM-DD)
Search customers by first name, last name, or email (partial match)

Response

Successful Response (200 OK)

success
boolean
Always true on success
data
array
Array of customer objects
pagination
object
Pagination information

Examples

List All Customers

curl -X GET "https://your-site.com/wp-json/latepoint-api/v1/customers" \
  -H "X-API-Key: lp_live_1234567890abcdef"

Search Customers with Dynamic Filters

curl -X GET "https://your-site.com/wp-json/latepoint-api/v1/customers?first_name=Carlos&last_name=Lopez&status=active" \
  -H "X-API-Key: lp_live_1234567890abcdef"

Filter by Phone and Guest Status

curl -X GET "https://your-site.com/wp-json/latepoint-api/v1/customers?phone=555&is_guest=true&include=stats" \
  -H "X-API-Key: lp_live_1234567890abcdef"

Filter by Creation Date

curl -X GET "https://your-site.com/wp-json/latepoint-api/v1/customers?created_at=2024-01&has_bookings=true" \
  -H "X-API-Key: lp_live_1234567890abcdef"

Paginate Through All Customers

JavaScript
async function getAllCustomers() {
  let allCustomers = [];
  let currentPage = 1;
  let hasNextPage = true;

  while (hasNextPage) {
    const params = new URLSearchParams({ page: currentPage, per_page: 100 });
    const response = await fetch(`https://your-site.com/wp-json/latepoint-api/v1/customers?${params}`, {
      headers: { 'X-API-Key': 'YOUR_API_KEY' }
    });
    const result = await response.json();

    if (result.success) {
      allCustomers = allCustomers.concat(result.data);
      hasNextPage = result.pagination.has_next_page;
      currentPage++;
      console.log(`Page ${currentPage - 1}/${result.pagination.total_pages}`);
    } else {
      break;
    }
  }
  return allCustomers;
}

Example Response

{
  "success": true,
  "data": [
    {
      "id": "30",
      "first_name": "Carlos",
      "last_name": "Rodriguez",
      "email": "carlos@example.com",
      "phone": "+59887222333",
      "status": "pending_verification",
      "is_guest": "1",
      "notes": "",
      "admin_notes": "",
      "wordpress_user_id": null,
      "created_at": "2025-09-24 06:10:34",
      "updated_at": "2026-01-27 22:23:23",
      "stats": {
        "total_bookings": "3",
        "completed_bookings": 3,
        "cancelled_bookings": 0,
        "future_bookings": "0",
        "total_spent": "46.00",
        "last_booking_date": "2026-03-02",
        "next_booking_date": null
      },
      "custom_fields": {
        "cf_JLIkv6Md": "24"
      }
    }
  ],
  "pagination": {
    "page": 1,
    "per_page": 10,
    "total": 29,
    "total_pages": 3,
    "has_next_page": true,
    "has_previous_page": false
  }
}

Error Responses

Error 401 - Unauthorized
{
  "code": "rest_forbidden",
  "message": "Unauthorized",
  "data": { "status": 401 }
}

Common Use Cases

Filter by Name and Status

GET /wp-json/latepoint-api/v1/customers?first_name=Carlos&status=active
X-API-Key: YOUR_API_KEY

Search by Email Domain

GET /wp-json/latepoint-api/v1/customers?email=gmail.com&per_page=50
X-API-Key: YOUR_API_KEY

Customers Created This Year

GET /wp-json/latepoint-api/v1/customers?created_after=2025-01-01&per_page=100
X-API-Key: YOUR_API_KEY
Stats and custom fields are always included in every customer in the response — you do not need to pass any include parameter.
Sorting: Results are always returned sorted by created_at DESC. Sorting is not configurable on this endpoint.