Docs

Create Resource

POST /resources

POST/resources

Required Tokens

FieldTypeRequiredDescription
BearerAuthorization: Bearer <api-key>OptionalYour API key. Pass it as the Bearer token on every request.
Organization tokenx-Organization-TokenOptionalRun **Authorize Organization** in the Authorization folder.

Creates one inventory resource. The variant's axis values are written onto the resource from the variant.

Requires ResourceInventory.Edit permission.

Request Body

FieldTypeRequiredDescription
typestringRequired`Asset` or `Crew`.
resourceTypeIdGuidRequiredThe type.
resourceVariantIdGuidRequiredA live variant of the type.
namestringRequiredName.
labelstringOptionalLabel.
identifierstringOptionalSerial or asset tag.
quantityint?OptionalPooled and Expendable stock.
crewIdGuid?OptionalFor Crew.
settlementstringOptional`OwnedCost` or `Invoiceable`.
rateCardIdGuid?OptionalOne of the type's cards.
attributeValuesarrayOptional`{ resourceAttributeId, value }`. A required Inventory-active attribute (not Checkbox) can't be left blank.

Response

201 Created with the new resource's id as a bare Guid.

Error Codes

HTTP StatusDescription
400Invalid arguments, or a required Inventory attribute left blank ("A value is required for {names}.").
404Type, variant or card not found.