---
title: "Get Preference by ID"
method: GET
path: "/devicepreferences/{preferenceId}"
tags: ["Preferences"]
---

# Get Preference by ID

`GET /devicepreferences/{preferenceId}`

## Request

- Base URL: `https://api.smartthings.com/v1`
- URL: `https://api.smartthings.com/v1/devicepreferences/{preferenceId}`
- Auth: OAuth 2
  - Implicit: `https://auth-global.api.smartthings.com`
  - Scopes: `r:customcapabilities:*`
- TypeScript: <https://skmtc.dev/smartthings/apis/smartthings-api/docs/devicepreferences/:preferenceId/get.ts> (a function with typed inputs; its response is checked against the schema)

Get a preference by preference ID.

## Response `200`

successful return of preference

- PreferenceResponse
  - `preferenceId` string: The ID of the preference
  - `name` string: An alphanumeric English language name for this preference.
  - `title` string, required: A short description for this preference.
  - `description` string: A long description for this preference.
  - `required` boolean: A flag describing whether this property is required or not.
  - `explicit` boolean: A flag describing whether this preference is explicit, or inline.
  - `preferenceType` 'integer' | 'number' | 'boolean' | 'string' | 'enumeration', required: The type of preference this is.

## Other responses

- `401`: Unauthorized
- `403`: Forbidden
- `429`: Too many requests
- `default`: Unexpected error

## Changes

- **2022-12-19** `adcacfc2749d`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/smartthings/apis/smartthings-api/changes/devicepreferences/:preferenceId/get.md)

---

[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)
