UpdateApiKey

Updated at:

Updates an API key.

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 /pop/2026-05-09/api-keys/{apiKeyID} HTTP/1.1

Path Parameters

Parameter

Type

Required

Description

Example

apiKeyID

string

No

The unique identifier of the API key.

34f6a4c4-499f-4bbd-baa0-0e699f53abcd

Request parameters

Parameter

Type

Required

Description

Example

body UpdateApiKeyInput

No

The request body parameters.

Response elements

Element

Type

Description

Example

object

message

string

The response message.

success

code

string

The response status code.

200

requestId

string

Id of the request

2BCFAE0A-9FA9-5F72-8E8B-724632BC19A9

apiKey ApiKey

The API key.

asdfjoY87-9IUHH

ipWhitelist

array

The list of IP addresses that are allowed to use the API key.

IPConfig

The configuration of a single IP address that is allowed access.

ipBlacklist

array

The list of IP addresses that are prohibited from using the API key.

IPConfig

The configuration of a single IP address that is denied access.

Examples

Success response

JSON format

{
  "message": "success",
  "code": "200",
  "requestId": "2BCFAE0A-9FA9-5F72-8E8B-724632BC19A9",
  "apiKey": {
    "apiKeyID": "34f6a4c4-499f-4bbd-baa0-0e699f53abcd",
    "apiKeyValue": "e2b_xxxxxx79cd777ef8exxxxxx4ad6f1b567cxxxxxx",
    "apiKeyMask": "e2b_xxxx****xxxx",
    "apiKeyName": "dev",
    "userID": "12345",
    "username": "user1",
    "createdTime": "2023-09-13T08:27:20Z",
    "expireTime": "2023-10-13T08:27:20Z",
    "lastUsedTime": "2023-09-14T08:27:20Z",
    "teamID": "70d1c834-0383-58d8-97ac-5336eb91abcd",
    "teamName": "Development team",
    "resourceGroupID": "rg-acfmwxqyrgwabcd",
    "status": "active",
    "teamPlan": "Pro",
    "source": "",
    "ipWhitelist": [
      {
        "ipAddress": "203.0.113.10",
        "description": "Fixed application egress"
      }
    ],
    "ipBlacklist": [
      {
        "ipAddress": "203.0.113.10",
        "description": "Fixed application egress"
      }
    ]
  },
  "ipWhitelist": [
    {
      "ipAddress": "203.0.113.10",
      "description": "Fixed application egress"
    }
  ],
  "ipBlacklist": []
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.