---
title: "Update writable profile fields."
method: PATCH
path: "/profile"
tags: ["profile"]
---

# Update writable profile fields.

`PATCH /profile`

## Request

- Base URL: `https://restivity.ai/api/v1`
- URL: `https://restivity.ai/api/v1/profile`
- Auth: OAuth 2 (authorization code, authorization URL `https://restivity.ai/oauth/authorize`, token URL `https://restivity.ai/api/oauth/token`, scopes: `profile:write`)

Strict whitelist. Unknown keys — including is_premium, subscription_*, firestore_id, and gamification counters — are rejected with 422 unprocessable.

## Request body

- ProfilePatchInput: Writable profile fields. Unknown keys (including is_premium, subscription_*, firestore_id, gamification counters) are rejected with 422 unprocessable.
  - `display_name` string
  - `bio` string
  - `occupation` string
  - `timezone` string
  - `language` string
  - `theme` 'light' | 'dark' | 'system'
  - `first_day_of_week` integer
  - `show_weekends` boolean
  - `notifications_enabled` boolean
  - `pomodoro_work_duration` integer: Work session length in minutes (10-240)
  - `pomodoro_short_break` integer: Short break length in minutes (1-60)
  - `pomodoro_long_break` integer: Long break length in minutes (1-120)
  - `pomodoro_long_break_interval` integer
  - `pomodoro_auto_start_breaks` boolean
  - `pomodoro_auto_start_work` boolean
  - `pomodoro_sound_enabled` boolean
  - `pomodoro_notifications_enabled` boolean
  - `pomodoro_volume` number

## Response `200`

The updated profile.

- Profile
  - `id` string, uuid, required
  - `display_name` string, required
  - `photo_url` string, nullable, required
  - `bio` string, required
  - `occupation` string, required
  - `theme` string, required
  - `language` string, required
  - `timezone` string, required
  - `first_day_of_week` integer, required
  - `show_weekends` boolean, required
  - `weekend_days` integer[], required
  - `notifications_enabled` boolean, required
  - `preferred_work_method` string, required
  - `pomodoro_work_duration` integer, required
  - `pomodoro_short_break` integer, required
  - `pomodoro_long_break` integer, required
  - `pomodoro_long_break_interval` integer, required
  - `pomodoro_preferred_break` string, required
  - `pomodoro_auto_start_breaks` boolean, required
  - `pomodoro_auto_start_work` boolean, required
  - `pomodoro_sound_enabled` boolean, required
  - `pomodoro_notifications_enabled` boolean, required
  - `pomodoro_volume` number, required
  - `timer_sound` string, required
  - `focus_music` string, required
  - `total_focus_time` integer, required
  - `tasks_completed` integer, required: Tasks this user has completed: the tasks they moved to completed (still completed, not in the Trash) plus the reminder occurrences they completed. Counted on every read.
  - `current_streak` integer, required
  - `longest_streak` integer, required
  - `level` integer, required
  - `points` integer, required
  - `is_premium` boolean, required
  - `created_at` string
  - `locale` string, required
  - `pomodoro_preferences` PomodoroPreferences, required
    - `work_duration_seconds` integer, required
    - `short_break_seconds` integer, required
    - `long_break_seconds` integer, required
    - `long_break_every_n_sessions` integer, required
  - `default_view` 'today' | 'inbox' | 'project', required

## Other responses

- `400`: Invalid request shape.
- `401`: Missing or invalid access token.
- `403`: Token lacks the required scope.
- `422`: Request body failed schema validation.
- `429`: Rate-limit exceeded for this tier.

---

[API](https://skmtc.dev/restivity/apis/restivity-rest-api.md) · [All operations](https://skmtc.dev/restivity/apis/restivity-rest-api/llms.txt) · [OpenAPI document](https://skmtc.dev/restivity/apis/restivity-rest-api/revisions/5764e41ebb3a?raw)
