---
title: "POST /services/coordinate/locations/{locationId}/subscriptions"
method: POST
path: "/services/coordinate/locations/{locationId}/subscriptions"
tags: ["Coordinate"]
---

# POST /services/coordinate/locations/{locationId}/subscriptions

`POST /services/coordinate/locations/{locationId}/subscriptions`

## Request

- Base URL: `https://api.smartthings.com/v1`
- URL: `https://api.smartthings.com/v1/services/coordinate/locations/{locationId}/subscriptions`
- Auth: OAuth 2
  - Implicit: `https://auth-global.api.smartthings.com`
  - Scopes: `r:locations:*`, `mobile`
- TypeScript: <https://skmtc.dev/smartthings/apis/smartthings-api/docs/services/coordinate/locations/:locationId/subscriptions/post.ts> (a function with typed inputs; its response is checked against the schema)

Create a new subscription

## Path parameters

- `locationId` string, required

## Headers

- `Authorization` string, string, required

## Request body

- ServiceSubscriptionBody
  - `capabilities` string[], required: capability name(s). NOTE: alert cannot be combined with other capabilities
  - `isaId` string, required: InstalledApp ID
  - `postalCode` string: Postal code (This ID is only supported in "alert" capability)
  - `type` string: DIRECT or EXECUTION delivery, default to DIRECT
  - `predicate` string: JEXL formatted expression. See https://commons.apache.org/proper/commons-jexl/reference/syntax.html

## Response `200`

Success

- ServiceNewSubscription
  - `locationId` string, required: location ID
  - `subscriptionId` string: subscription ID created

## Other responses

- `400`: Bad request
- `401`: Unauthorized
- `404`: Not found
- `default`: Unexpected error

---

[API](https://skmtc.dev/smartthings/apis/smartthings-api.md) - [All operations](https://skmtc.dev/smartthings/apis/smartthings-api/llms.txt) - [OpenAPI document](https://skmtc.dev/smartthings/apis/smartthings-api/revisions/2788a4236800?raw)
