Dozor
User

Update the user's UI locale preference

Validates against the canonical `LOCALES` tuple. The session refresh + URL prefix swap happen client-side: on `204` the client calls `session.update({})` to force a JWT refresh, then `router.replace(pathname, { locale })` to swap the URL. All three steps are sequenced inside `useUpdateLocaleMutation.onSuccess`.

PATCH/api/user/locale

Validates against the canonical LOCALES tuple. The session refresh + URL prefix swap happen client-side: on 204 the client calls session.update({}) to force a JWT refresh, then router.replace(pathname, { locale }) to swap the URL. All three steps are sequenced inside useUpdateLocaleMutation.onSuccess.

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

curl -X PATCH "https://loading/api/user/locale" \  -H "Content-Type: application/json" \  -d '{    "locale": "uk"  }'
Empty
Empty
Empty