Custom Integrations

Fountain Hire integrates with custom elements of your workflow through a combination of webhooks and PUT requests. Webhooks are used when external action is needed when an applicant arrives at a particular stage.

Use the Fountain One OAuth flow with the employer scope. Replace ACCESS_TOKEN in these examples with the resulting access token. Keep Fountain credentials and API calls server-side.

Headers configured for an outbound third-party webhook authenticate requests to that third party. They are separate from the Fountain Bearer token used when your server calls Fountain; do not send Fountain credentials to the third-party webhook URL.

Example: When the applicants reach a particular stage, fire a webhook which will send them a text to download an app. When they do, update a label in Fountain Hire.


1. Fire a webhook trigger

When an applicant lands in a particular stage (Rejected in this example), a trigger fires to a third-party webhook URL with all of the applicant's details. In this example, we want phone number and type so we can send them a text with a link to the app. The payload is delivered as a JSON object which includes the applicant's UUID, which identifies the applicant in subsequent API requests.

2450

2. Third-party sends applicant a text

With the applicant's phone number, the third-party provider sends the applicant a text message to download the app based on the phone type.

3. Complete the label with a PUT request

When the applicant downloads and signs into the app with their Fountain email address, the third-party provider sends a PUT request to Fountain to update the 'App Downloaded' label. If the 'Auto-Advance when all labels are checked' setting is on in your manual stage (you can toggle this in the Workflow Editor), the applicant automatically moves on to the next stage.

curl -X PUT -H 'Content-Type: application/json' -H 'Authorization: Bearer ACCESS_TOKEN' -d '{"completed":true}' 'https://services.fountain.com/api/servicehire/v2/applicants/22222222-0000-0000-0000-000000000000/labels/App%20Downloaded'

4. Want to add applicant data?

If you wish to append data to the applicant, do so with another PUT request before auto-advancing the applicant.

Example: Using our API and a filter in your workflow, you can reject applicants from third-party sources. For this example, you'll need applicants in a stage before the Rejected stage. In this example let's call this Manual stage.

1. Set up your label

First, set up a label which signifies the completion of your Manual stage. Make sure the 'Auto-Advance when all labels are checked' setting is on.

2. Make a filter

You'll need to create a filter based on some field that you'll set for the applicant via PUT. Here, we simply call it "reject" - if an applicant passes into the filter with reject = "not experienced", they'll be rejected with that reason.

783

3. Set your filter field with a PUT request

Next set the field your filter uses for an applicant in the Manual stage (use List Applicants to get applicant IDs).

curl -X PUT -H 'Content-Type: application/json' -H 'Authorization: Bearer ACCESS_TOKEN' -d '{"data":{"reject":"not experienced"}}' 'https://services.fountain.com/api/servicehire/v2/applicants/c6786558-1b20-4e44-b303-75e21b965ed7'

4. Complete the label with a PUT request

Finally, set the label you made to completed. The applicant will move into the filter, then they'll be pushed into Rejected stage.

curl -X PUT -H 'Content-Type: application/json' -H 'Authorization: Bearer ACCESS_TOKEN' -d '{"completed":true}' 'https://services.fountain.com/api/servicehire/v2/applicants/22222222-0000-0000-0000-000000000000/labels/reviewed'