Skip to content

Purge Learnings

POST
/api/admin/memory/purge
curl --request POST \
--url https://example.com/api/admin/memory/purge \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "scope": { "level": "example", "team_id": "example", "components": [ "all" ] }, "dry_run": true }'

Purge learning pipeline data.

Requires superadmin auth. Supports dry_run for previewing deletions.

Media type application/json
PurgeRequest

Request body for POST /purge.

object
scope
required
PurgeScopeRequest

Scope definition for a purge request.

object
level
required
Level
string
team_id
Any of:
string
components
Components
Array<string>
default: all
dry_run
Dry Run
boolean
default: true

Successful Response

Media type application/json
PurgeReportResponse

Response from a purge operation.

object
dry_run
required
Dry Run
boolean
level
required
Level
string
team_id
Any of:
string
components
required
Components
Array<string>
items_by_component
required
Items By Component
object
key
additional properties
any
total_items
required
Total Items
integer
audit_id
required
Audit Id
string
timestamp
required
Timestamp
string
verification
Any of:
PurgeVerificationResponse

Post-purge infrastructure verification.

object
signal_write_ok
Signal Write Ok
boolean
signal_read_ok
Signal Read Ok
boolean
signal_cleanup_ok
Signal Cleanup Ok
boolean
error
Any of:
string
Example
{
"verification": {
"signal_write_ok": false,
"signal_read_ok": false,
"signal_cleanup_ok": false
}
}

Validation Error

Media type application/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationError
object
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
input
Input
ctx
Context
object
Example generated
{
"detail": [
{
"loc": [
"example"
],
"msg": "example",
"type": "example",
"input": "example",
"ctx": {}
}
]
}