--- title: "User login" slug: "base-user-login-request" updated: 2026-04-29T13:32:05Z published: 2026-04-29T13:32:05Z canonical: "docs.lobstersoftware.com/base-user-login-request" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.lobstersoftware.com/llms.txt > Use this file to discover all available pages before exploring further. # User login | XML name | base:UserLoginRequest | | --- | --- | | Class name | de.lobster.scm.base.authentication.UserLoginRequest | The UserLoginRequest can be used both via REST and via Lobster_data expansions. Login example: ```xml ``` The login takes place under indication of the user name (`userName`) and its password (`password`). Should the user not exist or the password is wrong, an exception is raised and the login fails. If the user is assigned to several companies or roles (see [Users](/v1/docs/en/base-user)), the company and role that are to be used must be indicated. | Parameter | Required? | Description | Example | | --- | --- | --- | --- | | `userName` | ![images/s/-95e2zf/9012/8yg2g7/_/images/icons/emoticons/check.svg](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/check(26).svg) | The user name to be used for login. | `userName="jabend"` | | `password` | ![images/s/-95e2zf/9012/8yg2g7/_/images/icons/emoticons/check.svg](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/check(26).svg) | The user name's password. | `password="jabend123!"` | | `selectedRole` | ![images/s/-95e2zf/9012/8yg2g7/_/images/icons/emoticons/error.svg](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/error(19).svg) | The ID of the role to be used. This parameter is necessary only if the user is assigned to several roles. | `selectedRole="2"` | | `selectedCompany` | ![images/s/-95e2zf/9012/8yg2g7/_/images/icons/emoticons/error.svg](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/error(19).svg) | The ID of the company to be used. This parameter is necessary only if the user is assigned to several companies. | `selectedCompany="2"` | | `locale` | ![images/s/-95e2zf/9012/8yg2g7/_/images/icons/emoticons/error.svg](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/error(19).svg) | Here, the language set for the user can be overwritten for this session. | `locale="de"` | | `clientType` | ![images/s/-95e2zf/9012/8yg2g7/_/images/icons/emoticons/error.svg](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/error(19).svg) | The client type. The flex client used here is e.g. "Flex". Note that for every client type and user, only one simultaneous login is permitted. | `clientType="Custom Rest Client"` | | `forceLogin` | ![images/s/-95e2zf/9012/8yg2g7/_/images/icons/emoticons/error.svg](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/error(19).svg) | If "true", a possibly existing session is logged off for this user with this client type. If `forceLogin='false'` and a session already exists, an exception is raised. | `forceLogin="true"` |