REST API Overview
WP Sell Services provides a comprehensive REST API with 20 controllers. Base URL: /wp-json/wpss/v1/
Authentication
- Cookie authentication (browser-based) — include
X-WP-Nonceheader - Application Passwords (WordPress 5.6+) — Basic auth
- JWT tokens [PRO]
Generic Endpoints
| Endpoint | Method | Description |
|---|---|---|
| /categories | GET | Service categories |
| /tags | GET | Service tags |
| /settings | GET | Public settings |
| /me | GET | Current user info |
| /dashboard | GET | Dashboard stats |
| /batch | POST | Up to 25 requests in one call |
| /search | GET | Global search |
Error Codes
| Code | Status | Description |
|---|---|---|
| rest_forbidden | 401 | Auth required |
| invalid_request | 400 | Invalid params |
| not_found | 404 | Not found |
| rate_limit_exceeded | 429 | Rate limited [PRO] |
Pagination
Use page and per_page (max 100). Headers: X-WP-Total, X-WP-TotalPages.
CORS & Rate Limiting
CORS enabled for /wp-json/wpss/. Configure via wpss_api_cors_origins filter. [PRO] Rate limits: 300/hr authenticated, 1000/hr app passwords, unlimited admins.
