List All Employees
GEThttps://api.uber.com/v1/business/organizations/{organization_id}/employees
¶ Use Case
The Get Employees endpoint allows you to get a paginated list of employees of the organization.
¶ Authorization
The Get Employees endpoint requires an access_token using the client credentials (for 1P use-case)
grant to business.employees
scope.
If an application follows third party authentication, the get employees endpoint requires the client to get authorized using the authorization endpoint
¶ Path Parameters
Name | Type | Optional | Description |
---|---|---|---|
organization_id |
string | No | Identifier for your organization. |
¶ Query Parameters
Name | Type | Optional | Description |
---|---|---|---|
limit |
int | No | The number of employees in a page. Note: Default value is 50 . The maximum allowed value is 1000 |
start_key |
string | No | The page token of the employees. |
¶ Response Fields
Name | Type | Description |
---|---|---|
employees |
array | A list of employees objects. |
employees[].first_name |
string | First name of the employee. |
employees[].last_name |
string | Last name of the employee. |
employees[].email |
string | Email id of the employee. |
employees[].mobile_country_code |
string | The mobile country code of the employee. If no code is provided but mobile_number is provided, code of the organization will be taken as default code. |
employees[].mobile_number |
string | The mobile number of the employee. |
employees[].u4b_data |
object | Object containing employee data specific to uber for business. |
employees[].u4b_data.employee_id |
string | The employee ID of the employee. |
employees[].u4b_data.reviewer |
string | The email id of the reviewer. |
employees[].u4b_data.is_admin |
boolean | Check if employee is admin. |
employee.u4b_data.status |
string | The status of an employee Below are the possible values: CREATED INVITED LINKED_PENDING_APPROVAL LINKED SUSPENDED DELETED |
employees[].u4b_data.last_invite_timestamp |
string | The timestamp of the last invitation sent to the employee. Eg: “2022-09-28T06:58:46Z” |
employees[].u4b_data.invite_count |
int | Number of times the employee is invited to the Uber for Business Organization. Note: This field is only returned if the employee is not linked. |
employees[].u4b_data.groups |
array | List of groups the employee is in. Note: currently an employee can only be in one group. |
employees[].u4b_data.groups[].uuid |
string | Group UUID. |
employees[].u4b_data.groups[].name |
string | Group Name. |
next_start_key |
string | Page token for the next page. |
¶ Example Request
curl -X GET -H "Content-Type: application/json" \
-H "Authorization: Bearer <TOKEN>" \
"https://api.uber.com/v1/business/organizations/<organization_id>/employees"
¶ Example Response
Status-Code: 200 OK
{
"employees": [
{
"first_name": "test",
"last_name": "test",
"email": "testnew@uber.com",
"mobile_country_code": "+91",
"mobile_number": "1234567899",
"u4b_data": {
"employee_id": "test.test",
"reviewer": "test1@uber.com",
"is_admin": true,
"status": "LINKED",
"last_invite_timestamp": "2022-09-28T06:58:46Z",
"invite_count": 2,
"groups": [
{
"uuid": "uuid",
"name": "group-2"
}
]
}
},
{
"first_name": "test",
"last_name": "test",
"email": "testnew1@uber.com",
"mobile_country_code": "+91",
"mobile_number": "1234567899",
"u4b_data": {
"employee_id": "test.test",
"reviewer": "test1@uber.com",
"is_admin": true,
"last_invite_timestamp": "2022-09-28T06:58:46Z",
"invite_count": 2,
"groups": [
{
"uuid": "uuid",
"name": "group-2"
}
]
}
}
],
"next_start_key": "2"
}
¶ Error Responses
HTTP Status | Code | Description |
---|---|---|
400 | BAD_REQUEST |
request specific message |
401 | NOT_AUTHORIZED |
Caller not authorized to make this request |
429 | rate_limited |
Rate limit exceeded |
500 | INTERNAL_SERVER_ERROR |
We have experienced a problem |