---
title: "Create box by device"
method: POST
path: "/devices/{deviceId}/box"
tags: ["Device"]
---

# Create box by device

`POST /devices/{deviceId}/box`

Create a new box using a physical device

## Path parameters

- `deviceId` string, required

## Request body

- DeviceToBox
  - `force` boolean — If true, the device will be forcibly created as a new Box, which will forcibly terminate any existing box that is currently using this device. If false, an error will be thrown with HTTP 423 status code when the device is already occupied by a box.

## Response `201`

- string

---

[API](https://skmtc.dev/babelcloud/apis/gbox-open-api.md) · [All operations](https://skmtc.dev/babelcloud/apis/gbox-open-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/babelcloud/gbox-open-api/revisions/d655577fa915/schema)
