
# 查询源端服务器列表 - ListServers
#### 功能介绍
用户在源端安装并成功启动Agent后，Agent会将源端服务器信息注册在主机迁移服务中，调用该接口查询已注册的源端服务器列表信息。
#### 调用方法
请参见[如何调用API](https://support.huaweicloud.com/api-sms/sms_api_0007.html)。
#### 授权信息
账号具备所有API的调用权限，如果使用账号下的IAM用户调用当前API，该IAM用户需具备调用API所需的权限。
- 如果使用角色与策略授权，具体权限要求请参见[权限和授权项](https://support.huaweicloud.com/api-sms/sms_api_8001.html)。
- 如果使用身份策略授权，需具备如下身份策略权限。
  
  | 授权项             | 访问级别 | 资源类型（\*为必须） | 条件键                   | 别名                     | 依赖的授权项 |
  |:---|:---|:---|:---|:---|:---|
  | sms:server:list | List | server \*   | -                     | sms:server:queryServer | -      |
  | sms:server:list | List | -           | g:EnterpriseProjectId | sms:server:queryServer | -      |
     
  
 
#### URI
GET /v3/sources
表1Query参数 
| 参数                          | 是否必选 | 参数类型    | 描述                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
|:---|:---|:---|:---|
| state                       | 否    | String  | 源端服务器状态 unavailable：环境校验不通过 waiting：等待 initialize：初始化 replicate：复制 syncing：持续同步 stopping：暂停中 stopped：已暂停 skipping：跳过中 deleting：删除中 clearing: 清理快照资源中 cleared：清理快照资源完成 clearfailed：清理快照资源失败 premigready：迁移演练就绪 premiged：迁移演练完成 premigfailed：迁移演练失败 cloning：等待克隆完成 cutovering：启动目的端中 finished：启动目的端完成 error：错误 枚举值： - **unavailable**   - **waiting**   - **initialize**   - **replicate**   - **syncing**   - **stopping**   - **stopped**   - **skipping**   - **deleting**   - **clearing**   - **cleared**   - **clearfailed**   - **premigready**   - **premiged**   - **premigfailed**   - **cloning**   - **cutovering**   - **finished**   - **error**    |
| name                        | 否    | String  | 源端服务器名称 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| id                          | 否    | String  | 源端服务器ID 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| ip                          | 否    | String  | 源端服务器IP地址 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| ipv6                        | 否    | String  | 源端服务器IPV6地址，优先使用IP进行查询 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| migproject                  | 否    | String  | 迁移项目ID，填写该参数将查询迁移项目下的所有虚拟机 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| limit                       | 否    | Integer | 每一页记录的源端服务器数量，0表示用默认值 200 最小值：**0** 最大值：**200** 缺省值：**200**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| offset                      | 否    | Integer | 偏移量，默认值0 最小值：**0** 最大值：**65535** 缺省值：**0**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| migration_cycle             | 否    | String  | checking:检查中 setting:设置中 replicating:复制中 syncing:同步中 cutovering:启动目的端中 cutovered:启动目的端完成 最小长度：**0** 最大长度：**255** 枚举值： - **checking**   - **setting**   - **replicating**   - **syncing**   - **cutovering**   - **cutovered**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| connected                   | 否    | Boolean | 查询失去连接的源端                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| enterprise_project_id       | 否    | String  | 需要查询的企业项目ID 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| is_consistency_result_exist | 否    | Boolean | 是否存在一致性校验结果                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| vm_id                       | 否    | String  | 平台的克隆服务器id 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
   
#### 请求参数
表2请求Header参数 
| 参数           | 是否必选 | 参数类型   | 描述                                                                                                                                                                               |
|:---|:---|:---|:---|
| X-Auth-Token | 是    | String | 用户Token。 通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 最小长度：**1** 最大长度：**16384** |
   
#### 响应参数
**状态码：200**
表3响应Body参数 
| 参数             | 参数类型                                                                                           | 描述                                                                                                                       |
|:---|:---|:---|
| count          | Integer                                                                                        | 符合查询条件的源端总数量，不受limit和offset影响 最小值：**0** 最大值：**2147483647** |
| source_servers | Array of [SourceServersResponseBody] objects | 批量查询的源端服务器详列表 数组长度：**0 - 65535**                                                          |
   
 表4SourceServersResponseBody 
| 参数                          | 参数类型                                                                         | 描述                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
|:---|:---|:---|
| id                          | String                                                                       | 源端服务器ID 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| ip                          | String                                                                       | 源端服务器的IP地址 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
| name                        | String                                                                       | 源端服务器名称 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| enterprise_project_id       | String                                                                       | 企业项目ID 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| add_date                    | Long                                                                         | 源端服务器的注册时间 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| os_type                     | String                                                                       | 操作系统类型，OS_TYPE (WINDOWS/LINUX) 最小长度：**0** 最大长度：**255** 枚举值： - **WINDOWS**   - **LINUX**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
| os_version                  | String                                                                       | 系统详细版本号，如CENTOS7.6等 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| oem_system                  | Boolean                                                                      | 是否是OEM操作系统(Windows)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| state                       | String                                                                       | 源端服务器状态 unavailable：环境校验不通过 waiting：等待 initialize：初始化 replicate：复制 syncing：持续同步 stopping：暂停中 stopped：已暂停 skipping：跳过中 deleting：删除中 clearing: 清理快照资源中 cleared：清理快照资源完成 clearfailed：清理快照资源失败 premigready：迁移演练就绪 premiged：迁移演练完成 premigfailed：迁移演练失败 cloning：等待克隆完成 cutovering：启动目的端中 finished：启动目的端完成 error：错误 最小长度：**0** 最大长度：**255** 枚举值： - **unavailable**   - **waiting**   - **initialize**   - **replicate**   - **syncing**   - **stopping**   - **stopped**   - **skipping**   - **deleting**   - **clearing**   - **cleared**   - **clearfailed**   - **premigready**   - **premiged**   - **premigfailed**   - **cloning**   - **cutovering**   - **finished**   - **error**    |
| connected                   | Boolean                                                                      | 源端服务器与主机迁移服务端是否连接                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| cpu_quantity                | Integer                                                                      | 源端CPU核心数 最小值：**0** 最大值：**2147483647**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| memory                      | Long                                                                         | 源端物理内存大小（单位：字节） 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| current_task                | [TaskByServerSources] object     | 源端列表中关联的任务                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| checks                      | Array of [EnvironmentCheck] objects | 源端校验检查项列表 数组长度：**0 - 65535**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| init_target_server          | [InitTargetServer] object           | 推荐的目的端服务器配置                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| replicatesize               | Long                                                                         | 已复制的大小（单位：字节） 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| stage_action_time           | Long                                                                         | 迁移周期（migration_cycle）上一次变化的时间 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| totalsize                   | Long                                                                         | 需要迁移的数据量总大小（单位：字节） 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| last_visit_time             | Long                                                                         | Agent上一次连接状态发生变化的时间 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| migration_cycle             | String                                                                       | 迁移周期 cutovering:启动目的端中 cutovered:启动目的端完成 checking:检查中 setting:设置中 replicating:复制中 syncing:同步中 最小长度：**0** 最大长度：**255** 枚举值： - **cutovering**   - **cutovered**   - **checking**   - **setting**   - **replicating**   - **syncing**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| state_action_time           | Long                                                                         | 源端状态（state）上次发生变化的时间 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| is_consistency_result_exist | Boolean                                                                      | 是否有一致性校验结果 缺省值：**false**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| has_tc                      | Boolean                                                                      | 是否安装tc组件，Linux系统此参数为必选                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| start_type                  | String                                                                       | 启动方式 可以取值MANUAL、AUTO或者空，不进行校验。 默认值取值MANUAL，其余则表示从MGC平台启动 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
   
 表5TaskByServerSources 
| 参数                     | 参数类型                                                               | 描述                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
|:---|:---|:---|
| id                     | String                                                             | 任务ID 最小长度：**1** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| name                   | String                                                             | 任务名称 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| type                   | String                                                             | 迁移项目类型 MIGRATE_BLOCK:块级迁移 MIGRATE_FILE:文件级迁移 枚举值： - **MIGRATE_BLOCK**   - **MIGRATE_FILE**                                                                                                                                                                                                                                                                                                                                       |
| state                  | String                                                             | 任务状态 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| estimate_complete_time | Long                                                               | 预估结束时间 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| start_date             | Long                                                               | 开始时间 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| speed_limit            | Integer                                                            | 限速 最小值：**0** 最大值：**10000**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| migrate_speed          | Double                                                             | 迁移速率 最小值：**0** 最大值：**10000**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| compress_rate          | Double                                                             | 压缩率 最小值：**0** 最大值：**10000**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| start_target_server    | Boolean                                                            | 是否启动虚拟机                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| vm_template_id         | String                                                             | 虚拟机模板ID 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
| region_id              | String                                                             | region_id 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| project_name           | String                                                             | 项目名称 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| project_id             | String                                                             | 项目ID 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| target_server          | [TargetServerById] object | 目的端                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| log_collect_status     | String                                                             | 日志收集状态 INIT:就绪 UPLOADING:上传中 UPLOAD_FAIL:上传失败 UPLOADED:已上传 枚举值： - **INIT**   - **UPLOADING**   - **UPLOAD_FAIL**   - **UPLOADED**    |
| exist_server           | Boolean                                                            | 是否使用已有虚拟机                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| use_public_ip          | Boolean                                                            | 是否使用公网IP                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| clone_server           | [CloneServer] object           | 克隆服务器类                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| remain_seconds         | Long                                                               | 迁移剩余时间（秒） 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
| log_bucket             | String                                                             | 上传日志指定桶名称 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| log_expire             | Long                                                               | 分享链接有效期 最小值：**300** 最大值：**64800**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| log_upload_time        | Long                                                               | 日志上传时间 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| log_share_url          | String                                                             | 分享链接url 最小长度：**0** 最大长度：**65535**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| subtask_info           | String                                                             | 当前子任务及进度 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
   
 表6TargetServerById 
| 参数    | 参数类型   | 描述                                                                                             |
|:---|:---|:---|
| vm_id | String | 目的端服务器ID 最小长度：**0** 最大长度：**255** |
| name  | String | 目的端服务器名称 最小长度：**0** 最大长度：**255** |
   
 表7CloneServer 
| 参数          | 参数类型   | 描述                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
|:---|:---|:---|
| vm_id       | String | 克隆服务器ID 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| name        | String | 克隆虚拟机的名称 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| clone_error | String | 克隆错误信息 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| clone_state | String | 克隆状态 NOT_READY: 未准备好 READY: 就绪 PREPARING: 准备创建中 CREATING: 创建中 ERROR: 克隆错误 FINISHED: 克隆结束 枚举值： - **NOT_READY**   - **READY**   - **PREPARING**   - **CREATING**   - **ERROR**   - **FINISHED**    |
| error_msg   | String | 克隆错误信息描述 最小长度：**0** 最大长度：**1024**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
   
 表8EnvironmentCheck 
| 参数            | 参数类型             | 描述                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
|:---|:---|:---|
| id            | Long             | 该检查项的ID 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| params        | Array of strings | 参数 最小长度：**0** 最大长度：**255** 数组长度：**0 - 65535**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| name          | String           | 检查项名称 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| result        | String           | 检查结果 OK：检查通过 WARN：警告 ERROR:检查不通过 最小长度：**0** 最大长度：**255** 枚举值： - **OK**   - **WARN**   - **ERROR**    |
| error_code    | String           | 检查不通过的错误码 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| error_or_warn | String           | 检查的错误或者警告 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| error_params  | String           | 检查不通过的错误参数 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
   
 表9InitTargetServer 
| 参数            | 参数类型                                                                             | 描述                                                                      |
|:---|:---|:---|
| disks         | Array of [DiskIntargetServer] objects | 推荐的目的端服务器的磁盘信息 数组长度：**0 - 65535**        |
| volume_groups | Array of [VolumeGroups] objects             | Linux必选，如果没有卷组，输入\[\] 数组长度：**0 - 65535** |
   
 表10DiskIntargetServer 
| 参数               | 参数类型                                                                       | 描述                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
|:---|:---|:---|
| name             | String                                                                     | 磁盘名称 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| size             | Long                                                                       | 磁盘大小，单位：字节 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| device_use       | String                                                                     | 磁盘的作用 BOOT：BOOT设备 OS：系统设备 NORMAL:平常 最小长度：**0** 最大长度：**255** 枚举值： - **BOOT**   - **OS**   - **NORMAL**    |
| used_size        | Long                                                                       | 磁盘已使用大小，以字节为单位 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| physical_volumes | Array of [PhysicalVolumes] objects | 物理卷信息 数组长度：**0 - 65535**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
   
 表11PhysicalVolumes 
| 参数          | 参数类型    | 描述                                                                                                              |
|:---|:---|:---|
| device_use  | String  | 分区类型，普通分区，启动分区，系统分区 最小长度：**0** 最大长度：**255**       |
| file_system | String  | 文件系统类型 最小长度：**0** 最大长度：**255**                    |
| index       | Integer | 顺序 最小值：**0** 最大值：**2147483647**                   |
| mount_point | String  | 挂载点 最小长度：**0** 最大长度：**255**                       |
| name        | String  | 名称，windows表示盘符，Linux表示设备号 最小长度：**0** 最大长度：**255** |
| size        | Long    | 大小 最小值：**0** 最大值：**9223372036854775807**          |
| inode_size  | Long    | inode数量 最小值：**0** 最大值：**9223372036854775807**     |
| used_size   | Long    | 使用大小 最小值：**0** 最大值：**9223372036854775807**        |
| uuid        | String  | GUID，可从源端查询 最小长度：**0** 最大长度：**255**               |
   
 表12VolumeGroups 
| 参数              | 参数类型                                                                     | 描述                                                                                                       |
|:---|:---|:---|
| components      | String                                                                   | Pv信息 最小长度：**0** 最大长度：**255**               |
| free_size       | Long                                                                     | 剩余空间 最小值：**0** 最大值：**9223372036854775807** |
| logical_volumes | Array of [LogicalVolumes] objects | lv信息 数组长度：**0 - 50**                                                      |
| name            | String                                                                   | 名称 最小长度：**0** 最大长度：**255**                 |
| size            | Long                                                                     | 大小 最小值：**0** 最大值：**9223372036854775807**   |
   
 表13LogicalVolumes 
| 参数          | 参数类型    | 描述                                                                                                                                                                                                                                                                                                                                                                               |
|:---|:---|:---|
| block_count | Integer | 块数量 最小值：**0** 最大值：**2147483647** 缺省值：**0**                                                                                                                                                                                                                                          |
| block_size  | Long    | 块大小 最小值：**0** 最大值：**1048576** 缺省值：**0**                                                                                                                                                                                                                                             |
| file_system | String  | 文件系统 最小长度：**0** 最大长度：**255**                                                                                                                                                                                                                                                                                       |
| inode_size  | Integer | inode数量 最小值：**0** 最大值：**2147483647**                                                                                                                                                                                                                                                                               |
| inode_nums  | Long    | inode节点数量 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                    |
| device_use  | String  | 分区类型 无强约束，可为空值，常见取值如下 NORMAL：平常 OS：系统设备 BOOT：BOOT设备 VOLUME_GROUP：VolumeGroup组成设备 BTRFS：BTRFS组成设备 最小长度：**0** 最大长度：**255** |
| mount_point | String  | 挂载点 最小长度：**0** 最大长度：**256**                                                                                                                                                                                                                                                                                        |
| name        | String  | 名称 最小长度：**0** 最大长度：**1024**                                                                                                                                                                                                                                                                                        |
| size        | Long    | 大小 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                           |
| used_size   | Long    | 使用大小 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                         |
| free_size   | Long    | 剩余空间 最小值：**0** 最大值：**9223372036854775807**                                                                                                                                                                                                                                                                         |
   
**状态码：403**
表14响应Body参数 
| 参数                            | 参数类型                                                       | 描述                                                                                                                                          |
|:---|:---|:---|
| error_code                    | String                                                     | 错误代码 最小长度：**0** 最大长度：**255**                                                  |
| error_msg                     | String                                                     | 错误信息 最小长度：**0** 最大长度：**255**                                                  |
| encoded_authorization_message | String                                                     | 加密授权信息 最小长度：**0** 最大长度：**65535**                                              |
| error_param                   | Array of strings                                           | 错误参数 最小长度：**0** 最大长度：**65535** 数组长度：**1 - 20** |
| details                       | Array of [details] objects | 详细错误信息 数组长度：**1 - 20**                                                                                       |
   
 表15details 
| 参数         | 参数类型   | 描述                                                                                              |
|:---|:---|:---|
| error_code | String | SMS错误代码 最小长度：**0** 最大长度：**65535** |
| error_msg  | String | SMS错误信息 最小长度：**0** 最大长度：**65535** |
   
**状态码：500**
表16响应Body参数 
| 参数         | 参数类型   | 描述                                                                                          |
|:---|:---|:---|
| error_code | String | 错误码 最小长度：**0** 最大长度：**255**   |
| error_msg  | String | 错误信息 最小长度：**0** 最大长度：**1024** |
   
#### 请求示例
查询源端列表信息，每页10个源端，查看第0页。
```
GET https://{endpoint}/v3/sources?limit=10&offset=0
X-Auth-Token: XXXX
```
#### 响应示例
**状态码：200**
查询源端服务器列表成功。
```
{
  "count" : 10,
  "source_servers" : [ {
    "id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
    "ip" : "192.168.0.1",
    "name" : "sms-test",
    "enterprise_project_id" : "0",
    "add_date" : 1598417717000,
    "os_type" : "WINDOWS",
    "os_version" : "WINDOWS2008_R2_64BIT",
    "oem_system" : false,
    "state" : "finished",
    "connected" : true,
    "cpu_quantity" : 1,
    "memory" : 2146557952,
    "current_task" : {
      "id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
      "name" : "MigrationTask",
      "type" : "MIGRATE_BLOCK",
      "state" : "MIGRATE_SUCCESS",
      "estimate_complete_time" : null,
      "start_date" : 1598417771000,
      "speed_limit" : 0,
      "migrate_speed" : 0,
      "start_target_server" : true,
      "vm_template_id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
      "region_id" : "region_id",
      "project_name" : "project_name",
      "project_id" : "xxxxxxxxxxxxxxxxxxxxxxxx00000001",
      "target_server" : {
        "vm_id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
        "name" : "sms-test"
      },
      "log_collect_status" : "INIT",
      "exist_server" : false,
      "use_public_ip" : true,
      "clone_server" : null,
      "remain_seconds" : null
    },
    "checks" : [ {
      "id" : 524062,
      "params" : [ "" ],
      "name" : "OS_VERSION",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524063,
      "params" : [ "" ],
      "name" : "FIRMWARE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524064,
      "params" : [ "" ],
      "name" : "CPU",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524065,
      "params" : [ "" ],
      "name" : "MEMORY",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524066,
      "params" : [ "" ],
      "name" : "SYSTEM_ROOT",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524067,
      "params" : [ "" ],
      "name" : "PARTITION_STYLE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524068,
      "params" : [ "" ],
      "name" : "FILE_SYSTEM",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524069,
      "params" : [ "" ],
      "name" : "FREE_SPACE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524070,
      "params" : [ "" ],
      "name" : "OEM_SYSTEM",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524071,
      "params" : [ "" ],
      "name" : "DRIVER_FILE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524072,
      "params" : [ "" ],
      "name" : "SERVICE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524073,
      "params" : [ "" ],
      "name" : "ACCOUNT_RIGHTS",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    } ],
    "init_target_server" : {
      "volume_groups" : [ ],
      "disks" : [ {
        "name" : "Disk 0",
        "size" : 42949672960,
        "device_use" : "OS"
      } ]
    },
    "replicatesize" : 0,
    "stage_action_time" : 1598419352959,
    "totalsize" : 0,
    "last_visit_time" : 1598434312002,
    "migration_cycle" : "cutovered",
    "state_action_time" : 1598419352959,
    "start_type" : "MANUAL"
  }, {
    "id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
    "ip" : "192.168.0.154",
    "name" : "sms-win16",
    "add_date" : 1598417612000,
    "os_type" : "WINDOWS",
    "os_version" : "WINDOWS2016_64BIT",
    "oem_system" : false,
    "state" : "finished",
    "connected" : true,
    "cpu_quantity" : 1,
    "memory" : 2146553856,
    "current_task" : {
      "id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
      "name" : "MigrationTask",
      "type" : "MIGRATE_BLOCK",
      "state" : "MIGRATE_SUCCESS",
      "estimate_complete_time" : null,
      "start_date" : 1598417627000,
      "speed_limit" : 0,
      "migrate_speed" : 0,
      "start_target_server" : true,
      "vm_template_id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
      "region_id" : "region_id",
      "project_name" : "project_name",
      "project_id" : "xxxxxxxxxxxxxxxxxxxxxxxx00000001",
      "target_server" : {
        "vm_id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
        "name" : "e2e-sms-win16"
      },
      "log_collect_status" : "INIT",
      "exist_server" : false,
      "use_public_ip" : true,
      "clone_server" : null,
      "remain_seconds" : null
    },
    "checks" : [ {
      "id" : 524050,
      "params" : [ "" ],
      "name" : "OS_VERSION",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524051,
      "params" : [ "" ],
      "name" : "FIRMWARE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524052,
      "params" : [ "" ],
      "name" : "CPU",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524053,
      "params" : [ "" ],
      "name" : "MEMORY",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524054,
      "params" : [ "" ],
      "name" : "SYSTEM_ROOT",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524055,
      "params" : [ "" ],
      "name" : "PARTITION_STYLE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524056,
      "params" : [ "" ],
      "name" : "FILE_SYSTEM",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524057,
      "params" : [ "" ],
      "name" : "FREE_SPACE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524058,
      "params" : [ "" ],
      "name" : "OEM_SYSTEM",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524059,
      "params" : [ "" ],
      "name" : "DRIVER_FILE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524060,
      "params" : [ "" ],
      "name" : "SERVICE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524061,
      "params" : [ "" ],
      "name" : "ACCOUNT_RIGHTS",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    } ],
    "init_target_server" : {
      "volume_groups" : [ ],
      "disks" : [ {
        "name" : "Disk 0",
        "size" : 42949672960,
        "device_use" : "OS"
      } ]
    },
    "replicatesize" : 0,
    "stage_action_time" : 1598419339661,
    "totalsize" : 0,
    "last_visit_time" : 1598434316810,
    "migration_cycle" : "cutovered",
    "state_action_time" : 1598419339661,
    "start_type" : "AUTO"
  }, {
    "id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
    "ip" : "192.168.77.77",
    "name" : "sms-centos",
    "add_date" : 1598417551000,
    "os_type" : "LINUX",
    "os_version" : "CENTOS_7_4_64BIT",
    "oem_system" : false,
    "state" : "error",
    "connected" : true,
    "cpu_quantity" : 1,
    "memory" : 1038716928,
    "current_task" : {
      "id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
      "name" : "MigrationTask",
      "type" : "MIGRATE_BLOCK",
      "state" : "MIGRATE_FAIL",
      "estimate_complete_time" : null,
      "start_date" : 1598417588000,
      "speed_limit" : 0,
      "migrate_speed" : 0,
      "start_target_server" : true,
      "vm_template_id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
      "region_id" : "region_id",
      "project_name" : "project_name",
      "project_id" : "xxxxxxxxxxxxxxxxxxxxxxxx00000001",
      "target_server" : {
        "vm_id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
        "name" : "e2e-sms-centos"
      },
      "log_collect_status" : "INIT",
      "exist_server" : false,
      "use_public_ip" : true,
      "clone_server" : null,
      "remain_seconds" : null
    },
    "checks" : [ {
      "id" : 524038,
      "params" : [ "" ],
      "name" : "OS_VERSION",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524039,
      "params" : [ "" ],
      "name" : "CPU",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524040,
      "params" : [ "" ],
      "name" : "MEMORY",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524041,
      "params" : [ "" ],
      "name" : "PARAVIRTUALIZATION",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524042,
      "params" : [ "" ],
      "name" : "FIRMWARE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524043,
      "params" : [ "" ],
      "name" : "BOOT_LOADER",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524044,
      "params" : [ "" ],
      "name" : "RSYNC",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524045,
      "params" : [ "" ],
      "name" : "RAW_DEVICES",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524046,
      "params" : [ "" ],
      "name" : "DISK_INFO",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524047,
      "params" : [ "" ],
      "name" : "PARTITION_STYLE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524048,
      "params" : [ "" ],
      "name" : "FILE_SYSTEM",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 524049,
      "params" : [ "" ],
      "name" : "LINUX_BLOCK_SUPPORT",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    } ],
    "init_target_server" : {
      "volume_groups" : [ ],
      "disks" : [ {
        "name" : "/dev/vda",
        "size" : 42949672960,
        "device_use" : "BOOT"
      } ]
    },
    "has_tc" : true,
    "replicatesize" : 42949672960,
    "stage_action_time" : 1598428182454,
    "totalsize" : 42949672960,
    "last_visit_time" : 1598434308889,
    "migration_cycle" : "syncing",
    "state_action_time" : 1598428182454,
    "start_type" : ""
  }, {
    "id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
    "ip" : "192.168.0.235",
    "name" : "sms-ubuntu",
    "add_date" : 1598417522000,
    "os_type" : "LINUX",
    "os_version" : "UBUNTU_18_4_64BIT",
    "oem_system" : false,
    "state" : "unavailable",
    "connected" : false,
    "cpu_quantity" : 1,
    "memory" : 1032556544,
    "current_task" : null,
    "checks" : [ ],
    "init_target_server" : {
      "volume_groups" : [ ],
      "disks" : [ {
        "name" : "/dev/vda",
        "size" : 42949672960,
        "device_use" : "BOOT"
      }, {
        "name" : "/dev/vdb",
        "size" : 21474836480,
        "device_use" : "NORMAL"
      } ]
    },
    "has_tc" : true,
    "replicatesize" : 0,
    "stage_action_time" : 1598417521797,
    "totalsize" : 0,
    "last_visit_time" : 1598417521795,
    "migration_cycle" : "checking",
    "state_action_time" : null,
    "start_type" : "MANUAL"
  }, {
    "id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
    "ip" : "192.168.178.214",
    "name" : "sms-sms2",
    "add_date" : 1598403465000,
    "os_type" : "WINDOWS",
    "os_version" : "WINDOWS2012_R2_64BIT",
    "oem_system" : false,
    "state" : "waiting",
    "connected" : false,
    "cpu_quantity" : 1,
    "memory" : 2146553856,
    "current_task" : null,
    "checks" : [ {
      "id" : 523970,
      "params" : [ "" ],
      "name" : "OS_VERSION",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523971,
      "params" : [ "" ],
      "name" : "FIRMWARE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523972,
      "params" : [ "" ],
      "name" : "CPU",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523973,
      "params" : [ "" ],
      "name" : "MEMORY",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523974,
      "params" : [ "" ],
      "name" : "SYSTEM_ROOT",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523975,
      "params" : [ "" ],
      "name" : "PARTITION_STYLE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523976,
      "params" : [ "" ],
      "name" : "FILE_SYSTEM",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523977,
      "params" : [ "" ],
      "name" : "FREE_SPACE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523978,
      "params" : [ "" ],
      "name" : "OEM_SYSTEM",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523979,
      "params" : [ "" ],
      "name" : "DRIVER_FILE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523980,
      "params" : [ "" ],
      "name" : "SERVICE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523981,
      "params" : [ "" ],
      "name" : "ACCOUNT_RIGHTS",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    } ],
    "init_target_server" : {
      "volume_groups" : [ ],
      "disks" : [ {
        "name" : "Disk 0",
        "size" : 42949672960,
        "device_use" : "OS"
      } ]
    },
    "replicatesize" : 0,
    "stage_action_time" : 1598403465315,
    "totalsize" : 0,
    "last_visit_time" : 1598403588140,
    "migration_cycle" : "checking",
    "state_action_time" : 1598403465414,
    "start_type" : "MANUAL"
  }, {
    "id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
    "ip" : "192.168.0.1",
    "name" : "linux sources",
    "add_date" : 1598369476000,
    "os_type" : "LINUX",
    "os_version" : "REDHAT_7_3_64BIT",
    "oem_system" : false,
    "state" : "unavailable",
    "connected" : false,
    "cpu_quantity" : 4,
    "memory" : 8581140480,
    "current_task" : null,
    "checks" : [ ],
    "init_target_server" : {
      "volume_groups" : [ ],
      "disks" : [ {
        "name" : "sda",
        "size" : 85899345920,
        "device_use" : "BOOT"
      }, {
        "name" : "sdb",
        "size" : 214748364800,
        "device_use" : "NORMAL"
      } ]
    },
    "has_tc" : true,
    "replicatesize" : 0,
    "stage_action_time" : 1598369475726,
    "totalsize" : 0,
    "last_visit_time" : 1598369475725,
    "migration_cycle" : "checking",
    "state_action_time" : null,
    "start_type" : "MANUAL"
  }, {
    "id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
    "ip" : "192.168.0.1",
    "name" : "linux sources",
    "add_date" : 1598351694000,
    "os_type" : "LINUX",
    "os_version" : "REDHAT_7_3_64BIT",
    "oem_system" : false,
    "state" : "unavailable",
    "connected" : false,
    "cpu_quantity" : 4,
    "memory" : 8581140480,
    "current_task" : null,
    "checks" : [ ],
    "init_target_server" : {
      "volume_groups" : [ ],
      "disks" : [ {
        "name" : "sda",
        "size" : 85899345920,
        "device_use" : "BOOT"
      }, {
        "name" : "sdb",
        "size" : 214748364800,
        "device_use" : "NORMAL"
      } ]
    },
    "has_tc" : true,
    "replicatesize" : 0,
    "stage_action_time" : 1598351693858,
    "totalsize" : 0,
    "last_visit_time" : 1598351693857,
    "migration_cycle" : "checking",
    "state_action_time" : null,
    "start_type" : "MANUAL"
  }, {
    "id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
    "ip" : "192.168.0.1",
    "name" : "linux sources",
    "add_date" : 1598348080000,
    "os_type" : "LINUX",
    "os_version" : "REDHAT_7_3_64BIT",
    "oem_system" : false,
    "state" : "unavailable",
    "connected" : false,
    "cpu_quantity" : 4,
    "memory" : 8581140480,
    "current_task" : null,
    "checks" : [ ],
    "init_target_server" : {
      "volume_groups" : [ ],
      "disks" : [ {
        "name" : "sda",
        "size" : 85899345920,
        "device_use" : "BOOT"
      }, {
        "name" : "sdb",
        "size" : 214748364800,
        "device_use" : "NORMAL"
      } ]
    },
    "has_tc" : true,
    "replicatesize" : 0,
    "stage_action_time" : 1598348079782,
    "totalsize" : 0,
    "last_visit_time" : 1598348079781,
    "migration_cycle" : "checking",
    "state_action_time" : null,
    "start_type" : "MANUAL"
  }, {
    "id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
    "ip" : "192.168.0.239",
    "name" : "sms-centos7",
    "add_date" : 1598326505000,
    "os_type" : "LINUX",
    "os_version" : "CENTOS_8_5_64BIT",
    "oem_system" : false,
    "state" : "unavailable",
    "connected" : false,
    "cpu_quantity" : 1,
    "memory" : 1926860800,
    "current_task" : null,
    "checks" : [ {
      "id" : 523794,
      "params" : [ "" ],
      "name" : "OS_VERSION",
      "result" : "ERROR",
      "error_code" : "SMS.6504",
      "error_params" : ""
    }, {
      "id" : 523795,
      "params" : [ "" ],
      "name" : "CPU",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523796,
      "params" : [ "" ],
      "name" : "MEMORY",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523797,
      "params" : [ "" ],
      "name" : "PARAVIRTUALIZATION",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523798,
      "params" : [ "" ],
      "name" : "FIRMWARE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523799,
      "params" : [ "" ],
      "name" : "BOOT_LOADER",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523800,
      "params" : [ "" ],
      "name" : "RSYNC",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523801,
      "params" : [ "" ],
      "name" : "RAW_DEVICES",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523802,
      "params" : [ "" ],
      "name" : "DISK_INFO",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523803,
      "params" : [ "" ],
      "name" : "PARTITION_STYLE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523804,
      "params" : [ "" ],
      "name" : "FILE_SYSTEM",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523805,
      "params" : [ "" ],
      "name" : "LINUX_BLOCK_SUPPORT",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    } ],
    "init_target_server" : {
      "volume_groups" : [ ],
      "disks" : [ {
        "name" : "/dev/vda",
        "size" : 42949672960,
        "device_use" : "BOOT"
      }, {
        "name" : "/dev/vdb",
        "size" : 42949672960,
        "device_use" : "NORMAL"
      } ]
    },
    "has_tc" : true,
    "replicatesize" : 0,
    "stage_action_time" : 1598326505378,
    "totalsize" : 0,
    "last_visit_time" : 1598423828868,
    "migration_cycle" : "checking",
    "state_action_time" : 1598326505459,
    "start_type" : "MANUAL"
  }, {
    "id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
    "ip" : "192.168.0.65",
    "name" : "smsc-test",
    "add_date" : 1598238727000,
    "os_type" : "LINUX",
    "os_version" : "CENTOS_6_5_64BIT",
    "oem_system" : false,
    "state" : "finished",
    "connected" : true,
    "cpu_quantity" : 1,
    "memory" : 1043931136,
    "current_task" : {
      "id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
      "name" : "MigrationTask",
      "type" : "MIGRATE_FILE",
      "state" : "MIGRATE_SUCCESS",
      "estimate_complete_time" : null,
      "start_date" : 1598239243000,
      "speed_limit" : 0,
      "migrate_speed" : 0,
      "start_target_server" : true,
      "vm_template_id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
      "region_id" : "region_id",
      "project_name" : "project_name",
      "project_id" : "xxxxxxxxxxxxxxxxxxxxxxxx00000001",
      "target_server" : {
        "vm_id" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx0001",
        "name" : "smsc-test"
      },
      "log_collect_status" : "INIT",
      "exist_server" : false,
      "use_public_ip" : true,
      "clone_server" : null,
      "remain_seconds" : null
    },
    "checks" : [ {
      "id" : 523686,
      "params" : [ "" ],
      "name" : "OS_VERSION",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523687,
      "params" : [ "" ],
      "name" : "CPU",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523688,
      "params" : [ "" ],
      "name" : "MEMORY",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523689,
      "params" : [ "" ],
      "name" : "PARAVIRTUALIZATION",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523690,
      "params" : [ "" ],
      "name" : "FIRMWARE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523691,
      "params" : [ "" ],
      "name" : "BOOT_LOADER",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523692,
      "params" : [ "" ],
      "name" : "RSYNC",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523693,
      "params" : [ "" ],
      "name" : "RAW_DEVICES",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523694,
      "params" : [ "" ],
      "name" : "DISK_INFO",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523695,
      "params" : [ "" ],
      "name" : "PARTITION_STYLE",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523696,
      "params" : [ "" ],
      "name" : "FILE_SYSTEM",
      "result" : "OK",
      "error_code" : null,
      "error_params" : ""
    }, {
      "id" : 523697,
      "params" : [ "" ],
      "name" : "LINUX_BLOCK_SUPPORT",
      "result" : "WARN",
      "error_code" : "SMS.6617",
      "error_params" : ""
    } ],
    "init_target_server" : {
      "volume_groups" : [ ],
      "disks" : [ {
        "name" : "/dev/vda",
        "size" : 42949672960,
        "device_use" : "BOOT"
      }, {
        "name" : "/dev/vdb",
        "size" : 10737418240,
        "device_use" : "NORMAL"
      } ]
    },
    "has_tc" : true,
    "replicatesize" : 0,
    "stage_action_time" : 1598240178677,
    "totalsize" : 0,
    "last_visit_time" : 1598434314748,
    "migration_cycle" : "cutovered",
    "state_action_time" : 1598240178677,
    "start_type" : "MANUAL"
  } ]
}
```
**状态码：403**
鉴权失败
```
{
  "error_code" : "SMS.9004",
  "error_msg" : "The current account does not have the permission to execute policy. You do not have permission to perform action XXX on resource XXX.",
  "encoded_authorization_message" : "XXXXXX",
  "error_param" : [ "You do not have permission to perform action XXX on resource XXX." ],
  "details" : [ {
    "error_code" : "SMS.9004",
    "error_msg" : "You do not have permission to perform action XXX on resource XXX."
  } ]
}
```
#### SDK代码示例
SDK代码示例如下。
- [Java]
  ```
  package com.huaweicloud.sdk.test;
  import com.huaweicloud.sdk.core.auth.ICredential;
  import com.huaweicloud.sdk.core.auth.GlobalCredentials;
  import com.huaweicloud.sdk.core.exception.ConnectionException;
  import com.huaweicloud.sdk.core.exception.RequestTimeoutException;
  import com.huaweicloud.sdk.core.exception.ServiceResponseException;
  import com.huaweicloud.sdk.sms.v3.region.SmsRegion;
  import com.huaweicloud.sdk.sms.v3.*;
  import com.huaweicloud.sdk.sms.v3.model.*;
  public class ListServersSolution {
      public static void main(String[] args) {
          // The AK and SK used for authentication are hard-coded or stored in plaintext, which has great security risks. It is recommended that the AK and SK be stored in ciphertext in configuration files or environment variables and decrypted during use to ensure security.
          // In this example, AK and SK are stored in environment variables for authentication. Before running this example, set environment variables CLOUD_SDK_AK and CLOUD_SDK_SK in the local environment
          String ak = System.getenv("CLOUD_SDK_AK");
          String sk = System.getenv("CLOUD_SDK_SK");
          ICredential auth = new GlobalCredentials()
                  .withAk(ak)
                  .withSk(sk);
          SmsClient client = SmsClient.newBuilder()
                  .withCredential(auth)
                  .withRegion(SmsRegion.valueOf("<YOUR REGION>"))
                  .build();
          ListServersRequest request = new ListServersRequest();
          try {
              ListServersResponse response = client.listServers(request);
              System.out.println(response.toString());
          } catch (ConnectionException e) {
              e.printStackTrace();
          } catch (RequestTimeoutException e) {
              e.printStackTrace();
          } catch (ServiceResponseException e) {
              e.printStackTrace();
              System.out.println(e.getHttpStatusCode());
              System.out.println(e.getRequestId());
              System.out.println(e.getErrorCode());
              System.out.println(e.getErrorMsg());
          }
      }
  }
  ```
- [Python]
  ```
  # coding: utf-8
  import os
  from huaweicloudsdkcore.auth.credentials import GlobalCredentials
  from huaweicloudsdksms.v3.region.sms_region import SmsRegion
  from huaweicloudsdkcore.exceptions import exceptions
  from huaweicloudsdksms.v3 import *
  if __name__ == "__main__":
      # The AK and SK used for authentication are hard-coded or stored in plaintext, which has great security risks. It is recommended that the AK and SK be stored in ciphertext in configuration files or environment variables and decrypted during use to ensure security.
      # In this example, AK and SK are stored in environment variables for authentication. Before running this example, set environment variables CLOUD_SDK_AK and CLOUD_SDK_SK in the local environment
      ak = os.environ["CLOUD_SDK_AK"]
      sk = os.environ["CLOUD_SDK_SK"]
      credentials = GlobalCredentials(ak, sk)
      client = SmsClient.new_builder() \
          .with_credentials(credentials) \
          .with_region(SmsRegion.value_of("<YOUR REGION>")) \
          .build()
      try:
          request = ListServersRequest()
          response = client.list_servers(request)
          print(response)
      except exceptions.ClientRequestException as e:
          print(e.status_code)
          print(e.request_id)
          print(e.error_code)
          print(e.error_msg)
  ```
- [Go]
  ```
  package main
  import (
  "fmt"
  "github.com/huaweicloud/huaweicloud-sdk-go-v3/core/auth/global"
      sms "github.com/huaweicloud/huaweicloud-sdk-go-v3/services/sms/v3"
  "github.com/huaweicloud/huaweicloud-sdk-go-v3/services/sms/v3/model"
      region "github.com/huaweicloud/huaweicloud-sdk-go-v3/services/sms/v3/region"
  )
  func main() {
      // The AK and SK used for authentication are hard-coded or stored in plaintext, which has great security risks. It is recommended that the AK and SK be stored in ciphertext in configuration files or environment variables and decrypted during use to ensure security.
      // In this example, AK and SK are stored in environment variables for authentication. Before running this example, set environment variables CLOUD_SDK_AK and CLOUD_SDK_SK in the local environment
      ak := os.Getenv("CLOUD_SDK_AK")
      sk := os.Getenv("CLOUD_SDK_SK")
      auth, err := global.NewCredentialsBuilder().
          WithAk(ak).
          WithSk(sk).
          SafeBuild()
      if err != nil {
          fmt.Println(err)
          return
      }
      hcClient, err := sms.SmsClientBuilder().
           WithRegion(region.ValueOf("<YOUR REGION>")).
           WithCredential(auth).
           SafeBuild()
      if err != nil {
          fmt.Println(err)
          return
      }
      client := sms.NewSmsClient(hcClient)
      request := &model.ListServersRequest{}
  response, err := client.ListServers(request)
  if err == nil {
          fmt.Printf("%+v\n", response)
      } else {
          fmt.Println(err)
      }
  }
  ```
- [更多]
  更多编程语言的SDK代码示例，请参见[API Explorer](https://console.huaweicloud.com/apiexplorer/#/openapi/SMS/sdk?api=ListServers)的代码示例页签，可生成自动对应的SDK代码示例。
#### 状态码
| 状态码 | 描述                    |
|:---|:---|
| 200 | 查询源端服务器列表成功。          |
| 403 | 鉴权失败                  |
| 500 | Internal Server Error |
   
#### 错误码
请参见[错误码](https://support.huaweicloud.com/api-sms/ErrorCode.html)。
