Call GetSecureToken to obtain the SecureToken information of the given namespace. It is mainly used to obtain the AccessKey, SecretKey, TenantId, address server domain name, and other information of the given command space.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request header

This operation only uses common request headers. For more information, see the Common request parameters topic.

Request syntax

GET /pop/v5/secure_token HTTPS|HTTP

Request parameters

Element Type Required Example Description
NamespaceId String No cn-shenzhen:x*****

The ID of the namespace. For example, cn-beijing or cn-beijing:prod.

Response parameters

Element Type Sample response Description
Code Integer 200

The status code returned by the API request.

Message String Success

The information returned by the API request.

RequestId String D16979DC-4D42-*************** *

The request ID.

SecureToken Struct

The SecureToken object returned from the API request.

AccessKey String f676f1:****

The AccessKey of the namespace.

AddressServerHost String addr-****-****.edas.aliyun.com

The address server address corresponding to the namespace.

BelongRegion String cn-shenzhen

The ID of the region to which the NAT gateway belongs.

Description String ""

The description of the namespace.

EdasId String 11727458****

The ID of the user.

Id Long 7279

The ID of the SecureToken object.

RegionId Boolean cn-shenzhen:x*******

The ID of the region where the namespace resides.

RegionName String x******

The ID of the region to which the namespace belongs.

SecretKey String gOSgbg****

The SecretKey(SK) of the namespace.

TenantId String 401b7bc8-9441-4693****

The tenant ID(tid) of the namespace.

UserId String edas_com***_****@******-*****. ***

The UserId of the user.

Examples

Sample requests

GET /pop/v5/secure_token HTTP/1.1
Common request header
{
  "NamespaceId": ""
}

Sample success responses

XML format

<SecureToken>
    <TenantId>401b7bc8-9441-4693-****-************</TenantId>
    <RegionName>x******</RegionName>
    <BelongRegion>cn-shenzhen</BelongRegion>
    <AccessKey>f676f1**************</AccessKey>
    <AddressServerHost>addr-****.edas.aliyun.com</AddressServerHost>
    <RegionId>cn-shenzhen:x*******</RegionId>
    <SecretKey>gOSgbgR2R*************</SecretKey>
    <Id>7279</Id>
    <UserId>edas_com***_****@******-*****. ***</UserId>
    <EdasId>11727458********</EdasId>
</SecureToken>
<Message>success</Message>
<Code>200</Code>

JSON format

{
    "SecureToken": {
    "TenantId": "401b7bc8-9441-4693-****-************",
    "RegionName": "x******",
    "BelongRegion": "cn-shenzhen",
    "AccessKey": "f676f1**************",
    "AddressServerHost": "addr-****.edas.aliyun.com",
    "RegionId": "cn-shenzhen:x*******",
    "SecretKey": "gOSgbgR2R*************",
    "Id": 7279,
    "UserId": "edas_com***_****@******-*****. ***",
    "EdasId": "11727458********"
},
    "Message": "success",
    "Code": 200
}

Error codes.

For a list of error codes, visit the API Error Center.