tencent cloud

APIs

DescribeKeySandboxCredential

Unduh
Mode fokus
Ukuran font
Terakhir diperbarui: 2026-06-18 18:03:48

1. API Description

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

Query credential details and return credential metadata and masked credential data. The access kind returns an Access array (original Key, masked Value), and the sts kind 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 value:
access: standard key
sts: STS temporary key
CredentialEffectScope CredentialEffectScope Effective machine scope
Access Array of AccessCredentialOutput Normal key credential data (masked). Returned when CredentialType is access.
Supplementary explanation: Key is the original text, and Value is the masked value (reserve the first 3 and last 4 digits, with *** as substitution in the middle).
Note: This field may return null, indicating that no valid values can be obtained.
STS STSCredentialOutput STS credential data (masked). Returned when CredentialType is sts.
Supplementary description: System is the original text, SecretID and SecretKey are masked values (reserve the first 3 and last 4 characters, with *** as substitution in the middle).
Note: This field may return null, indicating that no valid values can be obtained.
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 access type credential details

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-live 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 Querying sts type credential details

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.

Bantuan dan Dukungan

Apakah halaman ini membantu?

masukan