API Documentation

Update User

The Update User API updates the details of an existing user in the QEval system. This API is used to modify user profile information, role assignments, supervisor details, campaign mappings, location settings, and access permissions.

URL https://{Subdomain}.qevalpro.com/api/ManageUser/UpdateUser
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)

</> JSON
{
    "EmpSrId": 1023,
    "EmpId": "EMP001",
    "UserName": "john.doe.updated",
    "Email": "john.updated@example.com",
    "EmpType": "Agent",
    "FirstName": "John",
    "LastName": "Doe",
    "RoleId": 1,
    "SupervisorId": "SUP001",
    "LocationID": 3,
    "CampaignId": 45,
    "IsAccessIPBased": "false",
    "IsAccessLocationBased": "false",
    "IsPartnerAllowed": "false",
    "IsSupervisor": "false"
}

Description for Request Parameters

S.No Name Type Description Is Required?
1 EmpSrId Integer Employee Serial ID generated during user creation Yes
2 EmpId String Employee ID Yes
3 UserName String Username of the user Yes
4 Email String Email address of the user Yes
5 EmpType String Type of employee Yes
6 FirstName String First name of the employee Yes
7 LastName String Last name of the employee Yes
8 RoleId Integer Role assigned to the user Yes
9 SupervisorId String Employee ID of the supervisor Yes
10 LocationID Integer Location assigned to the user Yes
11 CampaignId Integer Campaign assigned to the user Yes
12 IsAccessIPBased Boolean (String) Enables IP-based login restrictions Yes
13 IsAccessLocationBased Boolean (String) Enables location-based access restrictions Yes
14 IsPartnerAllowed Boolean (String) Indicates whether partner access is enabled Yes
15 IsSupervisor Boolean (String) Indicates whether the user is a supervisor Yes

Validation Rules

Field Validation Rule
EmpSrId Required and must reference an existing user
EmpId Required, maximum 25 characters
UserName Required, maximum 512 characters
Email Must be a valid email address
FirstName Required, maximum 100 characters
LastName Required, maximum 100 characters
EmpType Required, maximum 25 characters
IsAccessIPBased Must be “true” or “false”
IsAccessLocationBased Must be “true” or “false”
IsPartnerAllowed Must be “true” or “false”
IsSupervisor Must be “true” or “false”

3. Response Examples

Success

</> JSON
{
    "Message": "User updated successfully."
}

Status Codes

Code Status Description
200 Success User updated successfully

Response Parameters

S.No Name Type Description
1 Message String Status message returned by the API

Failure 

</> JSON
Validation Error

{
  "Message": "The request is invalid."
}
</> JSON
User Not Found / Invalid Employee Serial ID

{
  "Message": "User record not found."
}

Status Codes

Code Status Description
400 Bad Request Validation failure
401 Unauthorised Invalid or expired authentication token
406 Not Acceptable Exception occurred while processing the request
500 Internal Server Error Exception occurred while processing the request

Notes

  • Authentication is mandatory for accessing this API.
  • EmpSrId is required to identify the user record to be updated.
  • Only existing user records can be updated.
  • A valid Role ID, Campaign ID, Location ID, and Supervisor ID must be provided.
  • Boolean fields must be passed as string values: “true” or “false”.
  • Set IsSupervisor = “true” to designate the user as a supervisor.
  • Set IsAccessLocationBased = “true” to restrict user access based on assigned locations.
  • Set IsAccessIPBased = “true” to enforce IP-based login restrictions.
  • The API returns a success message upon successful completion of the update operation.

    ×

    Contact Us