Skip to content
Niu DocsNiu 牛元文档
Dashboard控制台

Read immutable operator and session lifecycle events

Generated from the checked-in source. Do not edit this reference by hand.

GET /api/v1/operators/{operator}/events

Requires a scoped owner for the target operator or an installation bootstrap credential. Cursor UUIDs are accepted only when they belong to the requested target operator. Events include actor class/identity and target tenant metadata, never session tokens, token hashes or request bodies.

Operation: adminListOperatorAuditEvents.

Use the credential and permission scope described above. Each object below is an alternative; schemes within one object are required together.

JSON
[
{
"adminBearerAuth": []
}
]

Set NIU_ORIGIN to your installation origin (without /v1). Replace path, query and header placeholders with the required values. Query examples use curl 7.87 or newer to encode values with --url-query. Use the credential scope described above; a bearer token must have the authority required by this operation.

Shell
curl --fail-with-body -X GET "$NIU_ORIGIN/api/v1/operators/{operator}/events" \
-H "Authorization: Bearer $NIU_ADMIN_TOKEN"

Location: path. Required.

JSON
{
"type": "string",
"format": "uuid"
}

Location: query. Optional.

JSON
{
"type": "integer",
"minimum": 1,
"maximum": 100,
"default": 50
}

Location: query. Optional. UUID from next_cursor in the previous page for this same operator.

JSON
{
"type": "string",
"format": "uuid"
}

No request body is declared.

Events in stable descending created_at/id order and a nullable next_cursor.

Content type: application/json.

JSON
{
"type": "object",
"additionalProperties": false,
"required": [
"data",
"next_cursor"
],
"properties": {
"data": {
"type": "array",
"items": {
"type": "object",
"additionalProperties": false,
"required": [
"id",
"action",
"actor_kind",
"actor_operator_id",
"target_operator_id",
"target_session_id",
"organization_id",
"project_id",
"before_role",
"after_role",
"created_at"
],
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"action": {
"type": "string",
"enum": [
"operator_created",
"session_created",
"session_revoked",
"operator_revoked",
"password_changed",
"password_login_succeeded",
"role_changed"
]
},
"actor_kind": {
"type": "string",
"enum": [
"installation",
"operator"
]
},
"actor_operator_id": {
"type": [
"string",
"null"
],
"format": "uuid",
"description": "Null only for installation actors."
},
"target_operator_id": {
"type": "string",
"format": "uuid"
},
"target_session_id": {
"type": [
"string",
"null"
],
"format": "uuid",
"description": "Present for session creation",
"revocation and password login; role changes apply to the member and have no target session.": null
},
"organization_id": {
"type": "string",
"format": "uuid"
},
"project_id": {
"type": [
"string",
"null"
],
"format": "uuid"
},
"before_role": {
"type": [
"string",
"null"
],
"enum": [
"owner",
"admin",
"viewer",
null
],
"description": "Recorded original role for role_changed; null for other events."
},
"after_role": {
"type": [
"string",
"null"
],
"enum": [
"owner",
"admin",
"viewer",
null
],
"description": "Recorded new role for role_changed; null for other events."
},
"created_at": {
"type": "string",
"format": "date-time"
}
}
}
},
"next_cursor": {
"type": [
"string",
"null"
],
"format": "uuid"
}
}
}

Page limit is outside 1–100 or cursor is absent from this operator’s event stream.

Missing, invalid, expired or revoked credentials.

The authenticated operator is not an owner.

Target operator is absent or outside the caller’s scope.

Requires a scoped owner for the target operator or an installation bootstrap credential. Cursor UUIDs are accepted only when they belong to the requested target operator. Events include actor class/identity and target tenant metadata, never session tokens, token hashes or request bodies.