---
title: "SetPreference"
method: POST
path: "/gitpod.v1.UserService/SetPreference"
tags: ["gitpod.v1.UserService"]
---

# SetPreference

`POST /gitpod.v1.UserService/SetPreference`

SetPreference upserts user preference settings for the user

## Request body

- GitpodV1SetPreferenceRequest
  - `key` string
  - `value` string — omitting value field will cause an error due to min_len validation, to unset a preference use DeletePreference instead

## Response `200`

Success

- GitpodV1SetPreferenceResponse

## Other responses

- `default` — Error

---

[API](https://skmtc.dev/gitpod-io/apis/gitpod-v1.md) · [All operations](https://skmtc.dev/gitpod-io/apis/gitpod-v1/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/gitpod-io/gitpod-v1/revisions/27f7bd641de1/schema)
