---
title: BambooHR
description: Follow these steps to configure BambooHR data collection in OpenLM Cloud Broker.
product: OpenLM Platform
---

## Configure data collection

Follow these steps to configure BambooHR data collection in OpenLM Cloud Broker.

:::info
BambooHR uses OAuth 2.0 for authentication. You must create a BambooHR application to obtain the required credentials.
:::

### Step 1: Gather required BambooHR information

From your BambooHR account, collect the following:

- **Company subdomain**  
  If you access BambooHR at `https://mycompany.bamboohr.com`, the subdomain is `mycompany`.

- **OAuth application credentials**
  - Client ID  
  - Client secret  
  - Redirect URI  

For detailed setup instructions, see the official BambooHR documentation:  
https://documentation.bamboohr.com/docs/getting-started#section-authentication

### Step 2: Authorize the application

Initiate the authorization request using a browser or `curl`:

```
https://<company-domain>.bamboohr.com/authorize.php?request=authorize&state=new&response_type=code&scope=<scopes separated by +>&client_id=<your client ID>&redirect_uri=<your redirect URI>
```

After authorization, BambooHR redirects to the specified `redirect_uri` with a temporary authorization code:

```
?code=<temporary authorization code>
```

:::tip
Store the authorization code securely. You need it only once to generate the initial access token.
:::

### Step 3: Generate an access token

Exchange the authorization code for an access token.

**Endpoint**
```
https://<company-domain>.bamboohr.com/token.php?request=token
```

**Request body**
```json
{
  "client_secret": "<your client secret>",
  "client_id": "<your client ID>",
  "code": "<temporary authorization code>",
  "grant_type": "authorization_code",
  "redirect_uri": "<redirect URI>"
}
```

**Response**
```json
{
  "access_token": "<temporary access token>",
  "expires_in": 3600,
  "token_type": "Bearer",
  "scope": "<scopes separated by space>",
  "refresh_token": "<temporary refresh token>",
  "id_token": "<unique ID>",
  "companyDomain": "<your company domain>"
}
```

Use the `access_token` for subsequent API calls. In tools such as Postman, select **Bearer Token** and paste the access token into the **Token** field.

:::note
The `refresh_token` is returned only if you included the `offline_access` scope in the authorization request.
:::

### Step 4: Refresh the access token (optional)

If the access token expires, use the refresh token to obtain a new one.

**Endpoint**
```
https://<company-domain>.bamboohr.com/token.php?request=token
```

**Request body**
```json
{
  "client_secret": "<your client secret>",
  "client_id": "<your client ID>",
  "refresh_token": "<temporary refresh token>",
  "grant_type": "refresh_token",
  "redirect_uri": "<redirect URI>"
}
```

### Step 5: Add credentials in OpenLM

1. Open the **OpenLM Cloud Broker** dashboard.
2. Locate the **BambooHR** integration.
3. Enter the following values:
   - BambooHR company domain  
   - API access token  

*BambooHR credentials configuration*

### Step 6: Verify and approve the connection

1. Test the connection to confirm that OpenLM can retrieve data.
2. Approve the new data source in the **License Servers** section.

:::tip
Once approved, BambooHR usage data becomes available in the OpenLM Allocation service.
:::

## Approve BambooHR in OpenLM Platform

1. Sign in to OpenLM Platform.
2. From the menu, go to **License Servers** → **Pending Server**.
3. Select the BambooHR data source, then select **Approve and Merge**.

## Verify the integration

1. In OpenLM Platform, go to **Allocation**.
2. Confirm BambooHR usage data appears.

:::note
It can take up to 3 minutes for data to appear after approval.
:::

## Viewing reports

- **User activity trends** — see which users are most active in the platform; reallocate seats accordingly.
- **Expired or unused licenses** — identify inactive users and reclaim their seats.

## Reference

- [Broker Hub](https://openlm.com/documentation/cloud/data-collection/broker-hub)
