Maintenance Admin API

Clear the code cache after an upgrade

POST /api/v1/upgrade/code-cache/clear

Once a run is done, clears the code cache of the PHP that serves the web requests: the upgrade's own processes cannot. none when there is no cache to clear; failed with PHP's reason, after which PHP must be restarted on the server.

Responses
200 What happened to the cache.
401 The token is missing or wrong (Unauthenticated.), or its user may not act on this object (Unauthorized). Without the Accept: application/json header, a missing or wrong token answers with a redirect to the sign-in page instead.
403 The token's admin may not manage upgrades.
Clear the code cache after an upgrade
1 2 3
curl -X POST 'https://your-domain/api/v1/upgrade/code-cache/clear' \
  -H "Accept: application/json" \
  -H "Authorization: Bearer YOUR_API_TOKEN"
Response
{
    "status": "cleared",
    "reason": null
}