hosting

DELETE /v1/sites/{siteId}/wordpress/debug-log

Empty the site's WordPress debug log.

All hosting endpoints

All developer docs →

Zinn®, our Viking, hammering at his anvil beside an API endpoint sending events to several listeners.

Authentication

Send an API key as a bearer token. The key must carry the sites.view permission; a key without it is refused with 403, not 404.

This endpoint takes no organisation id. Your key already identifies the organisation it belongs to, and the response is scoped to it.

Try it

Replace anything in angle brackets with your own values, and the key placeholder with a key from your dashboard.

curl -X DELETE https://api.zinndigital.com/v1/sites/{siteId}/wordpress/debug-log \
  -H "Authorization: Bearer zdk_live_…"

Signed in? The API console in your dashboard fills in your real organisation id and your own key, and runs the request against the live API so you can see the actual response. Open this endpoint in the API console

Details

Empties the debug log in place (the file stays, with its owner and permissions), then re-reads it and returns the log as re-read; audit-logged as wordpress.debug_log.cleared. Refused when WP_DEBUG_LOG names a file that does not end in .log, so a typo in wp-config.php can never erase a real file. Requires sites.view and sites.panel_access. Fleet only.

Parameters

NameTypeRequiredWhat it is
siteId (path)UuidYesSite ID (UUIDv7).

Response

NameTypeRequiredWhat it is
supportedbooleanYesFalse where this platform cannot read the site's debug log.
existsbooleanNoFalse when WordPress has not written a log file yet.
size_bytesintegerNoThe whole log file's size.
custom_pathbooleanNoTrue when WP_DEBUG_LOG names a path other than wp-content/debug.log.
linesstring[]NoThe last lines of the log, oldest first.
truncatedbooleanNoTrue when the log holds older lines than lines shows.

Errors this endpoint can return

401 · 403 · 404 · 422 · 429 · 503