• Bare Metal Server

bms
  1. Help Center
  2. Bare Metal Server
  3. API Reference
  4. API
  5. BMS Status Management (Native OpenStack APIs)
  6. Querying BMS Metadata (Native OpenStack API)

Querying BMS Metadata (Native OpenStack API)

Function

This interface is used to query BMS metadata.

Constraints

Pagination query is not supported.

URI

GET /v2.1/{project_id}/servers/{server_id}/metadata

Table 1 lists the parameters.

Table 1 Parameter description

Parameter

Mandatory

Description

project_id

Yes

Specifies the project ID.

server_id

Yes

Specifies the BMS ID.

Request Message

N/A

Response Message

  • Response parameters

    Parameter

    Type

    Description

    metadata

    Dictionary data structure [1]

    Specifies the user-defined metadata key and value pair.

    [1] metadata field data structure description

    Parameter

    Type

    Description

    User-defined field key and value pair

    String

    Specifies the key and value pair of the metadata.

    The maximum size for each metadata key and value pair is 255 bytes.

  • Example response
    {
        "metadata": {
            "key": "value"
        }
    } 

Returned Values

See section Common Returned Values.