Purge Oracle Cache
Drops everything cached for one price oracle, so a corrected source shows up now instead of after the cache window:
- every cached summary of the oracle (all codes), which is shared by every server process;
- the copy of the source document held by the server process that answered the request (only the
SHEETprovider keeps one).
The response says what was actually dropped: summary_entries: 0 with document_cleared: false means nothing was cached, not that the purge failed.
Required permission: oracle:update
Request
DELETE /v2/admin/oracles/{oracle_id}/cache
Parameters
| Name | Type | In | Description |
|---|---|---|---|
oracle_id | string | path | Required. Oracle id (24-character hex) |
Headers
| Name | Description |
|---|---|
Authorization | Required. Bearer <access_token> |
Example
curl --request DELETE \
--url '{{baseUrl}}/v2/admin/oracles/677ed6e3cc111aea14a3dfc3/cache' \
--header 'Authorization: Bearer <access_token>'
Response
{
"summary_entries": 2,
"document_cleared": false
}
Response Fields
| Field | Type | Description |
|---|---|---|
summary_entries | integer | Number of cached summaries removed |
document_cleared | boolean | Whether the answering process held a copy of the source document and dropped it. Other server processes keep theirs until their own cache window ends |
Errors
| Status | Code | Description |
|---|---|---|
| 400 | 10000 | oracle_id is not a valid 24-character hex id |
| 400 | 10001 | Oracle not found or deleted (domain 5) |
| 400 | 10003 | The summary cache could not be cleared (domain 5) |
See Errors for the error format and common codes.