Updated on 2025-05-29 GMT+08:00

Querying Physical Device Details

Function

Query physical device details.

SLA Item

Definition

Request success rate

≥ 99%

Availability

Tier 2

Data consistency

Strongly consistent

Throughput

60 times/minute

TP50 request latency

200 ms

TP99.9 request latency

300 ms

Precautions

None

Calling Method

GET

URI

/rest/dataapi/homs/open-api/v1/DeviceAsset/info

Path parameters

None

Query parameters

Parameter

Mandatory

Type

Value Range

Description

device_type

No

String

None

Device type, such as server, switch, firewall, and router.

page_size

Yes

int

0~1000

Page size.

offset_value

Yes

int

None

Start value for the query.

Request

  • Request header parameters

    Parameter

    Mandatory

    Type

    Value Range

    Description

    X-APIG-Appcode

    Yes

    String

    None

    AppCode allocated by SRE

    x-auth-token

    Yes

    String

    None

    IAM authentication token for the calling party APIG

    x-hcso-domainid

    Yes (HCS Online scenario)

    No (other scenarios)

    String

    None

    ID of the accessed tenant.

    x-hcso-appcode

    Yes

    String

    None

    AppCode allocated by SRE

  • Request body parameters

    None

  • Sample request
    GET /rest/dataapi/homs/open-api/v1/DeviceAsset/info HTTP/1.1 
    Host: example.com 
    Content-Type: application/json 
    Accept: application/json
    X-APIG-Appcode: xxx 
    x-auth-token: xxx 
    x-hcso-domainid: xxx
    x-hcso-appcode: xxx

Response

  • Response parameters
    • Response status code 200: The Data object is returned. The Data object has the following attributes.

      Parameter

      Mandatory

      Type

      Value Range

      Description

      total

      Yes

      int32

      None

      Total number of data records.

      list

      Yes

      List<Item>

      None

      Process object information.

      The Item object has the following attributes.

      Parameter

      Mandatory

      Type

      Value Range

      Description

      device_id

      Yes

      String

      None

      Device ID.

      name

      Yes

      String

      None

      Device name.

      device_type

      Yes

      int32

      None

      Device type.

      running_status

      Yes

      String

      None

      Device running status.

      model

      Yes

      String

      None

      Device specifications.

      management_ip

      Yes

      String

      None

      IP address of the device management port.

      os

      Yes

      String

      None

      Operating system of a device.

      region

      Yes

      String

      None

      Region code.

  • Sample response
    HTTP/1.1 200 OK
    Date:Tue,18 Jul 2023 09:58:01 GMT
    Server: example.com
    Content-Type: application/json;charset=UTF8 
    { 
        "total": "33", 
        "list": [ 
                 { 
    "device_id": "Physical device ID",
    "name": "Device name",
    "device_type": "Device type",
    "running_status": "running status",
    "model": "Device specifications",
    "management_ip": "IP address of the device management port",
    "os": "Operating system of a device",
                 "region": "cn-north-1" 
                  } 
                 ] 
    }

Status Codes

Status Code

Description

200

Operation successful.

400

Parameter error.

401

Token authentication failed.

403

Authentication failed.

404

REST API not found.

Operation Severity

Minor