---
title: "POST /locations"
method: POST
path: "/locations"
tags: ["locations"]
---

# POST /locations

`POST /locations`

Create a location

## Request body

- PostLocations — Create a location
  - `name` string, required
  - `parent_location_id` integer

## Response `201`

Create a location

- EndpointsLocation — Endpoints_Location model
  - `data` LocationEntity
    - `id` integer
    - `name` string
    - `parent_location_id` integer
    - `sub_locations` LocationEntity[]

## Other responses

- `400` — validation_error
- `401` — authentication_error
- `403` — authorization_error
- `404` — not_found_error
- `422` — validation_error
- `500` — internal_server_error

---

[API](https://skmtc.net/propstack/apis/propstack-api-v2-beta.md) · [All operations](https://skmtc.net/propstack/apis/propstack-api-v2-beta/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/propstack/propstack-api-v2-beta/revisions/ae1e0fe6da1a/schema)
