You can call this operation to query the Wi-Fi settings of a Smart Access Gateway (SAG) instance.

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 parameters

Parameter Type Required Example Description
Action String No DescribeSagWifi

The operation that you want to perform.

Set the value to DescribeSagWifi.

RegionId String Yes cn-shanghai

The ID of the region where the SAG instance is deployed.

SmartAGId String Yes sag-whfn****

The ID of the SAG instance.

SmartAGSn String Yes sag32a30****

The serial number (SN) of the SAG device.

Response parameters

Parameter Type Example Description
AuthenticationType String WPA2-PSK

The authentication type. Valid values:

  • NONE: authentication is disabled.
  • WPA-PSK: WPA-PSK authentication is enabled.
  • WPA2-PSK: WPA2-PSK authentication is enabled.
Bandwidth String Automatic

The bandwidth of the Wi-Fi channel. Valid values:

  • Automatic
  • 20 HMz
  • 40 MHz
Channel String 0

The Wi-Fi channel.

EncryptAlgorithm String AES

The encryption algorithm.

  • AUTO: automatically selects the encryption algorithm.
  • TKIP: uses the Temporal Key Integrity Protocol (TKIP).
  • AES: uses the Advanced Encryption Standard authorized by Wi-Fi®.
IsAuth String True

Indicates whether wireless security is enabled.

  • True: wireless security is enabled.
  • False: wireless security is disabled.
IsBroadcast String True

Indicates whether broadcast over Wi-Fi is enabled. Valid values:

  • True: broadcast is enabled.
  • False: broadcast is disabled.
IsEnable String True

Indicates whether wireless connections are enabled. Valid values:

  • True: wireless connections are enabled.
  • False: wireless connections are disabled.
RequestId String E93884AC-6C21-4FEA-8E3A-7377D33B194F

The ID of the request.

Ssid String aliyun_sag_123456***

The service set identifier (SSID) of the Wi-Fi network.

TaskStates Array

The information about the query task.

CreateTime String 1586843621000

The time when the query task was created.

ErrorCode String 200

The error code returned for a query task. The 200 error code indicates that the query task is successful.

ErrorMessage String Successful

The error message returned for a query task. The Successful error message indicates that the query task is successful.

State String Succeed

The status of the query task. Valid values:

  • Initialized: The query task has been initialized.
  • Offline: The query task is not dispatched because the SAG device is disconnected from Alibaba Cloud. The task will be dispatched after the SAG device is connected to Alibaba Cloud.
  • Succeed: The query task has been dispatched.
  • Processing: The query task is being dispatched.
  • VersionNotSupport: The current version of the SAG device does not support query tasks.
  • BuildRequestError: The SAG control system does not support query tasks.
  • HardwareError: The query task failed to be dispatched due to device errors.
  • TaskNotExist: The query task does not exist.
  • OfflineNotConfiged: The query task is not dispatched because the SAG device is disconnected from Alibaba Cloud. The task will not be dispatched after the device is connected to Alibaba Cloud.

Examples

Sample requests

http(s)://smartag.cn-shanghai.aliyuncs.com/? Action=DescribeSagWifi
&RegionId=cn-shanghai
&SmartAGId=sag-whfn****
&SmartAGSn=sag32a30****
&<Common request parameters>

Sample success responses

XML format

<DescribeSagWifiResponse>
  <IsEnable>False</IsEnable>
  <RequestId>C1ECD42E-B896-487B-8FCD-4A3364D00F21</RequestId>
  <TaskStates>
        <State>Succeed</State>
        <CreateTime>1586843621000</CreateTime>
        <ErrorCode>200</ErrorCode>
        <ErrorMessage>Successful</ErrorMessage>
  </TaskStates>
</DescribeSagWifiResponse>

JSON format

{
	"IsEnable": "False",
	"RequestId": "C1ECD42E-B896-487B-8FCD-4A3364D00F21",
    "TaskStates": [
	{
		"State": "Succeed",
		"CreateTime": 1586843621000,
		"ErrorCode": "200",
		"ErrorMessage": "Successful"
	}
]
}

Error codes

HttpCode Error code Error message Description
400 SAG.InstanceNoFound The specified SAG instance does not exist. The error message returned because the specified SAG instance does not exist.
400 SAG.SoftwareNotSupport The specified SAG software edition instance does not support ACL. The error message returned because the version of the specified SAG instance does not support ACLs.
500 SmartAccessGatewayInArrears The specified Smart Access Gateway has expired. The error message returned because the specified SAG instance has expired. Renew the SAG instance first.
500 SmartAccessGatewayNotActivated The specified Smart Access Gateway has not been activated. The error message returned because the specified SAG instance has not been activated. Activate the SAG instance first.
403 SmartAccessGatewayNotOnline The specified smart access gateway is not online. The error message returned because the specified SAG device is not connected to Alibaba Cloud.
500 SmartAccessGatewayOffline The request cannot be completed. The Smart Access Gateway is offline. The error message returned because the specified SAG device is disconnected form Alibaba Cloud.
400 InstanceNotExit The specified instance does not exist. The error message returned because the specified instance does not exist.
400 ConfigUnsynchronized The network configuration is not synchronized. The error message returned because the network settings are not synchronized between the SAG device and instance.
403 FeatureNotSupport The current edition of the smart access gateway does not support this feature. The error message returned because the current version of the specified SAG instance does not support this feature.
403 FeatureNotSupportForActiveSmartAG The current edition of the active smart access gateway does not support this feature. The error message returned because the current version of the active SAG device does not support this feature.
403 FeatureNotSupportForStandBySmartAG The current edition of the standby smart access gateway does not support this feature. The error message returned because the current version of the standby SAG device does not support this feature.

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