跳到导航

创建资产

Create a bookable asset, such as a room or a piece of equipment.

请求头

xi-api-keystring可选
xi-workspace-idstring必需

经销商 API 密钥操作的客户工作区。

请求

This endpoint expects an object.
namestring必需

Internal/admin name of the asset, shown in the dashboard and owner notifications.

groupslist of objects可选

此项目的分组成员关系。每个条目包含分组标签及该项目在组内从 0 开始的排名。

ungrouped_rankinteger or null可选>=0

无分组项目中的显示位置;null 排在最后。可通过重新排序端点更改。

descriptionstring可选
Description of the asset.
is_activeboolean可选默认为 true

该资产是否可预约。停用资产会保留预约历史。

available_hoursobject or null可选

Custom availability hours for this asset. Null means follow the assigned location’s operating_hours (requires location_id).

photo_urlstring or null可选格式: "uri"1-2083 characters

资产照片的 URL。

location_idstring or null可选

Location this asset belongs to; empty means available at all locations.

customer_facing_namestring可选

Optional public-facing label. When empty, name is shown to customers too. name stays the internal/admin label used in the dashboard and business-owner notifications.

响应

成功响应

namestring

Internal/admin name of the asset, shown in the dashboard and owner notifications.

idstring

资产的 ID。

groupslist of objects可选

此项目的分组成员关系。每个条目包含分组标签及该项目在组内从 0 开始的排名。

ungrouped_rankinteger or null可选>=0

无分组项目中的显示位置;null 排在最后。可通过重新排序端点更改。

descriptionstring可选
Description of the asset.
is_activeboolean可选默认为 true

该资产是否可预约。停用资产会保留预约历史。

available_hoursobject or null可选

Custom availability hours for this asset. Null means follow the assigned location’s operating_hours (requires location_id).

photo_urlstring or null可选格式: "uri"1-2083 characters

资产照片的 URL。

location_idstring or null可选

Location this asset belongs to; empty means available at all locations.

customer_facing_namestring可选

Optional public-facing label. When empty, name is shown to customers too. name stays the internal/admin label used in the dashboard and business-owner notifications.

created_at_unixinteger可选

创建时间,以秒为单位的 Unix 时间戳。

updated_at_unixinteger可选

上次更新时间,以秒为单位的 Unix 时间戳。

错误

422
Unprocessable Entity Error