Queries the types of entries in the audit log collected for an ApsaraDB for MongoDB instance.

  • The instance must be in the running state when you call this operation.
  • This operation is applicable only to general-purpose local-disk and dedicated local-disk instances.
  • You can call this operation up to 30 times per minute. To call this operation at a higher frequency, use a Logstore. For more information, see Manage a Logstore.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes DescribeAuditLogFilter

The operation that you want to perform. Set the value to DescribeAuditLogFilter.

RegionId String No cn-hangzhou

The region ID of the instance. You can call the DescribeRegions operation to query the most recent region list.

DBInstanceId String Yes dds-bp12c5b040dc****

The ID of the instance.

RoleType String No primary

The role of the node in the instance. Valid values:

  • primary
  • secondary

Response parameters

Parameter Type Example Description
RequestId String 7BAFB0B3-2A54-5B65-B13E-3937CF08FEE6

The ID of the request.

Filter String admin,slow,insert,query,update,delete,command

The type of the audit log entries. Valid values:

  • admin: O&M and management operations
  • slow: slow query logs
  • query: query operations
  • insert: insert operations
  • update: update operations
  • delete: delete operations
  • command: protocol commands such as the aggregate method
RoleType String primary

The role of the node.

Examples

Sample requests

http(s)://mongodb.aliyuncs.com/?Action=DescribeAuditLogFilter
&DBInstanceId=dds-bp12c5b040dc****
&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<DescribeAuditLogFilterResponse>
    <RequestId>7BAFB0B3-2A54-5B65-B13E-3937CF08FEE6</RequestId>
    <Filter>admin</Filter>
</DescribeAuditLogFilterResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "7BAFB0B3-2A54-5B65-B13E-3937CF08FEE6",
  "Filter" : "admin"
}

Error codes

For a list of error codes, visit the API Error Center.