tencent cloud

APIs

DescribeKeySandboxCredential

下载
聚焦模式
字号
最后更新时间: 2026-09-01 09:48:22

1. API Description

Domain name for API request: csip.intl.tencentcloudapi.com.

This API is used to query credential details and return credential metadata and masked credential data. The access type returns an Access array (original Key, masked Value), and the sts type returns an STS object (original System, masked SecretID and SecretKey).

A maximum of 20 requests can be initiated per second for this API.

We recommend you to use API Explorer
Try it
API Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation, and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters

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: DescribeKeySandboxCredential.
Version Yes String Common Params. The value used for this API: 2022-11-21.
Region No String Common Params. This parameter is not required.
CredentialId Yes String Credential ID
MemberId.N No Array of String Group Account Member ID

3. Output Parameters

Parameter Name Type Description
CredentialId String Credential ID
CredentialName String Credential name
CredentialType String Credential type
Enumeration values:
access: standard key
sts: STS temporary key
CredentialEffectScope CredentialEffectScope Scope of effective machines
Access Array of AccessCredentialOutput Normal key credential data (masked). Returned when CredentialType is access.
Supplemental description: Key is the original text, and Value is the masked value (first 3 and last 4 characters retained, middle replaced by ***).
STS STSCredentialOutput STS credential data (masked). Returned when CredentialType is sts.
Supplemental description: System is the original text. SecretID and SecretKey are masked values (first 3 and last 4 characters reserved, middle replaced with ***).
CreateTime String Creation time.
Parameter format: YYYY-MM-DDTHH:mm:ssZ (ISO8601 format)
UpdateTime String Update time
Parameter format: YYYY-MM-DDTHH:mm:ssZ (ISO8601 format)
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.

4. Example

Example1 Query the details of an access credential

Input Example

POST / HTTP/1.1
Host: csip.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeKeySandboxCredential
<Common request parameters>

{
    "CredentialId": "cred-abc12345"
}

Output Example

{
    "Response": {
        "CredentialId": "cred-abc12345",
        "CredentialName": "Tencent Cloud - Production Environment Key",
        "CredentialType": "access",
        "CredentialEffectScope": {
            "Exclude": 1,
            "Instances": []
        },
        "Access": [
            {
                "Key": "SecretId",
                "Value": "AKI***abcd"
            },
            {
                "Key": "SecretKey",
                "Value": "abc***wxyz"
            }
        ],
        "CreateTime": "2026-01-15T08:30:00Z",
        "UpdateTime": "2026-03-10T14:29:03Z",
        "RequestId": "c368eae2-8739-4cc2-b4f8-8f4284a93b41"
    }
}

Example2 Query the details of sts credentials

Input Example

POST / HTTP/1.1
Host: csip.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeKeySandboxCredential
<Common request parameters>

{
    "CredentialId": "cred-sts56789"
}

Output Example

{
    "Response": {
        "CredentialId": "cred-sts56789",
        "CredentialName": "STS temporary key - testing environment",
        "CredentialType": "sts",
        "CredentialEffectScope": {
            "Exclude": 1,
            "Instances": [
                "ins-abc12345",
                "ins-def67890"
            ]
        },
        "STS": {
            "System": "tencentCam",
            "SecretID": "AKI***efgh",
            "SecretKey": "abc***wxyz"
        },
        "CreateTime": "2026-02-20T10:00:00Z",
        "UpdateTime": "2026-03-09T10:15:00Z",
        "RequestId": "a1b2c3d4-5678-90ab-cdef-1234567890ab"
    }
}

5. Developer Resources

SDK

TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.

Command Line Interface

6. Error Code

There is no error code related to the API business logic. For other error codes, please see Common Error Codes.

帮助和支持

本页内容是否解决了您的问题?

填写满意度调查问卷,共创更好文档体验。

文档反馈