For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Truework.comAPI StatusGet your API key
HomeGuidesAPI referenceHelp
HomeGuidesAPI referenceHelp
    • Overview
    • Methods
    • Workflows
  • Target Employer API
    • Quickstart
  • Truework Direct API
    • Quickstart
    • Truework.js API reference
  • Mortgage Recipes
    • Truework for Mortgage
    • Truework LOS Integrations
    • Truework POS Integrations
LogoLogo
Truework.comAPI StatusGet your API key
On this page
  • Prerequisites
  • Creating an order
  • Listening for webhooks
  • Order completed webhook
  • Getting an order
  • Moving to production
  • Questions?
Target Employer API

Make your first Target Employer Order

Was this page helpful?
Previous

Quickstart

Next
Built with

Truework’s Target Employer Order API enables you to seamlessly integrate robust verification capabilities directly into your application. In this guide, we’ll explore how to use the Truework Sandbox—a risk-free playground where you can test your integration without touching production data. Get ready to dive in and make your first request with ease!

Prerequisites

  • Set up a Truework account
  • Generate a Sandbox API Key and webhook token under developer settings from your Truework account
  • Note the base URL for the Truework Sandbox is https://api.truework-sandbox.com

Creating an order

To create a verification request from your backend application, make a POST request to /orders/target-employer using a tool like curl, Postman, or via our built-in API Explorer. Making this POST request creates an order that will contain a single verification for the requested employer.

The /orders/target-employer endpoint processes your order asynchronously. Although you will receive a response instantly, there will be no reports associated with the verification on the order. You will need to retrieve the report(s) once the order is completed, which is detailed in the next section.

Request
Response
POST
/orders/target-employer
1curl -X POST https://api.truework-sandbox.com/orders/target-employer \
2 -H "Authorization: Bearer <token>" \
3 -H "Content-Type: application/json" \
4 -d '{
5 "permissible_purpose": "child-support",
6 "target": {
7 "company": {
8 "name": "Acme Inc",
9 "address": {
10 "address": "1234 Rainbow Road",
11 "city": "San Francisco",
12 "country_code": "US",
13 "country_subdivision_code": "CA",
14 "postal_code": "98265"
15 }
16 },
17 "first_name": "Jane",
18 "last_name": "Doe",
19 "social_security_number": "000-00-0000"
20 },
21 "type": "employment-income",
22 "use_case": "mortgage"
23}'
Try it

Once created, copy the string returned in the id field—we’ll need it for the next step.

Listening for webhooks

Truework uses webhooks to asynchronously update our partners when a verification is completed. Webhooks are configured under developer settings in the Truework app.

There are two types of webhooks: order completed and verification state change.

Of interest will mostly be the states completed and canceled:

  • A completed state indicates that new data is now available on the order
  • A canceled state indicates that a verification was not able to be completed, but may have user-provided information and/or documents

Order completed webhook

The order.completed webhook will be issued when all employer verifications associated with the order have been completed or canceled. Once you receive this webhook, you can fetch the order results.

1{
2 "hook": {
3 "id": 50,
4 "event": "order.completed",
5 "target": "https://example.com/webhook"
6 },
7 "data": {
8 "order_id": "AAAAAAAAAosABwGqF1AUKAH0-puth1tCzLNar3Jyb4bx3wdVKU99XC26",
9 }
10}

Getting an order

Now that you’ve created an order and copied its ID, we can get it from the API to see its current state and other data. To do so, we will need to make an HTTP GET request to the /orders/{order_id} endpoint.

Request
Response
GET
/orders/:order_id
1curl https://api.truework-sandbox.com/orders/order_id \
2 -H "Authorization: Bearer <token>"
Try it

After retrieving your order, you should observe the following:

  • The verification_requests list in the order includes one verification with a completed state
  • The reports field of the verification contains a Verification of Employment and Income (VOIE) report
  • If you set up a webhook logger, you should see that the order.completed webhook has been triggered

These actions occurred because a special SSN value (000-00-0000) was used in the sandbox environment, which automatically processed and completed the verification. You can learn more about the SSNs available for use in the sandbox here.

Moving to production

A general API service account is recommended to manage the integration (e.g. truework@yourcompany.com).

When your integration is complete (or nearing completion), follow the steps below:

  • Generate your production API Key and webhook token under developer settings from your Truework account
  • Change the base URL for all backend API calls to Truework from https://api.truework-sandbox.com to https://api.truework.com
  • Notify implementations@truework.com you are ready to move to production at least three (3) days prior to the target go live date

Questions?

Not a problem, we are here to help! Send your questions to implementations@truework.com.