All Products
Search
Document Center

Simple Log Service:UpdateApiKey

Last Updated:Sep 04, 2026

Updates the resource whitelist and description of a specified API key.

Operation description

Operation description

  • The apiKeyName parameter cannot be modified.

  • The allowedStores parameter cannot be empty.

  • The update takes effect immediately.

  • You can update the resources of an API key even if the API key is in the Disabled state.

  • This operation is not used to rotate the API key plaintext.

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 syntax

PUT /apikeys/{apiKeyName} HTTP/1.1

Path Parameters

Parameter

Type

Required

Description

Example

apiKeyName

string

Yes

The API key name.

demo-apikey-001

Request parameters

Parameter

Type

Required

Description

Example

body

object

No

The request struct.

description

string

No

The description.

test

allowedStores

array

No

The list of Logstores to which data can be written.

string

No

The list of Logstores.

test

project

string

No

The project name.

test

Response elements

Element

Type

Description

Example

None defined.

Examples

Success response

JSON format

{}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.