Skip to main content

Query Operation Logs

Use this API to query NineData operation audit logs with pagination. Filter by account, time range, module, event type, and object ID.

Request URL: /openapi/v1/actionTrail/list

Request Method: GET

Request Parameters

ParameterTypeRequiredDescriptionExample
accountIdStringNoAccount ID. Call the List Account Information API to get accountId.170**********159
startTimeDateTimeNoOperation time range - start time.2025-07-31T09:12:30Z
endTimeDateTimeNoOperation time range - end time.2025-07-31T10:12:30Z
moduleStringNoBelongs to module. Optional values:
  • sqlExport: Export result set.
  • sqlWriteSensitive: Sensitive data management.
  • dataExport: Data export.
  • dataImport: Data import.
  • ruleSet: SQL specification.
  • rule: SQL rule.
  • sqlReview: SQL review.
  • dataArchive: Data archiving and cleanup.
  • dataTrack: Data tracking and rollback.
  • slowLog: Slow query analysis.
  • dataGenerate: Data generation.
  • databaseVersion: Database version.
  • backupTask: Data backup.
  • restore: Data restoration.
  • replicationTask: Data replication.
  • compareData: Data comparison.
  • compareSchema: Structure comparison.
  • datasourceOperate: Data source.
  • gateway: Gateway.
  • accesscredential: Cloud access credentials.
  • privatelink: Private network connection.
  • approval: Approval process.
  • user: User management.
  • role: Role management.
  • organization: Organization management.
  • permissionApply: Permission application.
  • reportManage: Report download.
  • gitProject: Git configuration.
sqlExport
typeStringNoEvent type. Optional values:
  • create: Create.
  • modify: Modify.
  • delete: Delete.
  • execute: Execute.
  • revert: Revert.
  • cancel: Cancel.
  • export: Export.
  • transfer: Transfer.
  • login: Login.
  • download: Download.
  • enable: Enable.
  • disable: Disable.
  • debug: Debug.
create
objectIdStringNoEvent object ID.abc123456
currentIntegerNoCurrent page number, starting from 1, default is 1.1
pageSizeIntegerNoPage size, default is 10.10

Response Parameters

ParameterTypeDescriptionExample
dataArrayOperation log list. Each record includes these fields:
  • eventTime: Operation time.
  • accountId: Account ID.
  • accountName: Account name.
  • module: Belongs to module. See the module field in the request parameter table.
  • type: Event type. See the type field in the request parameter table.
  • objectId: Event object ID.
  • detail: Event details.
{
"eventTime": "2025-08-04 08:29:57Z",
"accountId": "1030799091781335",
"accountName": "NineData",
"module": "user",
"type": "login",
"objectId": "1030799091781335",
"detail": "{\"ip\":\"0:0:0:0:0:0:0:1\",\"loginMethod\":\"password\"}"
}
currentIntegerCurrent page number.1
pageSizeIntegerPage size.10
totalIntegerTotal number of records.1

Successful Invocation Example

{
"success": true,
"requestId": "Ji0q6MDE-HNLKqVKnIPMm6KWdLIb7STY",
"data": [{
"eventTime": "2025-08-04 08:29:57Z",
"accountId": "1030799091781335",
"accountName": "NineData",
"module": "user",
"type": "login",
"objectId": "1030799091781335",
"detail": "{\"ip\":\"0:0:0:0:0:0:0:1\",\"loginMethod\":\"password\"}"
}],
"current": 1,
"pageSize": 10,
"total": 1
}

Result

A successful response returns operation events that match the filters. Use the requestId for troubleshooting and the detail field to inspect event-specific metadata.