> For the complete documentation index, see [llms.txt](https://navixy.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://navixy.com/docs/navixy-api/panel-api/resources/user.md).

# User

In the Navixy Admin Panel, a User refers to the accounts of Organizations or Individuals who are customers of the Dealer (or Sub Dealer). For example, an organization 'ABC Inc.' can be a User with the type "legal\_entity," and John Doe can be a User with the type "individual."

> User accounts may have additional sub-accounts, commonly referred to as 'sub-users,' allowing larger organizations to grant access to multiple employees.

This page describes the User object and the API actions that can be performed with it within the Admin Panel.

## User Object Structure

## The User object

```json
{"openapi":"3.1.0","info":{"title":"Navixy Admin Panel API","version":"1.2.0"},"components":{"schemas":{"User":{"type":"object","readOnly":true,"description":"An end user of the dealer service. The response form is flat: every legal field is present regardless of `legal_type`, with empty strings where a field does not apply. The request form used by create and update is a discriminated union on `legal_type` instead.","properties":{"id":{"type":"integer","description":"User ID."},"dealer_id":{"type":"integer","description":"ID of the owning dealer."},"login":{"type":"string","description":"Login, an email address."},"activated":{"type":"boolean","description":"`true` once the account has been activated."},"verified":{"type":"boolean","description":"`true` if the email address has been verified."},"phone_verified":{"type":"boolean","description":"`true` if the phone number has been verified."},"legal_type":{"type":"string","description":"Legal status, which determines which legal fields below are meaningful.","enum":["individual","legal_entity","sole_trader"]},"first_name":{"type":"string","description":"First name."},"middle_name":{"type":"string","description":"Middle name."},"last_name":{"type":"string","description":"Last name."},"phone":{"type":"string","description":"Phone number."},"post_country":{"type":"string","description":"Postal address country."},"post_index":{"type":"string","description":"Postal code."},"post_region":{"type":"string","description":"Postal address region."},"post_city":{"type":"string","description":"Postal address city."},"post_street_address":{"type":"string","description":"Postal street address."},"registered_country":{"type":"string","description":"Registered address country. Meaningful for `legal_entity` and `sole_trader`."},"registered_index":{"type":"string","description":"Registered postal code. Meaningful for `legal_entity` and `sole_trader`."},"registered_region":{"type":"string","description":"Registered address region. Meaningful for `legal_entity` and `sole_trader`."},"registered_city":{"type":"string","description":"Registered address city. Meaningful for `legal_entity` and `sole_trader`."},"registered_street_address":{"type":"string","description":"Registered street address. Meaningful for `legal_entity` and `sole_trader`."},"legal_name":{"type":"string","description":"Legal company name. Meaningful for `legal_entity`."},"tin":{"type":"string","description":"Taxpayer identification number. Meaningful for `legal_entity` and `sole_trader`."},"iec":{"type":"string","description":"Interbranch enterprise code. Meaningful for `legal_entity`."},"state_reg_num":{"type":"string","description":"State registration number. Meaningful for `legal_entity` and `sole_trader`."},"okpo_code":{"type":"string","description":"OKPO classifier code. Digits only when present. Meaningful for `legal_entity` and `sole_trader`."},"balance":{"type":"number","description":"Current account balance."},"bonus":{"type":"number","description":"Current bonus balance."},"trackers_count":{"type":"integer","description":"Number of trackers the user owns."},"menu_preset_id":{"type":["integer","null"],"description":"ID of the menu preset assigned to this user."},"mfa_allowed":{"type":"boolean","description":"`true` if multi-factor authentication is permitted for this user."},"creation_date":{"type":"string","description":"When the account was created, as `YYYY-MM-DD HH:MM:SS`."},"comment":{"type":"string","description":"Free-text comment.","maxLength":255}}}}}}
```

The read operations return this flat form, with every legal field present regardless of `legal_type` and empty strings where a field does not apply.

The create and update operations take a different and stricter shape that varies by `legal_type`. It is documented as `UserEditForm` on those two operations below, and the three variants are cumulative: a sole trader is an individual plus registration details, and a legal entity is a sole trader plus a company name and interbranch code. The legal variants also tighten the postal fields, which may be empty for an individual but not for a sole trader or legal entity.

## Discount Object Structure

## The UserDiscount object

```json
{"openapi":"3.1.0","info":{"title":"Navixy Admin Panel API","version":"1.2.0"},"components":{"schemas":{"UserDiscount":{"type":"object","description":"A discount applied to a user.","properties":{"percent":{"type":"number","description":"Discount percentage."},"end_date":{"type":["string","null"],"description":"Date the discount expires.","format":"date"},"device_limit":{"type":["integer","null"],"description":"Minimum devices required for the discount to apply."}}}}}}
```

## API actions

API path: `panel/user`.

***

*required permissions*: `users: "create"`.

## Create user

> Create an end user.\
> \
> The profile is passed as a \`user\` object whose shape depends on \`legal\_type\`. Alongside it, \`password\`, \`locale\`, and \`time\_zone\` are all mandatory and sit at the top level rather than inside \`user\`.\
> \
> A login already in use fails with error code 206.

```json
{"openapi":"3.1.0","info":{"title":"Navixy Admin Panel API","version":"1.2.0"},"tags":[{"name":"User","description":"End users belonging to the dealer: their profiles, sessions, balance transactions, menu presets, and multi-factor authentication settings. All resources under the /panel/user/ path."}],"servers":[{"url":"https://api.eu.navixy.com/v2","description":"Navixy production server on European platform"},{"url":"https://api.us.navixy.com/v2","description":"Navixy production server on American platform"},{"url":"https://api.me.navixy.com/v2","description":"Navixy production server on Middle East platform"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"type":"apiKey","description":"Enter the panel session hash with the \"NVX \" prefix, e.g. \"NVX fa7bf873fab9333144e171372a321b06\". Obtain the hash from the accountAuth operation.","name":"Authorization","in":"header"}},"schemas":{"UserEditForm":{"description":"A user to create or update. The shape depends on `legal_type`, which selects one of three variants.\n\nThe three are cumulative: a sole trader is an individual plus registration details, and a legal entity is a sole trader plus a company name and interbranch code. The legal variants also tighten the postal fields, which may be empty for an individual but not for a sole trader or legal entity.\n\nOn update, `id` and `activated` are both mandatory.","oneOf":[{"$ref":"#/components/schemas/UserIndividual"},{"$ref":"#/components/schemas/UserSoleTrader"},{"$ref":"#/components/schemas/UserLegalEntity"}],"discriminator":{"propertyName":"legal_type","mapping":{"individual":"#/components/schemas/UserIndividual","sole_trader":"#/components/schemas/UserSoleTrader","legal_entity":"#/components/schemas/UserLegalEntity"}}},"UserIndividual":{"type":"object","title":"individual","description":"A private individual. Postal fields are mandatory but may be empty strings.","required":["legal_type","login","first_name","middle_name","last_name","post_city","phone","post_country","post_region","post_city","post_street_address","post_index"],"properties":{"legal_type":{"type":"string","description":"Legal status. Determines which shape this object takes.","enum":["individual"]},"login":{"type":"string","description":"Login, which is an email address. Must be unique across the platform."},"first_name":{"type":"string","description":"First name. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"middle_name":{"type":"string","description":"Middle name. Required but may be empty. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"last_name":{"type":"string","description":"Last name. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"phone":{"type":"string","description":"Phone number, digits only. Required but may be empty.","pattern":"[0-9]*","maxLength":15},"birth_date":{"type":["string","null"],"description":"Date of birth. Not returned by the read operations.","format":"date"},"passport":{"type":["string","null"],"description":"Passport details. Not returned by the read operations."},"menu_preset_id":{"type":["integer","null"],"description":"ID of the menu preset to assign. See the menu preset operations."},"activated":{"type":"boolean","description":"Whether the account is activated. Mandatory on update."},"post_country":{"type":"string","description":"Postal address country. Required but may be empty. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"post_region":{"type":"string","description":"Postal address region. Required but may be empty. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"post_city":{"type":"string","description":"Postal address city. Required but may be empty. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"post_street_address":{"type":"string","description":"Postal street address. Required but may be empty. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":200},"post_index":{"type":"string","description":"Postal code. Validated against the country format. Required but may be empty."}}},"UserSoleTrader":{"type":"object","title":"sole_trader","description":"A sole trader. Adds registration details, and tightens the postal fields so they may no longer be empty.","required":["legal_type","login","first_name","middle_name","last_name","post_city","phone","post_country","post_region","post_city","post_street_address","post_index","registered_country","registered_region","registered_city","registered_street_address","registered_index","tin"],"properties":{"legal_type":{"type":"string","description":"Legal status. Determines which shape this object takes.","enum":["sole_trader"]},"login":{"type":"string","description":"Login, which is an email address. Must be unique across the platform."},"first_name":{"type":"string","description":"First name. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"middle_name":{"type":"string","description":"Middle name. Required but may be empty. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"last_name":{"type":"string","description":"Last name. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"phone":{"type":"string","description":"Phone number, digits only. Required but may be empty.","pattern":"[0-9]*","maxLength":15},"birth_date":{"type":["string","null"],"description":"Date of birth. Not returned by the read operations.","format":"date"},"passport":{"type":["string","null"],"description":"Passport details. Not returned by the read operations."},"menu_preset_id":{"type":["integer","null"],"description":"ID of the menu preset to assign. See the menu preset operations."},"activated":{"type":"boolean","description":"Whether the account is activated. Mandatory on update."},"post_country":{"type":"string","description":"Postal address country. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"post_region":{"type":"string","description":"Postal address region. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"post_city":{"type":"string","description":"Postal address city. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"post_street_address":{"type":"string","description":"Postal street address. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":200,"minLength":1},"post_index":{"type":"string","description":"Postal code. Validated against the country format. Must not be blank.","minLength":1},"registered_country":{"type":"string","description":"Registered address country. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"registered_region":{"type":"string","description":"Registered address region. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"registered_city":{"type":"string","description":"Registered address city. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"registered_street_address":{"type":"string","description":"Registered street address. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":200,"minLength":1},"registered_index":{"type":"string","description":"Registered postal code. Validated against the country format. Must not be blank.","minLength":1},"tin":{"type":"string","description":"Taxpayer identification number. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":255},"state_reg_num":{"type":"string","description":"State registration number. Digits only when not empty.","maxLength":15,"pattern":"\\d+|(^$)"},"okpo_code":{"type":"string","description":"OKPO classifier code. When not empty, must be 8 or 10 digits.","pattern":"\\d{8,10}|(^$)"}}},"UserLegalEntity":{"type":"object","title":"legal_entity","description":"A legal entity. Adds the company name and interbranch code on top of the sole trader fields.","required":["legal_type","login","first_name","middle_name","last_name","post_city","phone","post_country","post_region","post_city","post_street_address","post_index","registered_country","registered_region","registered_city","registered_street_address","registered_index","tin","legal_name","iec"],"properties":{"legal_type":{"type":"string","description":"Legal status. Determines which shape this object takes.","enum":["legal_entity"]},"login":{"type":"string","description":"Login, which is an email address. Must be unique across the platform."},"first_name":{"type":"string","description":"First name. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"middle_name":{"type":"string","description":"Middle name. Required but may be empty. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"last_name":{"type":"string","description":"Last name. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"phone":{"type":"string","description":"Phone number, digits only. Required but may be empty.","pattern":"[0-9]*","maxLength":15},"birth_date":{"type":["string","null"],"description":"Date of birth. Not returned by the read operations.","format":"date"},"passport":{"type":["string","null"],"description":"Passport details. Not returned by the read operations."},"menu_preset_id":{"type":["integer","null"],"description":"ID of the menu preset to assign. See the menu preset operations."},"activated":{"type":"boolean","description":"Whether the account is activated. Mandatory on update."},"post_country":{"type":"string","description":"Postal address country. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"post_region":{"type":"string","description":"Postal address region. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"post_city":{"type":"string","description":"Postal address city. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"post_street_address":{"type":"string","description":"Postal street address. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":200,"minLength":1},"post_index":{"type":"string","description":"Postal code. Validated against the country format. Must not be blank.","minLength":1},"registered_country":{"type":"string","description":"Registered address country. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"registered_region":{"type":"string","description":"Registered address region. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"registered_city":{"type":"string","description":"Registered address city. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"registered_street_address":{"type":"string","description":"Registered street address. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":200,"minLength":1},"registered_index":{"type":"string","description":"Registered postal code. Validated against the country format. Must not be blank.","minLength":1},"tin":{"type":"string","description":"Taxpayer identification number. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":255},"state_reg_num":{"type":"string","description":"State registration number. Digits only when not empty.","maxLength":15,"pattern":"\\d+|(^$)"},"okpo_code":{"type":"string","description":"OKPO classifier code. When not empty, must be 8 or 10 digits.","pattern":"\\d{8,10}|(^$)"},"legal_name":{"type":"string","description":"Legal company name. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":255,"minLength":1},"iec":{"type":"string","description":"Interbranch enterprise code. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":255}}},"UserDiscount":{"type":"object","description":"A discount applied to a user.","properties":{"percent":{"type":"number","description":"Discount percentage."},"end_date":{"type":["string","null"],"description":"Date the discount expires.","format":"date"},"device_limit":{"type":["integer","null"],"description":"Minimum devices required for the discount to apply."}}}},"responses":{"ResponseError":{"description":"Error response object","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Always false."},"status":{"type":"object","description":"Error status. Present only when an error occurred.","properties":{"code":{"type":"integer","description":"An error code in this API (not a HTTP code)"},"description":{"type":"string","description":"An error description"}}},"errors":{"type":"array","description":"Per-parameter detail, returned with validation failures such as error code 7.","items":{"type":"object","properties":{"parameter":{"type":"string","description":"Name of the parameter that failed validation."},"error":{"type":"string","description":"What was wrong with it."}}}}}}}}}}},"paths":{"/panel/user/create":{"post":{"tags":["User"],"summary":"Create user","operationId":"userCreate","description":"Create an end user.\n\nThe profile is passed as a `user` object whose shape depends on `legal_type`. Alongside it, `password`, `locale`, and `time_zone` are all mandatory and sit at the top level rather than inside `user`.\n\nA login already in use fails with error code 206.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["user","password","locale","time_zone"],"properties":{"user":{"$ref":"#/components/schemas/UserEditForm"},"password":{"type":"string","format":"password","description":"Initial password. Must satisfy the password policy of the dealer."},"locale":{"type":"string","description":"Locale for the new user."},"time_zone":{"type":"string","description":"Time zone ID for the new user. See the timezone list operation."},"discount":{"anyOf":[{"$ref":"#/components/schemas/UserDiscount"},{"type":"null"}],"description":"Optional discount to apply to this user."},"default_tariff_id":{"type":["integer","null"],"description":"Optional. Plan the user is placed on. Must exist and belong to the dealer."},"comment":{"type":"string","description":"Optional free-text comment.","maxLength":255}}}}}},"responses":{"200":{"description":"User created","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","readOnly":true},"id":{"type":"integer","description":"ID of the created user.","readOnly":true}}}}}},"400":{"description":"Bad request. The response body carries the API-level error code in `status.code`. Validation failures also include an `errors` array.","$ref":"#/components/responses/ResponseError"},"403":{"description":"Operation not permitted, error code 13: the session lacks the required permission.","$ref":"#/components/responses/ResponseError"},"default":{"$ref":"#/components/responses/ResponseError"}}}}}}
```

#### Errors

* 206 - Login already in use - if this email is already registered.

***

*required permissions*: `users: "read"`.

## Read user

> Read a single end user.\
> \
> The response carries five sibling keys rather than a single \`value\`: the user profile, any discount, the default plan ID of the dealer, the block parameters of the user, and the dealer-level MFA settings.\
> \
> A sub-user, or a user belonging to another dealer, returns error code 201 exactly as a missing one does.

```json
{"openapi":"3.1.0","info":{"title":"Navixy Admin Panel API","version":"1.2.0"},"tags":[{"name":"User","description":"End users belonging to the dealer: their profiles, sessions, balance transactions, menu presets, and multi-factor authentication settings. All resources under the /panel/user/ path."}],"servers":[{"url":"https://api.eu.navixy.com/v2","description":"Navixy production server on European platform"},{"url":"https://api.us.navixy.com/v2","description":"Navixy production server on American platform"},{"url":"https://api.me.navixy.com/v2","description":"Navixy production server on Middle East platform"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"type":"apiKey","description":"Enter the panel session hash with the \"NVX \" prefix, e.g. \"NVX fa7bf873fab9333144e171372a321b06\". Obtain the hash from the accountAuth operation.","name":"Authorization","in":"header"}},"schemas":{"User":{"type":"object","readOnly":true,"description":"An end user of the dealer service. The response form is flat: every legal field is present regardless of `legal_type`, with empty strings where a field does not apply. The request form used by create and update is a discriminated union on `legal_type` instead.","properties":{"id":{"type":"integer","description":"User ID."},"dealer_id":{"type":"integer","description":"ID of the owning dealer."},"login":{"type":"string","description":"Login, an email address."},"activated":{"type":"boolean","description":"`true` once the account has been activated."},"verified":{"type":"boolean","description":"`true` if the email address has been verified."},"phone_verified":{"type":"boolean","description":"`true` if the phone number has been verified."},"legal_type":{"type":"string","description":"Legal status, which determines which legal fields below are meaningful.","enum":["individual","legal_entity","sole_trader"]},"first_name":{"type":"string","description":"First name."},"middle_name":{"type":"string","description":"Middle name."},"last_name":{"type":"string","description":"Last name."},"phone":{"type":"string","description":"Phone number."},"post_country":{"type":"string","description":"Postal address country."},"post_index":{"type":"string","description":"Postal code."},"post_region":{"type":"string","description":"Postal address region."},"post_city":{"type":"string","description":"Postal address city."},"post_street_address":{"type":"string","description":"Postal street address."},"registered_country":{"type":"string","description":"Registered address country. Meaningful for `legal_entity` and `sole_trader`."},"registered_index":{"type":"string","description":"Registered postal code. Meaningful for `legal_entity` and `sole_trader`."},"registered_region":{"type":"string","description":"Registered address region. Meaningful for `legal_entity` and `sole_trader`."},"registered_city":{"type":"string","description":"Registered address city. Meaningful for `legal_entity` and `sole_trader`."},"registered_street_address":{"type":"string","description":"Registered street address. Meaningful for `legal_entity` and `sole_trader`."},"legal_name":{"type":"string","description":"Legal company name. Meaningful for `legal_entity`."},"tin":{"type":"string","description":"Taxpayer identification number. Meaningful for `legal_entity` and `sole_trader`."},"iec":{"type":"string","description":"Interbranch enterprise code. Meaningful for `legal_entity`."},"state_reg_num":{"type":"string","description":"State registration number. Meaningful for `legal_entity` and `sole_trader`."},"okpo_code":{"type":"string","description":"OKPO classifier code. Digits only when present. Meaningful for `legal_entity` and `sole_trader`."},"balance":{"type":"number","description":"Current account balance."},"bonus":{"type":"number","description":"Current bonus balance."},"trackers_count":{"type":"integer","description":"Number of trackers the user owns."},"menu_preset_id":{"type":["integer","null"],"description":"ID of the menu preset assigned to this user."},"mfa_allowed":{"type":"boolean","description":"`true` if multi-factor authentication is permitted for this user."},"creation_date":{"type":"string","description":"When the account was created, as `YYYY-MM-DD HH:MM:SS`."},"comment":{"type":"string","description":"Free-text comment.","maxLength":255}}},"UserDiscount":{"type":"object","description":"A discount applied to a user.","properties":{"percent":{"type":"number","description":"Discount percentage."},"end_date":{"type":["string","null"],"description":"Date the discount expires.","format":"date"},"device_limit":{"type":["integer","null"],"description":"Minimum devices required for the discount to apply."}}}},"responses":{"ResponseError":{"description":"Error response object","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Always false."},"status":{"type":"object","description":"Error status. Present only when an error occurred.","properties":{"code":{"type":"integer","description":"An error code in this API (not a HTTP code)"},"description":{"type":"string","description":"An error description"}}},"errors":{"type":"array","description":"Per-parameter detail, returned with validation failures such as error code 7.","items":{"type":"object","properties":{"parameter":{"type":"string","description":"Name of the parameter that failed validation."},"error":{"type":"string","description":"What was wrong with it."}}}}}}}}}}},"paths":{"/panel/user/read":{"post":{"tags":["User"],"summary":"Read user","operationId":"userRead","description":"Read a single end user.\n\nThe response carries five sibling keys rather than a single `value`: the user profile, any discount, the default plan ID of the dealer, the block parameters of the user, and the dealer-level MFA settings.\n\nA sub-user, or a user belonging to another dealer, returns error code 201 exactly as a missing one does.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["user_id"],"properties":{"user_id":{"type":"integer","description":"ID of the user. Must belong to the current dealer and must not be a sub-user.","minimum":1}}}}}},"responses":{"200":{"description":"The user, with related settings","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"`true` if request finished successfully.","readOnly":true},"value":{"$ref":"#/components/schemas/User"},"discount":{"anyOf":[{"$ref":"#/components/schemas/UserDiscount"},{"type":"null"}],"description":"Discount applied to this user, or `null` when none."},"default_tariff_id":{"type":["integer","null"],"description":"ID of the default plan of the dealer."},"block_parameters":{"type":["object","null"],"description":"Parameters governing how and when the user is blocked.","additionalProperties":true},"dealer_mfa_settings":{"type":["object","null"],"description":"Dealer-level multi-factor authentication settings that apply to this user.","additionalProperties":true}}}}}},"400":{"description":"Bad request. The response body carries the API-level error code in `status.code`. Validation failures also include an `errors` array.","$ref":"#/components/responses/ResponseError"},"403":{"description":"Operation not permitted, error code 13: the session lacks the required permission.","$ref":"#/components/responses/ResponseError"},"default":{"$ref":"#/components/responses/ResponseError"}}}}}}
```

#### Errors

* 201 - Not found in the database - when the user does not exist, is a sub-user, or belongs to another dealer.

***

*required permissions*: `users: "update"`.

## Update user

> Update an end user.\
> \
> The \`user\` object must carry both \`id\` and \`activated\`; omitting either fails with an \`errors\` entry naming \`user.id\` or \`user.activated\`. Changing \`login\` to one already in use fails with error code 206.\
> \
> As with create, the shape of \`user\` depends on \`legal\_type\`.

```json
{"openapi":"3.1.0","info":{"title":"Navixy Admin Panel API","version":"1.2.0"},"tags":[{"name":"User","description":"End users belonging to the dealer: their profiles, sessions, balance transactions, menu presets, and multi-factor authentication settings. All resources under the /panel/user/ path."}],"servers":[{"url":"https://api.eu.navixy.com/v2","description":"Navixy production server on European platform"},{"url":"https://api.us.navixy.com/v2","description":"Navixy production server on American platform"},{"url":"https://api.me.navixy.com/v2","description":"Navixy production server on Middle East platform"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"type":"apiKey","description":"Enter the panel session hash with the \"NVX \" prefix, e.g. \"NVX fa7bf873fab9333144e171372a321b06\". Obtain the hash from the accountAuth operation.","name":"Authorization","in":"header"}},"schemas":{"UserEditForm":{"description":"A user to create or update. The shape depends on `legal_type`, which selects one of three variants.\n\nThe three are cumulative: a sole trader is an individual plus registration details, and a legal entity is a sole trader plus a company name and interbranch code. The legal variants also tighten the postal fields, which may be empty for an individual but not for a sole trader or legal entity.\n\nOn update, `id` and `activated` are both mandatory.","oneOf":[{"$ref":"#/components/schemas/UserIndividual"},{"$ref":"#/components/schemas/UserSoleTrader"},{"$ref":"#/components/schemas/UserLegalEntity"}],"discriminator":{"propertyName":"legal_type","mapping":{"individual":"#/components/schemas/UserIndividual","sole_trader":"#/components/schemas/UserSoleTrader","legal_entity":"#/components/schemas/UserLegalEntity"}}},"UserIndividual":{"type":"object","title":"individual","description":"A private individual. Postal fields are mandatory but may be empty strings.","required":["legal_type","login","first_name","middle_name","last_name","post_city","phone","post_country","post_region","post_city","post_street_address","post_index"],"properties":{"legal_type":{"type":"string","description":"Legal status. Determines which shape this object takes.","enum":["individual"]},"login":{"type":"string","description":"Login, which is an email address. Must be unique across the platform."},"first_name":{"type":"string","description":"First name. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"middle_name":{"type":"string","description":"Middle name. Required but may be empty. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"last_name":{"type":"string","description":"Last name. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"phone":{"type":"string","description":"Phone number, digits only. Required but may be empty.","pattern":"[0-9]*","maxLength":15},"birth_date":{"type":["string","null"],"description":"Date of birth. Not returned by the read operations.","format":"date"},"passport":{"type":["string","null"],"description":"Passport details. Not returned by the read operations."},"menu_preset_id":{"type":["integer","null"],"description":"ID of the menu preset to assign. See the menu preset operations."},"activated":{"type":"boolean","description":"Whether the account is activated. Mandatory on update."},"post_country":{"type":"string","description":"Postal address country. Required but may be empty. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"post_region":{"type":"string","description":"Postal address region. Required but may be empty. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"post_city":{"type":"string","description":"Postal address city. Required but may be empty. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"post_street_address":{"type":"string","description":"Postal street address. Required but may be empty. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":200},"post_index":{"type":"string","description":"Postal code. Validated against the country format. Required but may be empty."}}},"UserSoleTrader":{"type":"object","title":"sole_trader","description":"A sole trader. Adds registration details, and tightens the postal fields so they may no longer be empty.","required":["legal_type","login","first_name","middle_name","last_name","post_city","phone","post_country","post_region","post_city","post_street_address","post_index","registered_country","registered_region","registered_city","registered_street_address","registered_index","tin"],"properties":{"legal_type":{"type":"string","description":"Legal status. Determines which shape this object takes.","enum":["sole_trader"]},"login":{"type":"string","description":"Login, which is an email address. Must be unique across the platform."},"first_name":{"type":"string","description":"First name. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"middle_name":{"type":"string","description":"Middle name. Required but may be empty. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"last_name":{"type":"string","description":"Last name. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"phone":{"type":"string","description":"Phone number, digits only. Required but may be empty.","pattern":"[0-9]*","maxLength":15},"birth_date":{"type":["string","null"],"description":"Date of birth. Not returned by the read operations.","format":"date"},"passport":{"type":["string","null"],"description":"Passport details. Not returned by the read operations."},"menu_preset_id":{"type":["integer","null"],"description":"ID of the menu preset to assign. See the menu preset operations."},"activated":{"type":"boolean","description":"Whether the account is activated. Mandatory on update."},"post_country":{"type":"string","description":"Postal address country. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"post_region":{"type":"string","description":"Postal address region. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"post_city":{"type":"string","description":"Postal address city. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"post_street_address":{"type":"string","description":"Postal street address. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":200,"minLength":1},"post_index":{"type":"string","description":"Postal code. Validated against the country format. Must not be blank.","minLength":1},"registered_country":{"type":"string","description":"Registered address country. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"registered_region":{"type":"string","description":"Registered address region. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"registered_city":{"type":"string","description":"Registered address city. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"registered_street_address":{"type":"string","description":"Registered street address. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":200,"minLength":1},"registered_index":{"type":"string","description":"Registered postal code. Validated against the country format. Must not be blank.","minLength":1},"tin":{"type":"string","description":"Taxpayer identification number. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":255},"state_reg_num":{"type":"string","description":"State registration number. Digits only when not empty.","maxLength":15,"pattern":"\\d+|(^$)"},"okpo_code":{"type":"string","description":"OKPO classifier code. When not empty, must be 8 or 10 digits.","pattern":"\\d{8,10}|(^$)"}}},"UserLegalEntity":{"type":"object","title":"legal_entity","description":"A legal entity. Adds the company name and interbranch code on top of the sole trader fields.","required":["legal_type","login","first_name","middle_name","last_name","post_city","phone","post_country","post_region","post_city","post_street_address","post_index","registered_country","registered_region","registered_city","registered_street_address","registered_index","tin","legal_name","iec"],"properties":{"legal_type":{"type":"string","description":"Legal status. Determines which shape this object takes.","enum":["legal_entity"]},"login":{"type":"string","description":"Login, which is an email address. Must be unique across the platform."},"first_name":{"type":"string","description":"First name. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"middle_name":{"type":"string","description":"Middle name. Required but may be empty. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"last_name":{"type":"string","description":"Last name. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100},"phone":{"type":"string","description":"Phone number, digits only. Required but may be empty.","pattern":"[0-9]*","maxLength":15},"birth_date":{"type":["string","null"],"description":"Date of birth. Not returned by the read operations.","format":"date"},"passport":{"type":["string","null"],"description":"Passport details. Not returned by the read operations."},"menu_preset_id":{"type":["integer","null"],"description":"ID of the menu preset to assign. See the menu preset operations."},"activated":{"type":"boolean","description":"Whether the account is activated. Mandatory on update."},"post_country":{"type":"string","description":"Postal address country. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"post_region":{"type":"string","description":"Postal address region. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"post_city":{"type":"string","description":"Postal address city. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"post_street_address":{"type":"string","description":"Postal street address. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":200,"minLength":1},"post_index":{"type":"string","description":"Postal code. Validated against the country format. Must not be blank.","minLength":1},"registered_country":{"type":"string","description":"Registered address country. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"registered_region":{"type":"string","description":"Registered address region. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"registered_city":{"type":"string","description":"Registered address city. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":100,"minLength":1},"registered_street_address":{"type":"string","description":"Registered street address. Must not be blank. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":200,"minLength":1},"registered_index":{"type":"string","description":"Registered postal code. Validated against the country format. Must not be blank.","minLength":1},"tin":{"type":"string","description":"Taxpayer identification number. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":255},"state_reg_num":{"type":"string","description":"State registration number. Digits only when not empty.","maxLength":15,"pattern":"\\d+|(^$)"},"okpo_code":{"type":"string","description":"OKPO classifier code. When not empty, must be 8 or 10 digits.","pattern":"\\d{8,10}|(^$)"},"legal_name":{"type":"string","description":"Legal company name. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":255,"minLength":1},"iec":{"type":"string","description":"Interbranch enterprise code. Must match the platform name pattern: letters, digits, and the characters `- ' \" . , : /`.","maxLength":255}}},"UserDiscount":{"type":"object","description":"A discount applied to a user.","properties":{"percent":{"type":"number","description":"Discount percentage."},"end_date":{"type":["string","null"],"description":"Date the discount expires.","format":"date"},"device_limit":{"type":["integer","null"],"description":"Minimum devices required for the discount to apply."}}}},"responses":{"OK":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"`true` if request finished successfully.","readOnly":true}}}}}},"ResponseError":{"description":"Error response object","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Always false."},"status":{"type":"object","description":"Error status. Present only when an error occurred.","properties":{"code":{"type":"integer","description":"An error code in this API (not a HTTP code)"},"description":{"type":"string","description":"An error description"}}},"errors":{"type":"array","description":"Per-parameter detail, returned with validation failures such as error code 7.","items":{"type":"object","properties":{"parameter":{"type":"string","description":"Name of the parameter that failed validation."},"error":{"type":"string","description":"What was wrong with it."}}}}}}}}}}},"paths":{"/panel/user/update":{"post":{"tags":["User"],"summary":"Update user","operationId":"userUpdate","description":"Update an end user.\n\nThe `user` object must carry both `id` and `activated`; omitting either fails with an `errors` entry naming `user.id` or `user.activated`. Changing `login` to one already in use fails with error code 206.\n\nAs with create, the shape of `user` depends on `legal_type`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["user"],"properties":{"user":{"allOf":[{"$ref":"#/components/schemas/UserEditForm"}],"description":"The user to update. Must include `id` and `activated` in addition to the fields required by its `legal_type`."},"discount":{"anyOf":[{"$ref":"#/components/schemas/UserDiscount"},{"type":"null"}],"description":"Optional discount to apply to this user."},"default_tariff_id":{"type":["integer","null"],"description":"Optional. Plan the user is placed on. Must exist and belong to the dealer."},"comment":{"type":"string","description":"Optional free-text comment.","maxLength":255}}}}}},"responses":{"200":{"$ref":"#/components/responses/OK"},"400":{"description":"Bad request. The response body carries the API-level error code in `status.code`. Validation failures also include an `errors` array.","$ref":"#/components/responses/ResponseError"},"403":{"description":"Operation not permitted, error code 13: the session lacks the required permission.","$ref":"#/components/responses/ResponseError"},"default":{"$ref":"#/components/responses/ResponseError"}}}}}}
```

#### Errors

* 201 - Not found in the database - if the specified user does not exist or belongs to a different dealer.
* 206 - Login already in use - if the specified `login` is used by another user.

***

*required permissions*: `users: "update"`.

## Change user password

> Set a new password for an end user.\
> \
> Note the parameter is \`password\`, not \`new\_password\` as the dealer and subpaas equivalents use, and no current password is required: a dealer sets a user password without knowing the old one.\
> \
> The value must satisfy the password policy of the dealer, returned as \`password\_policy\` by the dealer get info operation.

```json
{"openapi":"3.1.0","info":{"title":"Navixy Admin Panel API","version":"1.2.0"},"tags":[{"name":"User","description":"End users belonging to the dealer: their profiles, sessions, balance transactions, menu presets, and multi-factor authentication settings. All resources under the /panel/user/ path."}],"servers":[{"url":"https://api.eu.navixy.com/v2","description":"Navixy production server on European platform"},{"url":"https://api.us.navixy.com/v2","description":"Navixy production server on American platform"},{"url":"https://api.me.navixy.com/v2","description":"Navixy production server on Middle East platform"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"type":"apiKey","description":"Enter the panel session hash with the \"NVX \" prefix, e.g. \"NVX fa7bf873fab9333144e171372a321b06\". Obtain the hash from the accountAuth operation.","name":"Authorization","in":"header"}},"responses":{"OK":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"`true` if request finished successfully.","readOnly":true}}}}}},"ResponseError":{"description":"Error response object","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Always false."},"status":{"type":"object","description":"Error status. Present only when an error occurred.","properties":{"code":{"type":"integer","description":"An error code in this API (not a HTTP code)"},"description":{"type":"string","description":"An error description"}}},"errors":{"type":"array","description":"Per-parameter detail, returned with validation failures such as error code 7.","items":{"type":"object","properties":{"parameter":{"type":"string","description":"Name of the parameter that failed validation."},"error":{"type":"string","description":"What was wrong with it."}}}}}}}}}}},"paths":{"/panel/user/change_password":{"post":{"tags":["User"],"summary":"Change user password","operationId":"userChangePassword","description":"Set a new password for an end user.\n\nNote the parameter is `password`, not `new_password` as the dealer and subpaas equivalents use, and no current password is required: a dealer sets a user password without knowing the old one.\n\nThe value must satisfy the password policy of the dealer, returned as `password_policy` by the dealer get info operation.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["user_id","password"],"properties":{"user_id":{"type":"integer","description":"ID of the user. Must belong to the current dealer and must not be a sub-user.","minimum":1},"password":{"type":"string","format":"password","description":"New password. Must satisfy the password policy of the dealer and must not match a recently used password."}}}}}},"responses":{"200":{"$ref":"#/components/responses/OK"},"400":{"description":"Bad request. The response body carries the API-level error code in `status.code`. Validation failures also include an `errors` array.","$ref":"#/components/responses/ResponseError"},"403":{"description":"Operation not permitted, error code 13: the session lacks the required permission.","$ref":"#/components/responses/ResponseError"},"default":{"$ref":"#/components/responses/ResponseError"}}}}}}
```

***

*required permissions*: `users: "corrupt"`.

## Corrupt user

> Corrupt an end user, marking the account and its data as unusable.\
> \
> \*\*The login of the user must be supplied alongside \`user\_id\`\*\*, which acts as a deliberate confirmation step for a destructive operation.\
> \
> By default the tracker clones of the user are corrupted too.

```json
{"openapi":"3.1.0","info":{"title":"Navixy Admin Panel API","version":"1.2.0"},"tags":[{"name":"User","description":"End users belonging to the dealer: their profiles, sessions, balance transactions, menu presets, and multi-factor authentication settings. All resources under the /panel/user/ path."}],"servers":[{"url":"https://api.eu.navixy.com/v2","description":"Navixy production server on European platform"},{"url":"https://api.us.navixy.com/v2","description":"Navixy production server on American platform"},{"url":"https://api.me.navixy.com/v2","description":"Navixy production server on Middle East platform"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"type":"apiKey","description":"Enter the panel session hash with the \"NVX \" prefix, e.g. \"NVX fa7bf873fab9333144e171372a321b06\". Obtain the hash from the accountAuth operation.","name":"Authorization","in":"header"}},"responses":{"OK":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"`true` if request finished successfully.","readOnly":true}}}}}},"ResponseError":{"description":"Error response object","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Always false."},"status":{"type":"object","description":"Error status. Present only when an error occurred.","properties":{"code":{"type":"integer","description":"An error code in this API (not a HTTP code)"},"description":{"type":"string","description":"An error description"}}},"errors":{"type":"array","description":"Per-parameter detail, returned with validation failures such as error code 7.","items":{"type":"object","properties":{"parameter":{"type":"string","description":"Name of the parameter that failed validation."},"error":{"type":"string","description":"What was wrong with it."}}}}}}}}}}},"paths":{"/panel/user/corrupt":{"post":{"tags":["User"],"summary":"Corrupt user","operationId":"userCorrupt","description":"Corrupt an end user, marking the account and its data as unusable.\n\n**The login of the user must be supplied alongside `user_id`**, which acts as a deliberate confirmation step for a destructive operation.\n\nBy default the tracker clones of the user are corrupted too.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["user_id","login"],"properties":{"user_id":{"type":"integer","description":"ID of the user. Must belong to the current dealer and must not be a sub-user.","minimum":1},"login":{"type":"string","description":"Login of the user being corrupted.","minLength":1},"corrupt_clones":{"type":"boolean","description":"Whether to corrupt the tracker clones of the user as well.","default":true}}}}}},"responses":{"200":{"$ref":"#/components/responses/OK"},"400":{"description":"Bad request. The response body carries the API-level error code in `status.code`. Validation failures also include an `errors` array.","$ref":"#/components/responses/ResponseError"},"403":{"description":"Operation not permitted, error code 13: the session lacks the required permission.","$ref":"#/components/responses/ResponseError"},"default":{"$ref":"#/components/responses/ResponseError"}}}}}}
```

#### Errors

* 201 - Not found in the database - if the specified user does not exist or belongs to a different dealer.

***

*required permissions*: `users: "create"`.

## Upload users

> Create users in bulk from a CSV or XLS spreadsheet.\
> \
> Requires a \`multipart/form-data\` request with the spreadsheet as a part named \`file\`, in the same way as the branding image upload. \*\*At most 10000 rows\*\* are processed.\
> \
> Column headers are localized, so a Russian-locale file uses Russian headers. Columns may appear in any order. \`Legal status\` is a number: \`1\` individual, \`2\` legal entity, \`3\` sole trader. Legal entities and sole traders require the address and registration columns as well as the always-required ones, except that a sole trader does not require \`Legal name\`.\
> \
> New users take the time zone from the \`default\_user\_time\_zone\` service setting.

```json
{"openapi":"3.1.0","info":{"title":"Navixy Admin Panel API","version":"1.2.0"},"tags":[{"name":"User","description":"End users belonging to the dealer: their profiles, sessions, balance transactions, menu presets, and multi-factor authentication settings. All resources under the /panel/user/ path."}],"servers":[{"url":"https://api.eu.navixy.com/v2","description":"Navixy production server on European platform"},{"url":"https://api.us.navixy.com/v2","description":"Navixy production server on American platform"},{"url":"https://api.me.navixy.com/v2","description":"Navixy production server on Middle East platform"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"type":"apiKey","description":"Enter the panel session hash with the \"NVX \" prefix, e.g. \"NVX fa7bf873fab9333144e171372a321b06\". Obtain the hash from the accountAuth operation.","name":"Authorization","in":"header"}},"responses":{"ResponseError":{"description":"Error response object","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Always false."},"status":{"type":"object","description":"Error status. Present only when an error occurred.","properties":{"code":{"type":"integer","description":"An error code in this API (not a HTTP code)"},"description":{"type":"string","description":"An error description"}}},"errors":{"type":"array","description":"Per-parameter detail, returned with validation failures such as error code 7.","items":{"type":"object","properties":{"parameter":{"type":"string","description":"Name of the parameter that failed validation."},"error":{"type":"string","description":"What was wrong with it."}}}}}}}}}}},"paths":{"/panel/user/upload":{"post":{"tags":["User"],"summary":"Upload users","operationId":"userUpload","description":"Create users in bulk from a CSV or XLS spreadsheet.\n\nRequires a `multipart/form-data` request with the spreadsheet as a part named `file`, in the same way as the branding image upload. **At most 10000 rows** are processed.\n\nColumn headers are localized, so a Russian-locale file uses Russian headers. Columns may appear in any order. `Legal status` is a number: `1` individual, `2` legal entity, `3` sole trader. Legal entities and sole traders require the address and registration columns as well as the always-required ones, except that a sole trader does not require `Legal name`.\n\nNew users take the time zone from the `default_user_time_zone` service setting.","requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary","description":"CSV or XLS spreadsheet. CSV uses `;` as the column separator."},"redirect_target":{"type":"string","format":"uri","description":"Optional URL to redirect to instead of returning the JSON response body, as for the branding image upload."}}}}}},"responses":{"200":{"description":"Upload processed","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","readOnly":true},"total":{"type":"integer","description":"Number of rows processed.","readOnly":true},"errors":{"type":"integer","description":"Number of rows that failed.","readOnly":true}}}}}},"400":{"description":"Bad request. The response body carries the API-level error code in `status.code`. Validation failures also include an `errors` array.","$ref":"#/components/responses/ResponseError"},"403":{"description":"Operation not permitted, error code 13: the session lacks the required permission.","$ref":"#/components/responses/ResponseError"},"default":{"$ref":"#/components/responses/ResponseError"}}}}}}
```

#### Spreadsheet columns

CSV uses `;` as the column separator. Column headers are localized, and headers marked `*` are always required.

For an English-locale file:

`Email address*;Password*;Status*;Legal status*;Surname*;Name*;Middle name;Phone number;Comment;Country;Region;City;Street, address;Zip code;Legal name;Tax number;IEC;Registration country;Registration region;Registration city;Registration address;Registration zip code;Discount;End date of discount;Device limit`

For a Russian-locale file:

`Адрес электронной почты*;Пароль*;Статус*;Юридический статус*;Фамилия*;Имя*;Отчество;Номер телефона;Комментарий;Страна;Регион;Город;Улица, дом, квартира;Почтовый индекс;Юридическое название;ИНН;КПП;ОГРН;ОКПО;Страна регистрации;Регион регистрации;Город регистрации;Улица, дом регистрации;Почтовый индекс регистрации;Скидка;Дата окончания скидки;Минимальное число устройств для скидки`

`Legal status` must be one of the following numbers:

* 1 - individual
* 2 - legal entity
* 3 - sole trader

For legal entity (2) and sole trader (3), the following columns must also be present and filled with data, in addition to those marked `*`:

`Country;Region;City;Street, address;Zip code;Legal name;Registration region;Registration city;Registration address;Registration zip code`

`Legal name` is the exception: it is not required for a sole trader (3).

The remaining columns are optional and can be omitted. Columns can appear in any order.

New users are created with the time zone specified in the `default_user_time_zone` [service setting](/docs/navixy-api/panel-api/resources/dealer/settings/service.md).

***

*required permissions*: `users: "read"`.

## List users

> List the end users of the dealer, with optional text filtering, ordering and pagination.

```json
{"openapi":"3.1.0","info":{"title":"Navixy Admin Panel API","version":"1.2.0"},"tags":[{"name":"User","description":"End users belonging to the dealer: their profiles, sessions, balance transactions, menu presets, and multi-factor authentication settings. All resources under the /panel/user/ path."}],"servers":[{"url":"https://api.eu.navixy.com/v2","description":"Navixy production server on European platform"},{"url":"https://api.us.navixy.com/v2","description":"Navixy production server on American platform"},{"url":"https://api.me.navixy.com/v2","description":"Navixy production server on Middle East platform"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"type":"apiKey","description":"Enter the panel session hash with the \"NVX \" prefix, e.g. \"NVX fa7bf873fab9333144e171372a321b06\". Obtain the hash from the accountAuth operation.","name":"Authorization","in":"header"}},"schemas":{"User":{"type":"object","readOnly":true,"description":"An end user of the dealer service. The response form is flat: every legal field is present regardless of `legal_type`, with empty strings where a field does not apply. The request form used by create and update is a discriminated union on `legal_type` instead.","properties":{"id":{"type":"integer","description":"User ID."},"dealer_id":{"type":"integer","description":"ID of the owning dealer."},"login":{"type":"string","description":"Login, an email address."},"activated":{"type":"boolean","description":"`true` once the account has been activated."},"verified":{"type":"boolean","description":"`true` if the email address has been verified."},"phone_verified":{"type":"boolean","description":"`true` if the phone number has been verified."},"legal_type":{"type":"string","description":"Legal status, which determines which legal fields below are meaningful.","enum":["individual","legal_entity","sole_trader"]},"first_name":{"type":"string","description":"First name."},"middle_name":{"type":"string","description":"Middle name."},"last_name":{"type":"string","description":"Last name."},"phone":{"type":"string","description":"Phone number."},"post_country":{"type":"string","description":"Postal address country."},"post_index":{"type":"string","description":"Postal code."},"post_region":{"type":"string","description":"Postal address region."},"post_city":{"type":"string","description":"Postal address city."},"post_street_address":{"type":"string","description":"Postal street address."},"registered_country":{"type":"string","description":"Registered address country. Meaningful for `legal_entity` and `sole_trader`."},"registered_index":{"type":"string","description":"Registered postal code. Meaningful for `legal_entity` and `sole_trader`."},"registered_region":{"type":"string","description":"Registered address region. Meaningful for `legal_entity` and `sole_trader`."},"registered_city":{"type":"string","description":"Registered address city. Meaningful for `legal_entity` and `sole_trader`."},"registered_street_address":{"type":"string","description":"Registered street address. Meaningful for `legal_entity` and `sole_trader`."},"legal_name":{"type":"string","description":"Legal company name. Meaningful for `legal_entity`."},"tin":{"type":"string","description":"Taxpayer identification number. Meaningful for `legal_entity` and `sole_trader`."},"iec":{"type":"string","description":"Interbranch enterprise code. Meaningful for `legal_entity`."},"state_reg_num":{"type":"string","description":"State registration number. Meaningful for `legal_entity` and `sole_trader`."},"okpo_code":{"type":"string","description":"OKPO classifier code. Digits only when present. Meaningful for `legal_entity` and `sole_trader`."},"balance":{"type":"number","description":"Current account balance."},"bonus":{"type":"number","description":"Current bonus balance."},"trackers_count":{"type":"integer","description":"Number of trackers the user owns."},"menu_preset_id":{"type":["integer","null"],"description":"ID of the menu preset assigned to this user."},"mfa_allowed":{"type":"boolean","description":"`true` if multi-factor authentication is permitted for this user."},"creation_date":{"type":"string","description":"When the account was created, as `YYYY-MM-DD HH:MM:SS`."},"comment":{"type":"string","description":"Free-text comment.","maxLength":255}}}},"responses":{"ResponseError":{"description":"Error response object","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Always false."},"status":{"type":"object","description":"Error status. Present only when an error occurred.","properties":{"code":{"type":"integer","description":"An error code in this API (not a HTTP code)"},"description":{"type":"string","description":"An error description"}}},"errors":{"type":"array","description":"Per-parameter detail, returned with validation failures such as error code 7.","items":{"type":"object","properties":{"parameter":{"type":"string","description":"Name of the parameter that failed validation."},"error":{"type":"string","description":"What was wrong with it."}}}}}}}}}}},"paths":{"/panel/user/list":{"post":{"tags":["User"],"summary":"List users","operationId":"userList","description":"List the end users of the dealer, with optional text filtering, ordering and pagination.","requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"filter":{"type":"string","description":"Optional. Text filter."},"order_by":{"type":"string","description":"Optional. Field to order by."},"ascending":{"type":"boolean","description":"Optional. Ascending when `true`.","default":true},"offset":{"type":"integer","description":"Optional. Starting offset, for pagination.","minimum":0,"default":0},"limit":{"type":"integer","description":"Optional. Maximum records to return.","minimum":0}}}}}},"responses":{"200":{"description":"Users","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"`true` if request finished successfully.","readOnly":true},"list":{"type":"array","readOnly":true,"items":{"$ref":"#/components/schemas/User"}},"count":{"type":"integer","readOnly":true,"description":"Total matching records, ignoring `offset` and `limit`."}}}}}},"400":{"description":"Bad request. The response body carries the API-level error code in `status.code`. Validation failures also include an `errors` array.","$ref":"#/components/responses/ResponseError"},"403":{"description":"Operation not permitted, error code 13: the session lacks the required permission.","$ref":"#/components/responses/ResponseError"},"default":{"$ref":"#/components/responses/ResponseError"}}}}}}
```

***

*required permissions*: `users: "read"`.

## Export users

> Export the user list as a spreadsheet. Unlike every other operation here, a successful response is a file download rather than a JSON body.

```json
{"openapi":"3.1.0","info":{"title":"Navixy Admin Panel API","version":"1.2.0"},"tags":[{"name":"User","description":"End users belonging to the dealer: their profiles, sessions, balance transactions, menu presets, and multi-factor authentication settings. All resources under the /panel/user/ path."}],"servers":[{"url":"https://api.eu.navixy.com/v2","description":"Navixy production server on European platform"},{"url":"https://api.us.navixy.com/v2","description":"Navixy production server on American platform"},{"url":"https://api.me.navixy.com/v2","description":"Navixy production server on Middle East platform"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"type":"apiKey","description":"Enter the panel session hash with the \"NVX \" prefix, e.g. \"NVX fa7bf873fab9333144e171372a321b06\". Obtain the hash from the accountAuth operation.","name":"Authorization","in":"header"}},"responses":{"ResponseError":{"description":"Error response object","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Always false."},"status":{"type":"object","description":"Error status. Present only when an error occurred.","properties":{"code":{"type":"integer","description":"An error code in this API (not a HTTP code)"},"description":{"type":"string","description":"An error description"}}},"errors":{"type":"array","description":"Per-parameter detail, returned with validation failures such as error code 7.","items":{"type":"object","properties":{"parameter":{"type":"string","description":"Name of the parameter that failed validation."},"error":{"type":"string","description":"What was wrong with it."}}}}}}}}}}},"paths":{"/panel/user/export":{"post":{"tags":["User"],"summary":"Export users","operationId":"userExport","description":"Export the user list as a spreadsheet. Unlike every other operation here, a successful response is a file download rather than a JSON body.","requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"format":{"type":"string","description":"Output file format.","enum":["csv","xlsx"],"default":"xlsx"},"columns":{"type":"array","description":"Columns to include, in order. Must not be empty.","minItems":1,"items":{"type":"string"},"default":["id","login","first_name","middle_name","last_name","phone"]},"filter":{"type":"string","description":"Optional. Text filter, as for the list operation."}}}}}},"responses":{"200":{"description":"The exported file.","content":{"text/csv":{"schema":{"type":"string"}},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":{"schema":{"type":"string","format":"binary"}}}},"400":{"description":"Bad request. The response body carries the API-level error code in `status.code`. Validation failures also include an `errors` array.","$ref":"#/components/responses/ResponseError"},"403":{"description":"Operation not permitted, error code 13: the session lacks the required permission.","$ref":"#/components/responses/ResponseError"},"default":{"$ref":"#/components/responses/ResponseError"}}}}}}
```

***

*required permissions*: `users: "read"` and `user_sessions: "create"`.

## Create user session

> Create a session for an end user and return its hash, letting a dealer act on behalf of that user in the user-facing API without knowing their password.

```json
{"openapi":"3.1.0","info":{"title":"Navixy Admin Panel API","version":"1.2.0"},"tags":[{"name":"User","description":"End users belonging to the dealer: their profiles, sessions, balance transactions, menu presets, and multi-factor authentication settings. All resources under the /panel/user/ path."}],"servers":[{"url":"https://api.eu.navixy.com/v2","description":"Navixy production server on European platform"},{"url":"https://api.us.navixy.com/v2","description":"Navixy production server on American platform"},{"url":"https://api.me.navixy.com/v2","description":"Navixy production server on Middle East platform"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"type":"apiKey","description":"Enter the panel session hash with the \"NVX \" prefix, e.g. \"NVX fa7bf873fab9333144e171372a321b06\". Obtain the hash from the accountAuth operation.","name":"Authorization","in":"header"}},"responses":{"ResponseError":{"description":"Error response object","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Always false."},"status":{"type":"object","description":"Error status. Present only when an error occurred.","properties":{"code":{"type":"integer","description":"An error code in this API (not a HTTP code)"},"description":{"type":"string","description":"An error description"}}},"errors":{"type":"array","description":"Per-parameter detail, returned with validation failures such as error code 7.","items":{"type":"object","properties":{"parameter":{"type":"string","description":"Name of the parameter that failed validation."},"error":{"type":"string","description":"What was wrong with it."}}}}}}}}}}},"paths":{"/panel/user/session/create":{"post":{"tags":["User"],"summary":"Create user session","operationId":"userSessionCreate","description":"Create a session for an end user and return its hash, letting a dealer act on behalf of that user in the user-facing API without knowing their password.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["user_id"],"properties":{"user_id":{"type":"integer","description":"ID of the user. Must belong to the current dealer and must not be a sub-user.","minimum":1}}}}}},"responses":{"200":{"description":"The session of the user","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"`true` if request finished successfully.","readOnly":true},"hash":{"type":"string","description":"Session key for the end user. Use it against the user-facing API, not the Admin Panel API.","readOnly":true}}}}}},"400":{"description":"Bad request. The response body carries the API-level error code in `status.code`. Validation failures also include an `errors` array.","$ref":"#/components/responses/ResponseError"},"403":{"description":"Operation not permitted, error code 13: the session lacks the required permission.","$ref":"#/components/responses/ResponseError"},"default":{"$ref":"#/components/responses/ResponseError"}}}}}}
```

#### Errors

* 201 - Not found in the database - if the specified user does not exist or belongs to a different dealer.

***

*required permissions*: `users: "read"` and `transactions: "read"`.

## List user transactions

> List balance transactions for an end user over a time interval.\
> \
> \`from\` and \`to\` are \*\*top-level parameters\*\*, not nested under an \`interval\` object. Both are mandatory.\
> \
> The interval is bounded: too wide a span fails with error code 211 rather than truncating.

```json
{"openapi":"3.1.0","info":{"title":"Navixy Admin Panel API","version":"1.2.0"},"tags":[{"name":"User","description":"End users belonging to the dealer: their profiles, sessions, balance transactions, menu presets, and multi-factor authentication settings. All resources under the /panel/user/ path."}],"servers":[{"url":"https://api.eu.navixy.com/v2","description":"Navixy production server on European platform"},{"url":"https://api.us.navixy.com/v2","description":"Navixy production server on American platform"},{"url":"https://api.me.navixy.com/v2","description":"Navixy production server on Middle East platform"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"type":"apiKey","description":"Enter the panel session hash with the \"NVX \" prefix, e.g. \"NVX fa7bf873fab9333144e171372a321b06\". Obtain the hash from the accountAuth operation.","name":"Authorization","in":"header"}},"schemas":{"UserTransaction":{"type":"object","readOnly":true,"description":"A balance transaction recorded against a user.","properties":{"id":{"type":"integer","description":"Transaction ID."},"user_id":{"type":"integer","description":"ID of the user."},"amount":{"type":"number","description":"Signed amount applied."},"type":{"type":"string","description":"Which balance the transaction applied to."},"text":{"type":"string","description":"Reason recorded with the transaction."},"timestamp":{"type":"string","description":"When the transaction was recorded, as `YYYY-MM-DD HH:MM:SS`."}}}},"responses":{"ResponseError":{"description":"Error response object","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Always false."},"status":{"type":"object","description":"Error status. Present only when an error occurred.","properties":{"code":{"type":"integer","description":"An error code in this API (not a HTTP code)"},"description":{"type":"string","description":"An error description"}}},"errors":{"type":"array","description":"Per-parameter detail, returned with validation failures such as error code 7.","items":{"type":"object","properties":{"parameter":{"type":"string","description":"Name of the parameter that failed validation."},"error":{"type":"string","description":"What was wrong with it."}}}}}}}}}}},"paths":{"/panel/user/transaction/list":{"post":{"tags":["User"],"summary":"List user transactions","operationId":"userTransactionList","description":"List balance transactions for an end user over a time interval.\n\n`from` and `to` are **top-level parameters**, not nested under an `interval` object. Both are mandatory.\n\nThe interval is bounded: too wide a span fails with error code 211 rather than truncating.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["user_id","from","to"],"properties":{"user_id":{"type":"integer","description":"ID of the user. Must belong to the current dealer and must not be a sub-user.","minimum":1},"from":{"type":"string","description":"Start of the interval, as `YYYY-MM-DD HH:MM:SS`."},"to":{"type":"string","description":"End of the interval, as `YYYY-MM-DD HH:MM:SS`."},"limit":{"type":"integer","description":"Optional. Maximum records to return.","minimum":1,"maximum":20000}}}}}},"responses":{"200":{"description":"The transactions of the user","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"`true` if request finished successfully.","readOnly":true},"list":{"type":"array","readOnly":true,"items":{"$ref":"#/components/schemas/UserTransaction"}}}}}}},"400":{"description":"Bad request. The response body carries the API-level error code in `status.code`. Validation failures also include an `errors` array.","$ref":"#/components/responses/ResponseError"},"403":{"description":"Operation not permitted, error code 13: the session lacks the required permission.","$ref":"#/components/responses/ResponseError"},"default":{"$ref":"#/components/responses/ResponseError"}}}}}}
```

#### Errors

* 211 - Requested time span is too big - if the interval between `from` and `to` exceeds the permitted maximum.

***

*required permissions*: `users: "update"` and `transactions: "create"`.

## Change user balance

> Adjust the balance or bonus balance of an end user by a signed amount, recording a transaction.\
> \
> A descriptive \`text\` of at least 5 characters is mandatory, so every adjustment carries a reason.

```json
{"openapi":"3.1.0","info":{"title":"Navixy Admin Panel API","version":"1.2.0"},"tags":[{"name":"User","description":"End users belonging to the dealer: their profiles, sessions, balance transactions, menu presets, and multi-factor authentication settings. All resources under the /panel/user/ path."}],"servers":[{"url":"https://api.eu.navixy.com/v2","description":"Navixy production server on European platform"},{"url":"https://api.us.navixy.com/v2","description":"Navixy production server on American platform"},{"url":"https://api.me.navixy.com/v2","description":"Navixy production server on Middle East platform"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"type":"apiKey","description":"Enter the panel session hash with the \"NVX \" prefix, e.g. \"NVX fa7bf873fab9333144e171372a321b06\". Obtain the hash from the accountAuth operation.","name":"Authorization","in":"header"}},"responses":{"OK":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"`true` if request finished successfully.","readOnly":true}}}}}},"ResponseError":{"description":"Error response object","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Always false."},"status":{"type":"object","description":"Error status. Present only when an error occurred.","properties":{"code":{"type":"integer","description":"An error code in this API (not a HTTP code)"},"description":{"type":"string","description":"An error description"}}},"errors":{"type":"array","description":"Per-parameter detail, returned with validation failures such as error code 7.","items":{"type":"object","properties":{"parameter":{"type":"string","description":"Name of the parameter that failed validation."},"error":{"type":"string","description":"What was wrong with it."}}}}}}}}}}},"paths":{"/panel/user/transaction/change_balance":{"post":{"tags":["User"],"summary":"Change user balance","operationId":"userTransactionChangeBalance","description":"Adjust the balance or bonus balance of an end user by a signed amount, recording a transaction.\n\nA descriptive `text` of at least 5 characters is mandatory, so every adjustment carries a reason.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["user_id","amount","type","text"],"properties":{"user_id":{"type":"integer","description":"ID of the user. Must belong to the current dealer and must not be a sub-user.","minimum":1},"amount":{"type":"number","description":"Signed amount to apply. Negative values debit the balance.","minimum":-9999999999.9999,"maximum":9999999999.9999},"type":{"type":"string","description":"Which balance to adjust."},"text":{"type":"string","description":"Reason for the adjustment, recorded on the transaction.","minLength":5,"maxLength":200}}}}}},"responses":{"200":{"$ref":"#/components/responses/OK"},"400":{"description":"Bad request. The response body carries the API-level error code in `status.code`. Validation failures also include an `errors` array.","$ref":"#/components/responses/ResponseError"},"403":{"description":"Operation not permitted, error code 13: the session lacks the required permission.","$ref":"#/components/responses/ResponseError"},"default":{"$ref":"#/components/responses/ResponseError"}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://navixy.com/docs/navixy-api/panel-api/resources/user.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
