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

# POST /locations

`POST /locations`

This endpoint allows you to create a new location. Support for Location-based camera grouping is only available in the professional and enterprise editions.

## Request body

- LocationCreate
  - `id` string
  - `name` string, required
  - `parentId` string — Unique identifier of this location's parent location in the hierarchy
  - `isDefault` boolean — Specifies if a new device should be automatically assigned to this location if not supplied
  - `address` LocationAddress
    - `country` string
    - `region` string
    - `city` string
    - `streetAddress` string
    - `streetAddress2` string
    - `postalCode` string
  - `notes` string — Description for the location
  - `geometry` object, nullable — GeoJSON structure to store polygon for the specific location. Currently the only supported geometry type is MultiPolygon, but in the future more GeoJSON schemas might be supported, so clients should be able to handle unknown schemas. This field must be in the standard GeoJSON format, as described in https://datatracker.ietf.org/doc/html/rfc7946 Please read https://datatracker.ietf.org/doc/html/rfc7946 for more information about the GeoJSON standard.
    - `type` 'MultiPolygon', required
    - `coordinates` array[], required
      - array[]
        - array[]
          - number[]
    - `bbox` number[]
  - `childLocationCount` integer — The total count of direct children of the location
  - `effectivePermissions` EffectiveLocationPermissions
    - `read` boolean
    - `delete` boolean
    - `edit` boolean
  - `resourceCounts` ResourceCounts1 — Count of resources.
    - `cameras` integer
    - `bridges` integer
    - `speakers` integer
    - `users` integer
    - `multiCameras` integer
  - `resourceStatusCounts` ResourceStatusCounts1 — Count of resources by status.
    - `cameras` CameraStatusCounts
      - `online` integer
      - `deviceOffline` integer
      - `off` integer
      - `bridgeOffline` integer
      - `invalidCredentials` integer
      - `error` integer
      - `unknown` integer
    - `bridges` BridgeStatusCounts
      - `online` integer
      - `deviceOffline` integer
      - `unknown` integer
    - `users` UserStatusCounts
      - `active` integer
      - `blocked` integer
      - `pending` integer
    - `multiCameras` CameraStatusCounts
      - `online` integer
      - `deviceOffline` integer
      - `off` integer
      - `bridgeOffline` integer
      - `invalidCredentials` integer
      - `error` integer
      - `unknown` integer
  - `resourceStatusV2Counts` ResourceStatusV2Counts1 — Count of resources by cloud connection status and edge-reported device status.
    - `cameras` CameraStatusV2Counts
      - `cloudConnectionStatus` CloudConnectionStatusCounts
        - `connected` integer
        - `disconnected` integer
      - `edgeReportedDeviceStatus` EdgeReportedDeviceStatusCounts
        - `operational` integer
        - `disabled` integer
        - `unreachable` integer
        - `error` integer
        - `unknown` integer
        - `initializing` integer
    - `bridges` BridgeStatusV2Counts
      - `cloudConnectionStatus` CloudConnectionStatusCounts
        - `connected` integer
        - `disconnected` integer
      - `edgeReportedDeviceStatus` EdgeReportedDeviceStatusCounts
        - `operational` integer
        - `disabled` integer
        - `unreachable` integer
        - `error` integer
        - `unknown` integer
        - `initializing` integer
    - `users` UserStatusCounts
      - `active` integer
      - `blocked` integer
      - `pending` integer
    - `multiCameras` CameraStatusV2Counts
      - `cloudConnectionStatus` CloudConnectionStatusCounts
        - `connected` integer
        - `disconnected` integer
      - `edgeReportedDeviceStatus` EdgeReportedDeviceStatusCounts
        - `operational` integer
        - `disabled` integer
        - `unreachable` integer
        - `error` integer
        - `unknown` integer
        - `initializing` integer

## Response `201`

Location created

- BasicLocationResponse
  - `id` string
  - `name` string
  - `parentId` string — Unique identifier of this location's parent location in the hierarchy
  - `isDefault` boolean — Specifies if a new device should be automatically assigned to this location if not supplied

## Other responses

- `400` — The supplied object is invalid. Error detail will contain the validation error.
- `401` — You are not authenticated. Please authenticate and try again.
- `403` — You have no permission to access the specified resource.
- `404` — Referenced resource could not be found.
- `500` — Something went wrong in the server. Please try again.

---

[API](https://skmtc.net/eagleeyenetworks/apis/devices.md) · [All operations](https://skmtc.net/eagleeyenetworks/apis/devices/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/eagleeyenetworks/devices/revisions/df57313de545/schema)
