All Products
Search
Document Center

Smart Access Gateway:CreateSmartAccessGatewayClientUser

Last Updated:Mar 03, 2024

Creates a client account.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
smartag:CreateSmartAccessGatewayClientUserWrite
  • SmartAccessGateway
    acs:smartag:{#regionId}:{#accountId}:smartag/{#SmartAGId}
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
RegionIdstringYes

The region ID of the Smart Access Gateway (SAG) app instance.

cn-shanghai
SmartAGIdstringYes

The ID of the SAG app instance.

sag-gnhe6sywtare5****
UserNamestringNo

The username of the client account. The usernames of client accounts added to the same SAG app instance must be unique.

The username must be 7 to 33 characters in length, and can contain letters, digits, underscores (_), at signs (@), periods (.), and hyphens (-). It must start with a letter or a digit.

Note For a client account, if you specify the username, you must also specify the password. If you specify the password, you must specify the username.
doctest
ClientIpstringNo
  • If you enable the client app service, you must set the IP address of the client app. The current client account uses the specified IP address to connect to Alibaba Cloud.
Note The IP address must fall within a private CIDR block.
  • If you disable the client app service, an IP address within a private CIDR block is assigned to the client account. Each connection to Alibaba Cloud uses a different IP address.
10.0.XX.XX
UserMailstringYes

The email address of the client account. The username and password are sent to the specified email address by the administrator.

username@example.com
BandwidthlongYes

The maximum bandwidth value. Unit: Kbit/s. Valid values: 1 to 20000. Default value: 2000.

20
PasswordstringNo

The password that is used to log on to the SAG app.

The password must be 8 to 32 characters in length. It can contain letters, digits, underscores (_), at signs (@), and hyphens (-). It must start with a letter or a digit.

duuf****

Response parameters

ParameterTypeDescriptionExample
object
UserNamestring

The username.

doc
RequestIdstring

The ID of the request.

72E82F5E-66E8-4C22-BF1F-5CEB7DC132E7
UserMailstring

The email address of the client account.

username@example.com
Bandwidthinteger

The maximum bandwidth value. Unit: Kbit/s.

20
ClientIpstring

The IP address of the client app.

10.0.XX.XX

Examples

Sample success responses

JSONformat

{
  "UserName": "doc",
  "RequestId": "72E82F5E-66E8-4C22-BF1F-5CEB7DC132E7",
  "UserMail": "username@example.com",
  "Bandwidth": 20,
  "ClientIp": "10.0.XX.XX"
}

Error codes

HTTP status codeError codeError messageDescription
400ClientUser.BandwidthInvalidThe specified Bandwidth is invalid.The specified bandwidth is invalid.
400ClientUser.EmailEmptyYou must specify UserEmail.You must specify the email address.
400ClientUser.EmailInvalidThe format of the specified UserEmail is invalid.The format of the email address is invalid.
400ClientUser.InvalidClientIpThe specified ClientIp is invalid.The specified ClientIp is invalid.
400ClientUser.IpEmptyYou must specify ClientIp.You must specify the static IP address.
400ClientUser.IpInvalidThe specified ClientIp is invalid.The specified static IP address is invalid.
400ClientUser.NameEmptyYou must specify UserName.You must enter a username.
400ClientUser.NameInvalidThe specified UserName is invalid.The format of the username is invalid.
400ClientUser.UserExistThe specified user already exists.The specified user already exists.
400ClientUser.UserOverLimitThe maximum number of users is exceeded.The maximum number of users is exceeded.
400SAG.CidrEmptyYou must specify the CIDR blocks of SAG.You must specify the CIDR blocks of SAG.
400ClientUser.PasswordInvalidThe specified password format is invalid.The specified password format is invalid.

For a list of error codes, visit the Service error codes.