GetLogSyncToSLS

Updated at:
Copy as MD

Retrieves the log synchronization configuration.

Operation description

  • Central public endpoint: adb.aliyuncs.com.

  • Regional public endpoint: adb.<region-id>.aliyuncs.com. Example: adb.cn-hangzhou.aliyuncs.com.

  • Regional VPC endpoint: adb-vpc.<region-id>.aliyuncs.com. Example: adb-vpc.cn-hangzhou.aliyuncs.com.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request parameters

Parameter

Type

Required

Description

Example

DBClusterId

string

Yes

The cluster ID.

am-uf6g8w25jacm7****

RegionId

string

Yes

The region ID.

cn-hangzhou

LogType

string

No

The log type. Valid values:

  • ADBMYSQL_AUDIT_LOG

  • ADBMYSQL_INSERT_LOG

Default value: ADBMYSQL_AUDIT_LOG.

ADBMYSQL_AUDIT_LOG

Response elements

Element

Type

Description

Example

object

RequestId

string

The request ID.

1AD222E9-E606-4A42-BF6D-8A4442913CEF

Data

object

The returned data.

Status

string

The log synchronization status. Valid values:

  • on: Synchronization is enabled.

  • off: Synchronization is disabled.

off

TargetProject

string

The Simple Log Service project.

log-service-****-cn-shenzhen

TargetLogStore

string

The Simple Log Service Logstore.

adbmysql-audit-log

Examples

Success response

JSON format

{
  "RequestId": "1AD222E9-E606-4A42-BF6D-8A4442913CEF",
  "Data": {
    "Status": "off",
    "TargetProject": "log-service-****-cn-shenzhen",
    "TargetLogStore": "adbmysql-audit-log"
  }
}

Error codes

HTTP status code

Error code

Error message

Description

404 InvalidDBCluster.NotFound The DBClusterId provided does not exist in our records. The specified DBClusterId parameter does not exist. Make sure that the DBClusterId value is valid.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.