Add devices

post/devices/v2beta1/devices

Add one or more devices to a workspace. This API endpoint provides an asynchronous response and returns 202 Accepted if basic input validations are successful. The location header in the response provides the URI to invoke to fetch the progress of the device addition task. For details about the status fetch URL, refer to the API Get progress or status of async operations in devices.

NOTE: You need edit permissions for the Devices and Subscription service to call this API endpoint.

Rate limits are enforced, and 25 requests per minute are supported per workspace. The API endpoint returns 429 if this threshold is breached.

SecurityBearer
Request
query Parameters
dry-run
boolean
Default: false

The dry-run query parameter is used to perform the resource update operation (POST, PUT, PATCH, DELETE) and return a response as if the operation had completed, but without actually creating, updating, or deleting the resource. This allows you to test if the request would succeed before making the change. If set to true, the request is validated but not executed.

Request Body schema: application/json
required

Accepts a maximum of five devices per request, combining the count of network, compute, and storage devices.

deviceType
required
string

The type of device.

Enum: "COMPUTE" "NETWORK" … 1 more
serialNumber
required
string

The serial number of the device.

object

The location ID of the device.

macAddress
string

The media access control (MAC) address of the device. This is required for claiming NETWORK devices.

partNumber
string

The part number of the device. This is required for claiming COMPUTE or STORAGE devices.

object
Responses
202

Request accepted

400

Bad request

401

Unauthorized request

403

The operation is forbidden

422

Validation error

429

Too many requests

500

Internal server error

Request samples
application/json
{
  • "serialNumber": "SN12345678",
  • "macAddress": "00:1B:44:11:3A:B7",
  • "deviceType": "NETWORK",
  • "tags": {
    },
  • "location": {
    }
}
Response samples
application/json
{
  • "errorCode": "HPE_GL_ERROR_BAD_REQUEST",
  • "message": "Bad Request",
  • "debugId": "abbeeb59-12cb-49a3-9ce5-55edba12213f",
  • "httpStatusCode": 400,
  • "errorDetails": [
    ]
}