Updated on 2025-07-22 GMT+08:00
        
          
          
        
      
      
      
      
      
      
      
      
      
      
      
        
Obtaining the Domain-Level Token
The following example shows how to obtain the domain-level token.
POST https://iam.eu-west-101.myhuaweicloud.com/v3/auth/tokens
Content-Type: application/json
{
    "auth": {
        "identity": {
            "methods": [
                "password"
            ],
            "password": {
                "user": {
                    "name": "username",
                    "password": "********",
                    "domain": {
                        "name": "domainname"
                    }
                }
            }
        },
        "scope": {
            "domain": {
                "id": "xxxxxxxxxxxxxxxxxx"
            }
        }
    }
}
 
 
  - The validity period of a token is 24 hours. Cache the token to prevent frequent API calling.
 - To avoid token expiration during an API call, ensure that the time taken to complete a call is shorter than the time left before a token expires.
 
   Parent topic: Appendix
  
 Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.
                The system is busy. Please try again later.