Domain name for API request: teo.intl.tencentcloudapi.com.
This API is used to list all keys in the specified namespace, with prefix filtering supported. Cursor-based traversal is implemented, and the next cursor is returned for continued querying. It is suitable for traversing all keys in a namespace.
A maximum of 20 requests can be initiated per second for this API.
The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.
| Parameter Name | Required | Type | Description |
|---|---|---|---|
| Action | Yes | String | Common Params. The value used for this API: EdgeKVList. |
| Version | Yes | String | Common Params. The value used for this API: 2022-09-01. |
| Region | No | String | Common Params. This parameter is not required. |
| ZoneId | Yes | String | Zone ID. |
| Namespace | Yes | String | Namespace name. |
| Prefix | No | String | Filter by key name prefix. Only return key names beginning with the specified prefix. Length: 1–512 characters. If not specified, all key names are returned. Empty string is not allowed. |
| Cursor | No | String | Cursor position. Identifies the starting position of the current query, used for traversing large amounts of data. Do not fill in for the initial query to start from the beginning. For subsequent queries, fill in the Cursor value returned last time to continue traversing backward from that position. |
| Limit | No | Integer | Number of returned key names. Default value: 20. Maximum value: 1000. |
| Parameter Name | Type | Description |
|---|---|---|
| Keys | Array of String | Key name list. |
| Cursor | String | Cursor position. Indicates the current traversal position and is used to obtain the next batch of data. Fill in this value in the Cursor parameter of the next request to continue backward traversal. If it is an empty string, all data has been traversed. |
| RequestId | String | The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. |
List the key list prefixed with "he" in the namespace of ns-011 on the site zone-3j1xw7910arp, returning 1 entry each time.
POST / HTTP/1.1
Host: teo.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: EdgeKVList
<Common request parameters>
{
"ZoneId": "zone-3j1xw7910arp",
"Namespace": "ns-011",
"Prefix": "he",
"Limit": 1
}
{
"Response": {
"Cursor": "hello",
"Keys": [
"hello"
],
"RequestId": "3be98a20-737d-488d-aeb3-85ebc95288fc"
}
}
Use the Cursor value hello returned from the last query to list the next page of key list prefixed with he in the namespace ns-011 of the site zone-3j1xw7910arp.
POST / HTTP/1.1
Host: teo.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: EdgeKVList
<Common request parameters>
{
"ZoneId": "zone-3j1xw7910arp",
"Namespace": "ns-011",
"Prefix": "he",
"Cursor": "hello",
"Limit": 1
}
{
"Response": {
"Cursor": "",
"Keys": [
"hello1"
],
"RequestId": "bc3370e5-a969-4760-ada8-e9071084f047"
}
}
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.
The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.
| Error Code | Description |
|---|---|
| FailedOperation | Operation failed. |
| InvalidParameterValue | Parameter value error. |
| ResourceUnavailable.NamespaceNotFound | KV namespace does not exist. |
フィードバック