Beginner's Guide

To use the API you must register at https://devtools.dol.gov/developer and request an API key for each application that will access the API. Registration and API keys are free.

note: A separate API key is not necessary for each application, but if you reuse your key across multiple apps, your apps' metrics will be combined and of little value.

Registration process

  • Visit https://devtools.dol.gov/developer
  • Click the Register link.
  • Fill in the registration form and submit it.
  • A confirmation email will be sent to the address you provided during registration.
  • Click on the link in the email to activate your developer account.

API Key (Token) Creation Process

  • Visit https://devtools.dol.gov/developer
  • At the login page, enter your username and password
  • Click on the My Tokens link
  • Click "Create New Token"
  • Provide a Shared Secret (deprecated, but for the moment still required for the registration process), Application Name, and a Description
  • The token value will be auto-generated and added to your tokens list.

Accessing the API

The API is exposed as an OData producer, with the addition of request authorizations. To make API calls you must supply a valid Token as the "KEY" parameter on the query string with every request. The current version of the API is backwards compatible. We are providing SDKs for some platforms that abstract the OData and request signing process and provides you with an easy to use method call. Please visit the open source code page to learn more about the Federal SDKs.
Example Assume that you want to read data from the Agencies table found in the dataset named DOLAgency. The request URL is: http://api.dol.gov/V1/DOLAgency/Agencies.

 

Your API Key (Token) is d9c6c290-da4c-424e-a378-fb4bd027b58b

note: This token is only an example. It is not usable.

 

Your direct link to Agency data using the input above is:
http://api.dol.gov/V1/DOLAgency/Agencies/?KEY=d9c6c290-da4c-424e-a378-fb4bd027b58b

Result Format

By default, the DOL API's responses are in XML format. To receive the data in JSON, send an "Accept" header with "application/json."

Next Steps

Following the steps above will return the first 100 records. To retrieve more or to be more selective in the data that is returned, read on about accessing the API using HTTP requests.