ready-made APIby Neha Gonzalez

USAspending Federal Awards & Spending

usaspending.gov

Search US federal contract and other awards with filters, get full award details, list top-tier agencies with budget authority, group spending by category, search recipients and subawards, and find awards by recipient UEI.

Writ CloudRESTMCPwebhookschedule2 credits / call

No website sign-in or persona needed. Free to install. Try any function below with your own values, no account: 10 free credits a day per device. Cloud calls after that use your own credits. Pricing →

The name usaspending.gov belongs to its owner. This API is not affiliated with, endorsed by or sponsored by usaspending.gov. You are responsible for how you use it.

01 · Functions7 functions

The form is the docs.

Choose a function, fill in its inputs, and run it: the answer comes back from the live site, with your values. Without an account you get 10 free credits a day per device for this; install the listing in Writ to keep calling it.

7 functionschoose one to explore
01search_awardsSearch for government awards with advanced filtering. Returns paginated results of contracts and other award types. Supports keyword search and complex filter objects including time_period, award_type_codes, and agencies. If award_type_codes is not specified in filters, defaults to contracts (A, B, C, D).02get_award_detailsGet comprehensive details for a specific award including recipient info, contract data, period of performance, and funding/awarding agency details. Returns the full award record from USASpending.gov given a generated_internal_id from search_awards results (the same identifier get_awards_by_recipients emits as generated_unique_award_id).03list_agenciesList all federal toptier agencies with budget authority amounts for the current active fiscal year and quarter. Returns agencies sorted by the specified field. Each agency includes budget_authority_amount, percentage_of_total_budget_authority, and agency_slug for further lookups.04search_spending_by_categorySearch for spending grouped by a category such as awarding agency, recipient, or geographic area. A default time_period filter covering the past year is applied if none is provided in filters. Returns the top results by amount for the chosen category.05search_recipientsSearch for award recipients by name via autocomplete. Returns matching recipient names with optional UEI and DUNS identifiers. Useful for finding the exact recipient name to use in award filters.06search_subawardsSearch for government subawards with advanced filtering. Returns paginated results of subcontracts and subgrants under prime awards. Supports keyword search and complex filter objects including time_period, award_type_codes, prime_award_id, prime_recipient_name, subawardee_name, and awarding_agency. If award_type_codes is not specified in filters, defaults to contracts (A, B, C, D).07get_awards_by_recipientsReturns full award detail records for every award whose recipient matches one of the supplied UEIs and that had transaction activity (action dates) inside the given date range; an award signed before start_date still matches when it was modified within the range. One call performs one award search for the requested page, one count lookup, and then one detail lookup per matched award, so the cost grows with `limit` (capped at 20 per page). Each entry in `awards` is the same full award record shape that get_award_details returns, plus `search_recipient_uei` naming which requested UEI the award matched; `errors` lists awards on the page whose detail lookup failed (with the award's generated_internal_id and upstream status), `coverage` summarises matched/fetched/failed counts for the page, and `page_metadata` carries `hasNext` for continuation and `total` (the site's count of matching awards in the requested award type group, null if the count lookup fails). Results are ordered by award amount descending. Award types must all belong to one group (e.g. contracts A,B,C,D, or grants 02,03,04,05); mixing groups is rejected. An empty `awards` list with `coverage.matched_on_page` 0 means no awards matched (for example a contractor UEI queried with grant type codes). Omitting `page` starts at page 1; the site limits searches to dates on or after 2007-10-01.
When a call does not work
No key · GET

AI assistants and tools that can only open a URL can call it with no key: one URL per function, its inputs in the query string. Each call spends the free keyless allowance, 10 credits a day per IP address.

