Queries the hosts of users.

Debugging

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

Request parameters

Parameter Type Required Example Description
Action String Yes ListUserHosts

The operation that you want to perform. Set the value to ListUserHosts.

Search String No ip:1.1.1.1

Specifies the host you want to query.

CurrentPage Integer No 1

The number of the page to return.

Default value: 1.

PageSize Integer No 10

The number of entries to return on each page.

Default value: 10.

Maximum value: 10.

Response parameters

Parameter Type Example Description
CurrentPage Integer 1

The number of the returned page.

PageSize Integer 10

The number of entries returned per page.

Records Array

The returned host information.

Hostname String guest

The hostname in the returned host information.

IP String 192.168.1.1

The IP address in the returned host information.

Id Integer 1

The ID assigned by Cloud Security Scanner to the host in the returned host information.

Index Integer 1

The index number of each record in the returned host information.

OS String windows

The operating system of the host in the returned domain information.

State String up

The status of the host in the returned domain information. Valid values:

  • up: indicates that the host is online.
  • down: indicates that the host is offline.
UpdatedAt Long 1581348080000

The time when the host list was updated.

RequestId String 7DC8391E-D5D8-4E00-A457-1F861F86E78A

The ID of the request.

TotalCount Integer 269

The total number of returned entries.

Examples

Sample requests

http(s)://[Endpoint]/?Action=ListUserHosts
&<Common request parameters>

Sample success responses

XML format

<ListUserHostsResponse>
  <TotalCount>1</TotalCount>
  <PageSize>10</PageSize>
  <RequestId>4A1AA1D7-F806-475B-8B9B-B9B0B889EA9F</RequestId>
  <CurrentPage>1</CurrentPage>
  <Records>
        <OS>Linux 3.10 - 4.11</OS>
        <State>up</State>
        <IP>1.1.1.1</IP>
        <Hostname></Hostname>
        <Index>1</Index>
        <Id>4741</Id>
        <UpdatedAt>1582625412000</UpdatedAt>
  </Records>
</ListUserHostsResponse>

JSON format

{
    "TotalCount": 1,
    "PageSize": 10,
    "RequestId": "4A1AA1D7-F806-475B-8B9B-B9B0B889EA9F",
    "CurrentPage": 1,
    "Records": [
        {
            "OS": "Linux 3.10 - 4.11",
            "State": "up",
            "IP": "1.1.1.1",
            "Hostname": "",
            "Index": 1,
            "Id": 4741,
            "UpdatedAt": 1582625412000
        }
    ]
}

Error codes

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