# SmartRecruiters

![SmartRecruiters Logo.png](https://assets.relyanceuat.xyz/images/docs/31341374613261/31341341043981.png)
SmartRecruiters is a cloud-based talent acquisition platform that streamlines the hiring process by offering tools for recruitment marketing, candidate management, and collaboration. It enables organizations to find, engage, and hire top talent efficiently with features like AI-powered sourcing, applicant tracking, and analytics.

In order to integrate SmartRecruiters with Relyance AI you will need either:

- An **API Key** and **Company ID**, or
- A **Client ID** and **Client Secret** (for OAuth).

#### In SmartRecruiters:

##### Option 1: API Key + Company ID

1. Login to SmartRecruiters as an admin.
2. Navigate to your Admin Settings.
3. Once you're on the Admin Settings page, look at the URL in your browser's address bar.
The **Company ID** is embedded within the URL.

![SmartRecruiters-3.png](https://assets.relyanceuat.xyz/images/docs/31341374613261/31341383298701.png)

4. Follow this [guide](https://developers.smartrecruiters.com/docs/authentication-api-key) to create an **API Key**.

##### Option 2: OAuth

1. Login to SmartRecruiters as an admin.
2. Go to **Credential Manager**.
3. Click **New Credential** and select **OAuth Client ID**.
4. Enter a name, description, and select the appropriate scopes.
5. Click **Generate**.
6. Copy the **Client ID** and **Client Secret** immediately (they cannot be retrieved later).

Official documentation:[SmartRecruiters OAuth 2.0 Client Credentials Guide](https://developers.smartrecruiters.com/docs/authentication-oauth-client-credential?utm_source=chatgpt.com)

##### **✅ Required Scopes for Relyance AI**

Relyance AI can use the following scopes when connecting via OAuth:

- users:read
- candidates_offers:read
- users_me:read
- jobs:read
- audit_events:read
- candidates:read
- reviews:read
- messages:read
- reporting:read

You don’t need to grant all of these scopes. Relyance AI will only scan and process the data that the selected scopes allow.

Full list of available scopes: [SmartRecruiters Access Scopes Reference](https://developers.smartrecruiters.com/docs/access-scopes?utm_source=chatgpt.com)

#### In the Relyance AI application:

1. Login to your Relyance account.
2. Navigate to the **Settings** Menu in the bottom left-hand side.
3. Select **Integrations**.
4. Find the **SmartRecruiters** integration card and click it to open its connections.
5. On the **Authentication** step, pick the method under **Authentication Method**.
6. Under **Connection → Authentication Step**, choose your authentication method:
    - If using **API Key**: select ***API Key*** from the dropdown and enter your **API Key** and **Company ID**.
    - If using **OAuth**: select ***OAuth (Client Credentials)*** and enter your **Client ID** and **Client Secret**.
7. Additional Features:
    - Select the **Enable Data Inspection** checkbox if you wish Relyance also to inspect the data. For more information on Relyance features, please refer to this help center article: [here](/docs/introduction-to-relyance-ai/integration-features/).
8. Click **Authenticate**.
9. At this point, you should see the following result on the integrations page:

![SmartRecruiters-2.png](https://assets.relyanceuat.xyz/images/docs/31341374613261/31341374610957.png)

10. Congratulations, you are now connected to **SmartRecruiters**.

<!-- failure-modes:begin (generated from the integration catalog; do not hand-edit) -->

## If the connection reports Connected but returns nothing

These are the ways this integration comes back empty without reporting an error. Generated from the integration catalog, so it tracks what the connection actually asks for.

1. **Authorised, then empty.** The connection carries an authorisation, not a password: it stops returning data if the account that granted it loses access, its own permissions narrow, or the grant is revoked at the vendor. None of that reports an error here -- the connection keeps its last status until the next scan.
2. **A credential rotated at the vendor is not picked up here.** **Client Secret** and **API Key** are stored when you save the connection, so regenerating the value at the vendor breaks the next scan until it is re-pasted here. Recording the expiry on the connection means Relyance warns you before it lapses.

<!-- failure-modes:end -->

<!-- auth-methods:begin (generated from the integration catalog; do not hand-edit) -->

## Authentication methods and fields

Pick one of these under **Authentication Method** on the connection wizard's **Authentication** step. This table is generated from the integration catalog, so it always matches what the form actually asks for.

| Method | Required | Optional |
| --- | --- | --- |
| **Oauth2 / App Token** | `Client ID`, `Client Secret` (secret) | — |
| **API Key** | `API Key` (secret) | `Company ID` |

<!-- auth-methods:end -->

<!-- terraform-examples:begin (generated from the integration catalog; do not hand-edit) -->

## Manage this integration with Terraform

Connections for this integration can be managed as code with the [Relyance Terraform provider](https://registry.terraform.io/providers/Relyance/relyance/latest). Non-secret fields go in `auth.params`; secret fields go in `auth.secrets_wo`, which is write-only — never stored in Terraform state. Rotate secrets by bumping `auth.secrets_wo_version`.

### OAuth (browser authorization)

The **OAuth (browser authorization)** method uses a browser authorization flow, so the connection is created in the Relyance app. Manage it in Terraform afterwards by importing it (`terraform import relyance_integration_connection.example smartrecruiters/<connection_id>`) or reading it with the `relyance_integration_connection` data source.

### API key

```hcl
resource "relyance_integration_connection" "smartrecruiters_1" {
  vendor = "smartrecruiters"
  name   = "<your connection name>"

  auth = {
    method = "api-key"
    params = {
      data_storage_location = "us"
    }
    # Secret fields are write-only: sent to Relyance, never stored in state.
    secrets_wo = {
      api_key = var.smartrecruiters_api_key
    }
    secrets_wo_version = 1
  }

  scans = { "data-inspection" = { enabled = true } }
}
```

<!-- terraform-examples:end -->
