Rest API Endpoints
Learn how to use the Booknetic REST API (v1.0.0) to manage appointments and customers.
Learn how to use the Booknetic REST API (v1.0.0) to manage appointments and customers.
Booknetic includes a JSON-based REST API for working with core resources such as appointments and customers. This guide is based on the provided OpenAPI specification and presents the available endpoints in a cleaner, more developer-friendly format.
The API is intended for programmatic access to Booknetic data through standard HTTP requests and JSON payloads.
| Property | Value |
|---|---|
| Version | 1.0.0 |
| Base path | /wp-json/booknetic/v1 |
| Format | JSON (application/json) |
All endpoints in this guide are relative to:
/wp-json/booknetic/v1In a typical WordPress installation, the full base URL is:
https://your-domain.com/wp-json/booknetic/v1Requests and responses use JSON.
| Header | Value |
|---|---|
| Request header | Content-Type: application/json |
| Response header | Content-Type: application/json |
| Resource | Description |
|---|---|
| Appointments | Appointment management |
| Customers | Customer management |
The appointments resource provides endpoints for listing, creating, retrieving, updating, deleting, and changing appointment records, as well as fetching available statuses and time slots.
Returns a list of appointments.
Endpoint
GET /appointmentsResponse
200 OK — List of appointments
Response body: array of Appointment
Example response
[
{
"id": 101,
"customer_id": 55,
"service_id": 9,
"staff_id": 3,
"date": "2026-01-10T14:30:00Z",
"status": "approved"
}
]Creates a new appointment.
Endpoint
POST /appointmentsRequest body
Required — AppointmentCreate
Example request
{
"customer_id": 55,
"service_id": 9,
"staff_id": 3,
"date": "2026-01-10T14:30:00Z"
}Responses
201 Created — Appointment created
Response body: Appointment
Example response
{
"id": 102,
"customer_id": 55,
"service_id": 9,
"staff_id": 3,
"date": "2026-01-10T14:30:00Z",
"status": "pending"
}Returns a single appointment by its ID.
Endpoint
GET /appointments/{id}Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
id | integer | Yes | Appointment ID |
Responses
200 OK — Appointment
Response body: Appointment
Example response
{
"id": 102,
"customer_id": 55,
"service_id": 9,
"staff_id": 3,
"date": "2026-01-10T14:30:00Z",
"status": "pending"
}Updates an appointment by its ID.
Endpoint
PUT /appointments/{id}Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
id | integer | Yes | Appointment ID |
Request body
Required — AppointmentUpdate
Example request
{
"staff_id": 4,
"date": "2026-01-10T15:00:00Z",
"status": "approved"
}Responses
200 OK — Appointment updated
The provided OpenAPI specification does not define a response schema for this endpoint. In practice, returning the updated Appointment object would make the endpoint more predictable and easier to consume.
Deletes an appointment by its ID.
Endpoint
DELETE /appointments/{id}Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
id | integer | Yes | Appointment ID |
Responses
204 No Content — Appointment deleted
Updates the status of an appointment.
Endpoint
PUT /appointments/{id}/change-statusPath parameters
| Field | Type | Required | Description |
|---|---|---|---|
id | integer | Yes | Appointment ID |
Request body
Required
| Field | Type | Required | Description |
|---|---|---|---|
status | string | Yes | New status value |
Example request
{
"status": "approved"
}Responses
200 OK — Status updated
The provided OpenAPI specification does not define a response schema for this endpoint. A consistent implementation may return either the updated Appointment object or a standard success payload.
Returns the list of available appointment statuses.
Endpoint
GET /appointments/statusesResponses
200 OK — Available statuses
Response body: array of strings
Example response
["pending", "approved", "canceled"]Returns a list of available appointment time slots.
Endpoint
GET /appointments/available-timesResponses
200 OK — Available times
Response body: array of strings
Example response
[
"2026-01-10 14:30",
"2026-01-10 15:00",
"2026-01-10 15:30"
]The OpenAPI schema defines the example as a plain string such as "2026-01-10 14:30". If the actual implementation expects ISO 8601 values or timezone-aware values, that should be documented explicitly.
The customers resource provides endpoints for listing, retrieving, creating, updating, and deleting customer records.
Returns a list of customers.
Endpoint
GET /customersResponses
200 OK — Customer list
Response body: array of Customer
Example response
[
{
"id": 55,
"name": "Jane Doe",
"email": "[email protected]",
"phone": "+1 555 123 4567"
}
]Returns a customer by ID.
Endpoint
GET /customer/info/{id}Path parameters
| Field | Type | Required | Description |
|---|---|---|---|
id | integer | Yes | Customer ID |
Responses
200 OK — Customer info
Response body: Customer
Example response
{
"id": 55,
"name": "Jane Doe",
"email": "[email protected]",
"phone": "+1 555 123 4567"
}Creates a new customer.
Endpoint
POST /customer/createRequest body
Required — CustomerCreate
Example request
{
"name": "Jane Doe",
"email": "[email protected]",
"phone": "+1 555 123 4567"
}Responses
201 Created — Customer created
Response body: Customer
Updates an existing customer.
Endpoint
POST /customer/editRequest body
Required — CustomerUpdate
Example request
{
"id": 55,
"name": "Jane A. Doe",
"email": "[email protected]",
"phone": "+1 555 123 4567"
}Responses
200 OK — Customer updated
The provided OpenAPI specification does not define a response schema for this endpoint. Returning the updated Customer object would improve consistency.
Deletes a customer by ID.
Endpoint
POST /customer/deleteRequest body
Required
| Field | Type | Required | Description |
|---|---|---|---|
id | integer | Yes | Customer ID |
Example request
{
"id": 55
}Responses
200 OK — Customer deleted
This endpoint uses POST rather than DELETE. If that is intentional because of WordPress-specific implementation patterns, permissions, or nonce handling, the rationale should be documented clearly for API consumers.
The following schemas are described in the provided OpenAPI specification.
| Field | Type | Notes |
|---|---|---|
id | integer | Appointment ID |
customer_id | integer | Related customer ID |
service_id | integer | Related service ID |
staff_id | integer | Related staff ID |
date | string (date-time) | ISO 8601 datetime |
status | string | Appointment status |
Required fields: customer_id, service_id, date
| Field | Type | Required | Notes |
|---|---|---|---|
customer_id | integer | Yes | Customer ID |
service_id | integer | Yes | Service ID |
staff_id | integer | No | Staff ID |
date | string (date-time) | Yes | ISO 8601 datetime |
| Field | Type | Required | Notes |
|---|---|---|---|
staff_id | integer | No | Staff ID |
date | string (date-time) | No | ISO 8601 datetime |
status | string | No | Appointment status |
| Field | Type | Notes |
|---|---|---|
id | integer | Customer ID |
name | string | Customer name |
email | string (email) | Customer email |
phone | string | Customer phone |
Required fields: name
| Field | Type | Required | Notes |
|---|---|---|---|
name | string | Yes | Customer name |
email | string (email) | No | Customer email |
phone | string | No | Customer phone |
Required fields: id
| Field | Type | Required | Notes |
|---|---|---|---|
id | integer | Yes | Customer ID |
name | string | No | Customer name |
email | string (email) | No | Customer email |
phone | string | No | Customer phone |
The following table summarizes all endpoints defined in the provided specification.
| Method | Endpoint | Description |
|---|---|---|
GET | /appointments | Get appointments |
POST | /appointments | Create appointment |
GET | /appointments/{id} | Get appointment by ID |
PUT | /appointments/{id} | Update appointment |
DELETE | /appointments/{id} | Delete appointment |
PUT | /appointments/{id}/change-status | Change appointment status |
GET | /appointments/statuses | Get appointment statuses |
GET | /appointments/available-times | Get available appointment times |
| Method | Endpoint | Description |
|---|---|---|
GET | /customers | Get customers |
GET | /customer/info/{id} | Get customer info |
POST | /customer/create | Create customer |
POST | /customer/edit | Edit customer |
POST | /customer/delete | Delete customer |
A few details in the provided specification are not fully defined and would benefit from clarification in the final production documentation.
These endpoints do not define response schemas in the provided OpenAPI file:
| Endpoint | Note |
|---|---|
PUT /appointments/{id} | Updated appointment response is not defined |
PUT /appointments/{id}/change-status | Response payload is not defined |
POST /customer/edit | Updated customer response is not defined |
Returning the updated resource object for these endpoints would make the API easier to use and more consistent.
The date field is documented as string (date-time) and example request and response payloads use ISO 8601 values such as:
"2026-01-10T14:30:00Z"At the same time, the available times endpoint returns strings formatted like:
"2026-01-10 14:30"If the implementation relies on a specific timezone, local server time, or strict ISO 8601 formatting, that expectation should be documented explicitly.
The customer delete endpoint uses POST instead of DELETE:
POST /customer/deleteIf this behavior is intentional, documenting the reason will reduce confusion for developers integrating with the API.
Booknetic’s REST API provides a JSON-based interface for managing appointments and customers under the /wp-json/booknetic/v1 namespace.
The current specification includes support for:
| Resource | Operations |
|---|---|
| Appointments | List, create, retrieve, update, delete, change status, get statuses, get available times |
| Customers | List, retrieve, create, update, delete |