Activate plugin
Activate a WordPress plugin on a site.
POST/api/servers/{server}/sites/{id}/wordpress/plugins/activate
Activate plugin
Activates the specified WordPress plugin. Requires WP-CLI to be installed on the server.
Required attributes
- Name
plugin- Type
- string
- Description
The plugin slug to activate (e.g.
wordpress-seo).
Query parameters
- Name
ondemand- Type
- boolean
- Description
When set to
true, the command runs synchronously and returns the result directly. When omitted orfalse(default), the action is queued and processed in the background.
Request
POST
/api/servers/{server}/sites/{id}/wordpress/plugins/activatecurl -X POST "https://ploi.io/api/servers/{server}/sites/{id}/wordpress/plugins/activate?ondemand=true" \
-H "Authorization: Bearer {token}" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d '{"plugin": "wordpress-seo"}'
Response
{
"status": "ok",
"message": "Plugin activated."
}