API Reference
WordPress API
Copy page
List, inspect, install, update, plugins, login links, error logs, users, staging, address changes and wp-cron for the WordPress sites on your own hosting
All endpoints live on https://api.hostino.ai and use an OAuth (Bearer) token. Ownership comes only from the token: a service or site that isn’t the token owner’s answers like a missing one (404). The MCP equivalents are in WordPress with AI.
| Endpoint | Scope | What it does |
|---|---|---|
GET /v1/wordpress/sites | wordpress:read | WordPress sites on your hosting |
GET /v1/wordpress/site?service_id=&site= | wordpress:read | One site’s details |
POST /v1/wordpress/login-link | hosting:login | One-time wp-admin login link |
POST /v1/wordpress/update | wordpress:write | Update core, plugins or theme |
POST /v1/wordpress/plugins | wordpress:write | Install and activate a plugin |
POST /v1/wordpress/install | wordpress:write | Install a fresh WordPress (asynchronous, 202) |
GET /v1/wordpress/install-status?service_id=&install_id= | wordpress:read | Installation progress |
GET /v1/wordpress/plugins · themes · settings · admins · maintenance · security-scan (?service_id=&site=) | wordpress:read | Plugins, themes, settings, administrators, maintenance state, checksum scan |
POST /v1/wordpress/plugin-state | wordpress:write | slug + state (active, inactive, deleted) |
POST /v1/wordpress/themes | wordpress:write | slug, install (default true), activate |
POST /v1/wordpress/settings | wordpress:write | Any of title, tagline, search_engines (allowed/discouraged), timezone, permalinks (post_name, day_and_name, month_and_name, category, numeric) |
POST /v1/wordpress/maintenance | wordpress:write | enabled: true (on) / false (off) |
POST /v1/wordpress/cache/flush | wordpress:write | Flush object, transient and page caches |
POST /v1/wordpress/optimize · GET /v1/wordpress/optimizations | wordpress:write / wordpress:read | Start the optimizer (types: ALL, PHP, DATABASE, JS, CSS, IMAGES); recent jobs |
GET /v1/wordpress/backup · POST /v1/wordpress/backup · POST /v1/wordpress/backup/restore | wordpress:read / wordpress:write | Latest backup, new backup, restore the latest backup |
GET /v1/wordpress/jobs/:id?kind=optimize|backup | wordpress:read | Progress of an optimize or backup job |
GET /v1/wordpress/debug-log?service_id=&site=&lines= | wordpress:read | Latest lines of debug.log and the PHP error_log (1–300) and the debug state |
POST /v1/wordpress/debug | wordpress:write | enabled: true/false — log errors to debug.log (never shown to visitors) |
GET /v1/wordpress/users?service_id=&site= | wordpress:read | Users with roles |
POST /v1/wordpress/users | wordpress:write | action: create (user, user_email, role; administrators need confirm_role: "administrator"), reset_password (optional send_email) or delete (confirm = login, reassign) |
POST /v1/wordpress/search-replace | wordpress:write | from, to; dry run by default (dry_run: true); apply with dry_run: false and confirm_from = from |
GET /v1/wordpress/directory?service_id=&type=&query= | wordpress:read | Search wordpress.org plugins (plugin) or themes (theme) |
GET /v1/wordpress/cron · POST /v1/wordpress/cron | wordpress:read / wordpress:write | wp-cron mode; mode: server (hosting cron every 15 minutes) or wordpress |
GET /v1/wordpress/staging?service_id=&job_id= | wordpress:read | Sites including staging copies, or a job’s status |
POST /v1/wordpress/staging | wordpress:write | action: create (site), push (staging_site, confirm = the live site URL; a restore point is created first) or delete (staging_site, confirm = the staging URL) |
site is the site URL as returned by /v1/wordpress/sites (e.g. https://blog.example.com). If empty, the account’s main site is used.
Website tools for your own domains and services: GET /v1/sites/seo-check?url= (SEO check), POST /v1/sites/audit ({"url","device"}, Lighthouse) and GET /v1/services/:id/health (hosting health), all with scope services:read. See SEO and site health with AI.
List sites
curl -s https://api.hostino.ai/v1/wordpress/sites -H "Authorization: Bearer $TOKEN"{ "services": [ { "service_id": "150", "product": "WP-Plus-IR", "domain": "example.com", "sites": [ { "site": "https://example.com", "name": "My shop", "path": "", "version": "7.1.3", "latest_version": "7.1.3", "outdated": false, "healthy": true, "main_site": true, "login_page": "https://example.com/wp-login.php" } ] } ]}Update
curl -s -X POST https://api.hostino.ai/v1/wordpress/update -H "Authorization: Bearer $TOKEN" -H "Content-Type: application/json" \ -d '{"service_id":"150","target":"plugins","plugins":["contact-form-7","elementor"]}'target:core,pluginsortheme.plugins: plugin slugs; omit to update all plugins.- Every operation works on any WordPress site of the account (main, folder or subdomain).
Install a fresh WordPress
curl -s -X POST https://api.hostino.ai/v1/wordpress/install -H "Authorization: Bearer $TOKEN" -H "Content-Type: application/json" \ -d '{"service_id":"392","domain":"example.com","site_title":"My site","language":"en_US"}'The response is 202 with an install_id. Follow install-status until done. The admin password is random and not returned; sign in with login-link.
Dry run of an address change
curl -s -X POST https://api.hostino.ai/v1/wordpress/search-replace -H "Authorization: Bearer $TOKEN" -H "Content-Type: application/json" \ -d '{"service_id":"150","from":"http://example.com","to":"https://example.com"}'Without dry_run: false nothing changes; the answer only shows the number of replacements. Back up the site before applying (POST /v1/wordpress/backup). A staging copy is created at staging.<domain> with the same path; the full flow is in WordPress with AI.
Errors
site_not_found, invalid_plugin, domain_not_on_service, wordpress_already_installed, wordpress_operation_failed, service_not_found, service_not_active, and for the newer endpoints confirmation_required, confirmation_mismatch, last_administrator, user_not_found, invalid_reassign, staging_exists, staging_not_found, already_staging, hosting_tools_not_available. Each is explained in WordPress with AI.