TOC
1. API Headers
2. Sample Request (Payload)
The Add User API creates a new user in the QEval system. This API is used to onboard users by assigning profile information, role, supervisor, campaign, location, and access permissions.
| URL | https://{Subdomain}.qevalpro.com/api/ManageUser/AddUser |
| Method | POST |
| Sub Domains | “app” or “ai” |
1. API Headers
Every API call must include two-factor authentication by providing the following headers:
| Header | Type | Description |
|---|---|---|
| Authorisation | String | Bearer <Generated_Token> (generated after successful login) |
| X-API-KEY | String |
<Your_Unique_API_Key> (generated after successful login) Note: If unavailable, email Qeval@etechtexas.com. |
2. Sample Request (Payload)
Description for Request Parameters
| S.No | Name | Type | Description | Is Required? |
|---|---|---|---|---|
| 1 | EmpId | String | Unique employee identifier | Yes |
| 2 | UserName | String | Username used for login | Yes |
| 3 | Password | String | Password for the user account | Yes |
| 4 | EmpType | String | Employee type (e.g., Agent, FTE) | Yes |
| 5 | FirstName | String | First name of the employee | Yes |
| 6 | LastName | String | Last name of the employee | Yes |
| 7 | MiddleName | String | Middle name of the employee | No |
| 8 | String | Email address of the user | Yes | |
| 9 | RoleId | Integer | Role assigned to the user | Yes |
| 10 | SupervisorId | String | Employee ID of the supervisor | Yes |
| 11 | LocationID | Integer | Location assigned to the user | Yes |
| 12 | PartnerId | Integer | Partner identifier associated with the user | Yes |
| 13 | CampaignId | Integer | Campaign assigned to the user | Yes |
| 14 | IsAccessLocationBased | Boolean (String) | Enables location-based access restrictions | Yes |
| 15 | IsAccessIPBased | Boolean (String) | Enables IP-based login restrictions | Yes |
| 16 | IsSupervisor | Boolean (String) | Indicates whether the user is a supervisor | Yes |
| 17 | IsPartnerAllowed | Boolean (String) | Indicates whether partner access is enabled | Yes |
Validation Rules
| Field | Validation Rule |
|---|---|
| EmpId | Required, maximum 25 characters, alphanumeric and dot (.) allowed |
| UserName | Required, maximum 512 characters |
| Password | Required, minimum 12 characters, maximum 128 characters |
| EmpType | Required, maximum 25 characters, alphanumeric |
| FirstName | Required, maximum 100 characters |
| LastName | Required, maximum 100 characters |
| Must be a valid email address | |
| IsAccessLocationBased | Must be “true” or “false” |
| IsAccessIPBased | Must be “true” or “false” |
| IsSupervisor | Must be “true” or “false” |
| IsPartnerAllowed | Must be “true” or “false” |
3. Response Examples
Success
Status Codes
| Code | Status | Description |
|---|---|---|
| 200 | Success | User added successfully |
Response Parameters
| S.No | Name | Type | Description |
|---|---|---|---|
| 1 | Message | String | Status message returned by the API |
| 2 | EmpSrId | Integer | System-generated employee serial identifier |
| 3 | EmpId | String | Employee identifier |
| 4 | UserName | String | Username created in the system |
Failure
Status Codes
| Code | Status | Description |
|---|---|---|
| 400 | Bad Request | Validation failure or duplicate Employee ID, Username, or Email |
| 401 | Unauthorised | Invalid or expired authentication token |
| 403 | Forbidden | Invalid or missing API key |
| 406 | Not Acceptable | Exception occurred while processing the request |
| 500 | Internal Server Error | Unexpected server error occurred |
Notes
- Authentication is mandatory for accessing this API.
- Employee ID, Username, and Email must be unique within the system.
- Password length must be between 12 and 128 characters.
- Boolean fields must be passed as string values: “true” or “false”.
- A successful response returns the generated Employee Serial ID (EmpSrId) which can be used for future update and delete operations.
- Ensure all referenced entities such as Role, Campaign, Supervisor, Location, and Partner exist before creating a user.
- The API validates all mandatory fields before creating the user record.
Video