Skip to content

Actualizează setare

Actualizează setările utilizatorului.

Endpoint

http
PATCH /api/v1/user/settings

Parametri

Parametri body

ParametruTipObligatoriuDescriere
namestringyesNumele atributului pe care îl actualizezi. Atribute permise: - color (format HEX) - first_name - last_name - address - state - city - postal_code - country (format ISO 3166-1 alpha-2) - phone_number - timezone (1.0, 2.0, 3.0...) - emoji_type (twemoji
valuestringintegeryes

Exemplu de cerere

sh
curl --location --request PATCH 'https://files.ro/api/v1/user/settings' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer {token}' \
--data-raw '{
  "name": "first_name",
  "value": "Jane"
}'

Răspuns

json
{
  "type": "success",
  "message": "The first_name was successfully updated."
}
json
{
  "type": "error",
  "message": "You typed the invalid 'name' name parameter."
}
json
{
  "type": "error",
  "message": "Unsupported language locale 'ro'."
}