Skip to content

Get RabbitPress Cache on a site

GET /v1/sites/{siteId}/rabbitpress

Returns whether RabbitPress Cache, Rabbitflare's WordPress cache plugin, is installed on the site and which version (version, and latestVersion, the newest), whether the web server sends the site's cached pages itself (serving, or why not in notServingReason), whether an install or removal is running (busy), and whether the site needs one of your licences (licenseRequired: sites on servers of your own do). It's read from the site's server each time, so it takes a second or two and counts as a heavy request; blockedReason says when it can't be installed or removed here.

Scopes

The token needs this scope. Without it, the request is refused with insufficient_scope (see Scopes).

sites:read
View sites. See sites and their domains, CDN, firewall, malware protection, backups, staging, resources, SMTP and Media Offload. SMTP includes who each site's recent emails went to, their subjects, and the team's sign-in addresses.

Path parameters

FieldType and description
siteId Required

string

The site's id.

Example request

curl "https://api.rabbitflare.com/v1/sites/8a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d/rabbitpress" \
  -H "Authorization: Bearer $RABBITFLARE_TOKEN"

Response

200 OK Returns the SiteRabbitPress object in data.

The SiteRabbitPress object's fields 10 fields
FieldType and description
installed

boolean

Whether the plugin is installed on the site, as the site's server reports it. False too while the server is off or doesn't answer.

version

string or null

The installed version. Null when the plugin isn't installed (or the server didn't say).

latestVersion

string or null

The newest version Rabbitflare installs: installing again on a site with an older version updates it. Null when none can be installed right now.

serving

boolean

Whether the web server sends the site's cached pages itself, without PHP: the fastest way.

notServingReason

string or null

Why the web server doesn't send the site's cached pages itself (PHP serves them instead, or the plugin isn't caching yet). Null while it does, or when the server didn't say.

busy

boolean

An install, update or removal is running: usually done within a minute or two.

licenseRequired

boolean

Whether the site needs one of your RabbitPress Cache licences: sites on servers of your own do. On servers Rabbitflare creates it's included, without a licence.

licenseId

string or null

The licence the site uses, on a server of your own. Null on servers Rabbitflare creates, or before a licence was chosen for the site.

lastError

string or null

Why the last install, update or removal didn't finish. Null when it did.

blockedReason

string or null

Why RabbitPress Cache can't be installed, updated or removed on this site right now: a staging copy, a site still installing, or a server that isn't running. Null when it can.

Example response

200 OK
{
  "data": {
    "installed": true,
    "version": "2.0.10",
    "latestVersion": "2.0.10",
    "serving": true,
    "notServingReason": null,
    "busy": false,
    "licenseRequired": false,
    "licenseId": null,
    "lastError": null,
    "blockedReason": null
  }
}

Errors

The errors this request can answer besides those every request can (a missing token, a missing scope, the rate limits). Each answer is an Error object (see Errors).

Status and codeWhen, and what to do
403 feature_unavailable

This product isn't open to the account.

Contact support if you'd like it opened.

404 not_found

The resource doesn't exist, or isn't this account's.

Check the id. Ids of other accounts' resources answer the same way.

409 server_restoring

The server is being restored, and nothing else can change it or its sites until that's done.

Wait until the restore finishes (the server's pendingAction is null again), then try again. A restore that stopped partway keeps pendingAction: "restore", with the server's lastError set, until our team has checked the server.

429 rate_limited

Too many requests. scope says which limit: token, account, create, operation or network.

Wait for Retry-After seconds, then go on more slowly.

Rate limit

Heavy requests: 20 a minute per token, 40 per account. More in Rate limits.

Added on .

Popular

API docs