Updated on 2023-10-23 GMT+08:00

Viewing Parameter Change History

Function

This API is used to view the parameter change history. Before calling this API:

URI

GET /v3/{project_id}/configurations/{configuration_id}/modify-history

Table 1 URI parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Project ID of a tenant in a region.

To obtain this value, see Obtaining a Project ID.

configuration_id

Yes

String

Parameter template ID.

To obtain this value, see Querying Details of a DB Instance.

After the request is processed, the value of configuration_id in the response body is the value of configuration_id.

Table 2 Query parameters

Parameter

Mandatory

Type

Description

offset

No

Integer

Index offset. If offset is set to N, the resource query starts from the N+1 piece of data. The value is 0 by default, indicating that the query starts from the first piece of data. The value cannot be a negative number.

limit

No

Integer

Number of records to be queried. The default value is 100. The value must be a positive integer. The minimum value is 1 and the maximum value is 100.

Request Parameters

Table 3 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

User token.

If the following response body is returned for calling the API used to obtain a user token, the request is successful.

After the request is processed, the value of X-Subject-Token in the message header is the token value.

X-Language

No

String

Request language type. The default value is en-us.

Value:

  • en-us
  • zh-cn

Response Parameters

Status code: 200

Table 4 Response body parameters

Parameter

Type

Description

total_count

Integer

Total number of records.

histories

Array of ParamGroupHistoryResponse objects

Change history of the parameter template.

Table 5 ParamGroupHistoryResponse

Parameter

Type

Description

parameter_name

String

Parameter name.

old_value

String

Old parameter value.

new_value

String

New parameter value.

update_result

String

Update result.

is_applied

Boolean

Whether the changed template is applied.

  • true: applied.
  • false: not applied

updated

String

Time when the template was modified. The format is yyyy-mm-ddThh:mm:ssZ. T is the separator between the calendar and the hourly notation of time. Z indicates the time zone offset. For example, if the time zone offset is one hour, the value of Z is +0100.

applied

String

Time when the template was applied. The format is yyyy-mm-ddThh:mm:ssZ. T is the separator between the calendar and the hourly notation of time. Z indicates the time zone offset. For example, if the time zone offset is one hour, the value of Z is +0100.

Status code: 400

Table 6 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error message.

Status code: 500

Table 7 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error message.

Example Request

Querying change history of a parameter template

GET https://{endpoint}/v3/0483b6b16e954cb88930a360d2c4e663/configurations/7625c6a12d884be1891c61d921e0e114pr07/modify-history

Example Response

Status code: 200

Success.

{
  "total_count" : 2,
  "histories" : [ {
    "parameter_name" : "binlog_rows_query_log_events",
    "old_value" : false,
    "new_value" : true,
    "update_result" : "SUCCESS",
    "is_applied" : true,
    "updated" : "2023-07-10T02:14:28+0000",
    "applied" : "2023-07-10T02:14:28+0000"
  }, {
    "parameter_name" : "block_encryption_mode",
    "old_value" : "aes-256-cbc",
    "new_value" : "aes-128-cfb1",
    "update_result" : "SUCCESS",
    "is_applied" : true,
    "updated" : "2023-07-10T02:14:28+0000",
    "applied" : "2023-07-10T02:14:28+0000"
  } ]
}

Status Code

For details, see Status Codes.

Error Code

For details, see Error Codes.