Use the MainWP Postman collection as the source of truth for request and response schemas.
What You’ll Learn
- How to authenticate with REST API keys
- Which endpoint category to use for each task
- How v2 and legacy v1 access fit together
Base URL
All v2 endpoints use:Set Up API Keys
Create a key in API Access
Go to MainWP Dashboard > API Access > API Keys > Add API Keys, set a name, assign permissions, and generate a key.
Permission Scope
| Permission | Methods | Purpose |
|---|---|---|
| Read | GET | Fetch data |
| Write | POST, PUT, PATCH | Create and update |
| Delete | DELETE | Remove resources |
Endpoint Categories
Sites
Site inventory, sync, plugins, themes, and site operations.
Clients
Client CRUD, client fields, and client-level site/cost endpoints.
Tags
Tag CRUD, plus related sites and clients.
Updates
Update listing, execution, and ignore management.
Costs
Cost tracker records, linked sites/clients, and batch operations.
Users
User listing, create/edit/delete, CSV import, and admin password updates.
Settings
General, advanced, monitoring, email, tools, and other settings domains.
Monitoring
Uptime monitor list, incidents, heartbeat, and monitor settings.
API Keys
REST API key list, create, edit, and delete endpoints.
Posts
Cross-site post listing and post CRUD actions.
Pages
Cross-site page listing and page CRUD actions.
Batch
Global
/batch orchestration across multiple controllers.Legacy v1 Compatibility
MainWP still supports legacy v1 endpoints (/wp-json/mainwp/v1/) for backward compatibility.
Build new integrations on v2 first. Use v1 only where an existing integration still requires it.
