- Docs
- Techvia TMS overview
- API reference
- Facilities API reference
- Create a facility
Create a facility
POST /api/public/v1/facilities
Scope: directory.write. MCP tool: create_facility. Rules and edge cases: Facilities guide.
Request body
Section titled “Request body”Content type application/json. Limits and rules for each field are in the Facilities guide.
| Field | Type | Required | Notes |
|---|---|---|---|
name |
string | no | |
street |
string | no | |
city |
string | no | |
state |
string | no | |
zip |
string | no | |
country |
string | no | |
code |
string | no | |
confirmNew |
boolean | no | Default false |
Responses
Section titled “Responses”| Status | Meaning | Body |
|---|---|---|
201 |
Created | PublicFacility |
409 |
Conflict | ProblemDetails |
422 |
Unprocessable Entity | ProblemDetails |
201 body
Section titled “201 body”| Field | Type | Notes |
|---|---|---|
id |
string (uuid) | |
name |
string | |
code |
string | |
street |
string | |
city |
string | |
state |
string | |
zip |
string | |
timeZoneId |
string | |
status |
enum FacilityStatus | One of Active, Inactive |
rowVersion |
integer |
Errors are RFC 7807 problem details; see Errors.