Create Admin
An overview of the Create Admins Endpoint
Endpoint Description
The "Create Admin" endpoint facilitates the addition of new administrative users to the R1 Discover platform. These administrators have the capability to manage user accounts and access detailed user data, playing a critical role in the oversight and operational management within R1 Discover.
HTTP Method
POST /api/v1/companies/{companyId}/admins
Headers
Content-Type:
application/json
- Specifies the format of the body of the request.Accept:
application/json
- Indicates that the response should be in JSON format.Authorization:
Bearer {token}
- A valid Bearer token is required to authenticate the request and authorize the creation of an administrator.
URL Parameters
companyId (integer): The identifier for the company under which the admin is being created. This must correspond to an existing company within the R1 Discover system.
Body Parameters
admin_id (string): A unique identifier for the admin, typically provided by an integration partner system as our shared unique ID. Must be unique within R1 Discover.
admin_username (string): The username for the new admin. This must be unique within R1 Discover. See Check Global Username Availability
admin_email (string): The email address of the admin. This will be used for login and communication purposes. This must be unique within R1 Discover.
admin_type (string): Describes the role or type of the admin and indicates if User's can be aligned to them via the Practitioner assignment. Available options:
Practitioner: Access to manage and review user activities relevant to their programs. Only a practitioner can have users aligned to them.
Company Admin: Label for reporting, Admin Role sets permissions, see Permission Matrix.
Compliance Officer: Label for reporting, Admin Role sets permissions, see Permission Matrix.
Executive Team: Label for reporting, Admin Role sets permissions, see Permission Matrix.
Other: Label for reporting, Admin Role sets permissions, see Permission Matrix.
admin_location (string): The primary office or location with which the admin is associated. This should correspond to a predefined location within the company's structure in R1 Discover. See View Company Locations.
Designates the location the admin can view user data.
admin_program (string): The primary program or department to which the admin is assigned. This should correspond to a predefined program within the company's structure in R1 Discover. See View Company Programs.
Designates the program the admin can view user data.
admin_status (string): The status of the admin account, typically "active" or "inactive".
Request Examples
curl --request GET \
--get "https://api.r1learning.com/api/v1/view-company-practitioners/1/1/50" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--header "Authorization: Bearer {token}"
Response Examples
{
"error": 0,
"message": "Admin created successfully",
"data": {
"username": "newadmin",
"email": "[email protected]"
}
}
Notes
Authorization Required: Ensure the provided Bearer token is valid and has sufficient privileges to create an admin.
Data Validation: All body parameters must be correctly formatted and complete. The system will validate these parameters and reject requests with missing or invalid data.
Uniqueness Required: The
admin_id
,admin_username
andadmin_email
must be unique within the system to prevent conflicts.
Last updated