Economy

Search US federal contract awards

Search US federal contract awards by recipient, keyword, NAICS, PSC and state: amount, agency, dates, codes and places, up to 100 a page with a cursor.

GET/v1/economy/government-contracts
1credit
x-api-keystringheader

API key (`sfk_...`)

Parameters
12
recipientstringquery

Company or organisation name, matched as text against the recipient's legal name, e.g. `Lockheed Martin`. Contracts are filed under legal names: `Space Exploration Technologies` finds SpaceX, `SpaceX` does not.

min 2 chars · max 120 chars

keywordstringquery

Text matched against award descriptions, e.g. `cybersecurity`. 3 to 120 characters.

min 3 chars · max 120 chars

naicsarrayquery

NAICS industry codes, comma-separated, up to 20. Each has 2, 4 or 6 digits; a shorter code covers its whole family, e.g. `4811` (scheduled air transport) or `54`.

pscarrayquery

Federal product and service codes (PSC), comma-separated, up to 20. 1 to 4 characters; a shorter code covers its family, e.g. `D3` (IT services) or `R425`.

statestringquery

Only contracts performed in this state, as a two-letter USPS code, e.g. `VA`.

one of: AL, AK, AZ, AR, CA, CO, CT, DE, DC, FL, GA, HI, ID, IL, IN, IA, KS, KY, LA, ME, MD, MA, MI, MN, MS, MO, MT, NE, NV, NH, NJ, NM, NY, NC, ND, OH, OK, OR, PA, RI, SC, SD, TN, TX, UT, VT, VA, WA, WV, WI, WY, AS, GU, MP, PR, VI

typestringquery

`all` (default), `definitive_contract`, `purchase_order`, `delivery_order` or `bpa_call`.

one of: all, bpa_call, purchase_order, delivery_order, definitive_contract

fromstringquery

Start of the window, `YYYY-MM-DD`, not before `2007-10-01`. A contract matches when it had activity in the window. Without `from` and `to`: the latest US federal fiscal year (1 October to 30 September) that ended at least 90 days ago. With only `from`: to today.

pattern: ^\d{4}-\d{2}-\d{2}$

tostringquery

End of the window, `YYYY-MM-DD`. With only `to`: the year up to that day.

pattern: ^\d{4}-\d{2}-\d{2}$

sortstringquery

`amount` (default), `start_date`, `end_date` or `recipient`.

one of: amount, start_date, end_date, recipient

orderstringquery

`desc` (default) or `asc`.

one of: desc, asc

limitintegerquery

Contracts per page, 1 to 100. Default 25.

≥ 1 · ≤ 100

cursorstringquery

Cursor from `page.nextCursor` of the previous response. It only works with the same filters, sort and order.

min 1 chars · max 512 chars

Response fields
63

Endpoint-specific response payload.

datafrom
string

Start of the window used, `YYYY-MM-DD`.

datato
string

End of the window used, `YYYY-MM-DD`.

datatotal
integernullable

Contracts matching the search; null when the count could not be read this time.

≥ 0

Contracts on this page, in the order asked for.

dataawards[]id
string

Unique award id, e.g. `CONT_AWD_N0001917C0001_9700_-NONE-_-NONE-`.

min 1 chars

dataawards[]awardId
stringnullable

The contract number (PIID), e.g. `N0001917C0001`.

dataawards[]url
string

The award's page on USAspending.gov.

min 1 chars

dataawards[]type
stringnullable

Contract type.

one of: definitive_contract, purchase_order, delivery_order, bpa_call, other, null

dataawards[]recipientName
stringnullable

Recipient's legal name.

dataawards[]recipientUei
stringnullable

Recipient's Unique Entity Identifier (UEI).

dataawards[]amount
numbernullable

Total obligated to the award so far, in US dollars (not only within the window).

dataawards[]outlays
numbernullable

Total paid out so far, in US dollars, when reported.

dataawards[]description
stringnullable

What the contract is for.

dataawards[]startDate
stringnullable

Start date, `YYYY-MM-DD`.

dataawards[]endDate
stringnullable

Current end date, `YYYY-MM-DD`.

dataawards[]signedDate
stringnullable

Date of the base award's first obligation, `YYYY-MM-DD`.

dataawards[]lastModifiedAt
stringnullable

When the award record last changed, ISO 8601.

dataawards[]awardingAgency
stringnullable
dataawards[]awardingSubAgency
stringnullable
dataawards[]fundingAgency
stringnullable
dataawards[]fundingSubAgency
stringnullable

Industry (NAICS) code.

dataawards[]naicscode
string

The code.

min 1 chars

dataawards[]naicsdescription
stringnullable

What the code means.

Product or service code (PSC).

dataawards[]psccode
string

The code.

min 1 chars

dataawards[]pscdescription
stringnullable

What the code means.

A place, as the award records it.

dataawards[]placeOfPerformancecity
stringnullable
dataawards[]placeOfPerformancecounty
stringnullable
dataawards[]placeOfPerformancestate
stringnullable

USPS state code; null abroad.

dataawards[]placeOfPerformancestateName
stringnullable
dataawards[]placeOfPerformancezip
stringnullable

5-digit ZIP code.

dataawards[]placeOfPerformancecountry
stringnullable

ISO 3166-1 alpha-3 country code, e.g. `USA`.

dataawards[]placeOfPerformancecountryName
stringnullable
dataawards[]placeOfPerformancecongressionalDistrict
stringnullable

Congressional district number within the state.

A place, as the award records it.

dataawards[]recipientLocationcity
stringnullable
dataawards[]recipientLocationcounty
stringnullable
dataawards[]recipientLocationstate
stringnullable

USPS state code; null abroad.

dataawards[]recipientLocationstateName
stringnullable
dataawards[]recipientLocationzip
stringnullable

5-digit ZIP code.

dataawards[]recipientLocationcountry
stringnullable

ISO 3166-1 alpha-3 country code, e.g. `USA`.

dataawards[]recipientLocationcountryName
stringnullable
dataawards[]recipientLocationcongressionalDistrict
stringnullable

Congressional district number within the state.

Pagination state.

datapagehasMore
boolean

Whether another page exists.

datapagenextCursor
stringnullable

Cursor for the next page; null on the last page.

Where the data comes from and how to credit it when you reuse it.

datasourcepublisher
string

Who publishes the data, e.g. `Eurostat`.

min 1 chars

datasourcedataset
stringnullable

The publisher's dataset code, when it has one.

datasourcetitle
stringnullable

The dataset's title.

datasourceupdatedAt
stringnullable

When the publisher last updated the data, ISO 8601.

datasourceurl
stringnullable

Where the data can be viewed.

datasourcelicence
string

The terms the data is published under.

min 1 chars

datasourceattribution
string

Credit line the licence asks for when you reuse or publish the data.

min 1 chars

Metadata describing the request and billing outcome.

metarequestId
string

Unique request identifier for tracing this API call.

min 1 chars

metacreditsCharged
integer

Credits charged for this request.

≥ 0

metaversion
string

Public API version that served the response.

one of: v1

metastale
booleanoptional

Present, and `true`, only when the source couldn't be reached and this is the last good answer for the same request instead, up to 24 hours old. Absent on every live answer.

one of: true

metafetchedAt
stringoptional

When a stale answer (`stale: true`) was originally fetched (ISO 8601, UTC). Absent on every live answer.

Code example

curl "https://api.socialfetch.dev/v1/economy/government-contracts?recipient=Lockheed%20Martin" \
  -H "x-api-key: YOUR_API_KEY"

Responses

A page of contract awards.