GET https://api.usewrit.app/api/marketplace/listings/usaspending-federal-awards-spending/run?function_name=search_awardsGET https://api.usewrit.app/api/marketplace/listings/usaspending-federal-awards-spending/run?function_name=get_award_details&award_id=<award_id>GET https://api.usewrit.app/api/marketplace/listings/usaspending-federal-awards-spending/run?function_name=list_agencies&sort=percentage_of_total_budget_authority&order=descGET https://api.usewrit.app/api/marketplace/listings/usaspending-federal-awards-spending/run?function_name=search_spending_by_category&category=awarding_agencyGET https://api.usewrit.app/api/marketplace/listings/usaspending-federal-awards-spending/run?function_name=search_recipientsGET https://api.usewrit.app/api/marketplace/listings/usaspending-federal-awards-spending/run?function_name=search_subawards&page=1&limit=10GET https://api.usewrit.app/api/marketplace/listings/usaspending-federal-awards-spending/run?function_name=get_awards_by_recipients&page=1&ueis=<ueis>&limit=10&end_date=<end_date>&start_date=<start_date>&award_type_codes=A%2CB%2CC%2CD
02 · Checks and timingsmeasured per function

Built to be called again.

Every function was called on the live site before this API was published, and keeps being measured. The numbers are the listing’s own.

—typical callnot measured yet
—measured runsacross 7 functions
—daily checks passedchecks start with the first install
—buyer runs succeededno counted buyer runs yet
functionmedian · 95th percentilemedianruns
search_awards Not measured —
get_award_details Not measured —
list_agencies Not measured —
search_spending_by_category Not measured —
search_recipients Not measured —
search_subawards Not measured —
get_awards_by_recipients Not measured —
Checked daily No daily check results published yet. Checks begin with the first install; no pass rate is claimed.
Repaired when it breaks A function that fails its check is re-tested and rebuilt. Installed copies receive the update; you redeploy nothing.
Buyer runs counted No counted buyer runs published yet; uptime counts real buyers’ runs only. Writ service status →

Historical measurements from the public listing, refreshed Dec 4, 2026. Timing samples are not an uptime claim or a guarantee for your next call.

03 · Your copyyour account

Install your copy. Call it your way.

2 credits
Priced per cloud call.

The listing’s base price is 2 credits per call. Longer runs, residential traffic and CAPTCHA solving can add usage. A site or Writ failure is free; your own input or login failures can be billable. Full usage rates →

cloud
No computer to keep running.

Marketplace copies execute in Writ Cloud, in your own account. Requirements and prices are checked before you use the listing.

REST · MCP
Every way to call it, at once.

Use your API key, connect an assistant, set a schedule with email or webhook delivery, or export answers as a dataset.

read-only
It only reads.

The published functions read data from the source website. No website sign-in or persona is needed for this listing.

private copy
Your account, your usage.

Your installed copy belongs to your account. Its underlying recipe stays sealed with its creator; no creator credentials are included.

04 · Or build your ownwebsite → API

Missing a function? Describe it.

Give Writ a website and say what you want. It builds and tests the API for your task.

On your computeryour machine

Build it in Writ Desktop and run it from your own IP. Execution on your machine costs 0 credits.

Get Writ Desktop →
In Writ Cloudcloud

Keep your API online without leaving your computer running. Cloud calls start at 2 credits, or 20 with a browser.

Build an API →
05 · More ready-madeAll APIs →
06 · Questions
Does USAspending have an API?
This page is an independent API and MCP server for usaspending.gov: Writ built it on the site’s public pages and tests it, and it has 7 functions you can call today. It is not an official USAspending product. For an official API, check USAspending’s own developer pages.
How do I use the USAspending API from Claude, ChatGPT or Cursor?
Install it in Writ, then add Writ’s MCP server (https://api.usewrit.app/mcp) to Claude, ChatGPT, Cursor or any MCP client: your assistant can run this API’s functions and read the results. From your own code, call the same functions over REST with a Writ API key.
How much does a call to the USAspending API cost?
2 credits per call, charged only when the call succeeds. New accounts start with 1,000 free credits, then 500 a month on the Free plan, no card.