PUT ./utilizatori/preferinte

It is used to setup user's preferences.

We can modify the following fields, that can be retrieved with GET./utilizatori/preferinte:

  • The student can not modify the following fields: prefNrRaportSMS, prefElevNotifSms;
  • As a parent, if the field prefNrRaportSMS will be updated, the fields: rapSmsChID, rapSmsChResponse will become mandatory.

    Exception: when the set number is the same with the number that was originally set for parent account and it's validated. The field rapSmsChID can be retrieved by using POST ./auth/challenge_phone;

  • The field prefAvatar can be retrieved by using POST ./fisiere/upload_tmp;
  • If the field prefAvatar will be modified for a student, the call to the endpoint will be made with the student user ID.

    Be aware: In this case the endpoint will have only the parameter uaID and prefAvatar; This will apply only for kindergarten and primary school students;

  • prefLangID will be the 2 letter ISO code: eo, en, nl, fr etc;
  • prefAvatar will be in the response only if the field has been modified;

PUT parameters

NameValue TypeValidationDetails
uaIDintRequiredUser ID
rapSmsChIDintRequiredChallenge ID
rapSmsChResponsestringRequiredChallenge response

Validation

Error FieldError CodeError Message
uaID101Invalid user ID.
prefAvatar102The file does not exist or it is not an image
rapSmsChID103Challenge failed.
prefLangID104Invalid language ID.

Output example

{
"$schema": "http://json-schema.org/draft-07/schema#",
"type": "object",
"required": ["result"],
"additionalProperties": false,
"properties": {
"result": { "type": "boolean" }
}
}