Create a location
Create a new storage location, room, or department.
Authorization
bearerAuth AuthorizationBearer <token>
Bearer token authentication. Use your API key as the token. Obtain from your NextSDS team settings.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
curl -X POST "https://api.nextsds.com/v1/locations" \ -H "Content-Type: application/json" \ -d '{ "name": "Lab Storage Room A" }'{
"data": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"name": "Lab Storage Room A",
"type": "room",
"description": "string",
"ventilation": "natural",
"process_category": "production",
"tags": [
"string"
],
"inventory_count": 0,
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z"
}
}{
"type": "https://api.nextsds.com/errors/unauthorized",
"title": "Unauthorized",
"status": 401,
"detail": "Invalid or missing X-API-Key header"
}{
"type": "https://api.nextsds.com/errors/validation-error",
"title": "Validation Error",
"status": 422,
"detail": "One or more fields failed validation",
"errors": [
{
"field": "name",
"message": "Name is required"
}
]
}