Government Legal
USAspending.gov logo

USAspending.gov API

usaspending.gov

US federal spending - award search, agency profiles, budgetary resources, and spending breakdowns.

Actions
11
Category
Government Legal
Login
Not required
Output
JSON

Call the USAspending.gov API

Submit a task, then poll the job until it settles. This example runs act_usaspending_gov_agency_budgetary_resources.

curl -X POST https://api.anakin.io/v1/wire/task \
  -H "X-API-Key: $ANAKIN_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "action_id": "act_usaspending_gov_agency_budgetary_resources",
    "params": {
      "toptier_code": "020"
    }
  }'

11 actions on usaspending.gov

Read

  • Agency Budgetary Resources

    act_usaspending_gov_agency_budgetary_resourcesread1 credit / call

    Returns multi-year budgetary resources, obligations, and outlays for an agency.

    toptier_code
    string · required
  • Agency Directory Ranked

    act_usaspending_gov_agency_directory_rankedread1 credit / call

    Returns all toptier agencies ranked by share of total budget authority.

    sort
    string
    order
    string
  • Agency Profile Overview

    act_usaspending_gov_agency_profile_overviewread1 credit / call

    Returns an agency profile with mission, website, fiscal-year totals, and metadata.

    toptier_code
    string · required
    fiscal_year
    integer · required
  • Award Details

    act_usaspending_gov_award_detailread1 credit / call

    Returns full award details with obligations, recipient, contract metadata, and dates.

    award_id
    string · required
  • Sub Agency Spending

    act_usaspending_gov_agency_sub_agency_spendingread2 credits / call

    Returns ranked sub-agency spending with obligation totals and transaction counts.

    toptier_code
    string · required
    fiscal_year
    integer · required
    page
    integer
    limit
    integer
    sort
    string
    order
    string

Write

Write actions change state on usaspending.gov and run as the account you connect.

  • Award Federal Accounts

    act_usaspending_gov_award_federal_accountswrite2 credits / call

    Returns the federal account funding breakdown and obligated amounts for an award.

    award_id
    string · required
    page
    integer
    limit
    integer
    sort
    string
    order
    string
  • Award Funding Rollup

    act_usaspending_gov_award_funding_rollupwrite2 credits / call

    Returns aggregated funding totals and agency and account counts for an award.

    award_id
    string · required
  • Award Search

    act_usaspending_gov_award_search_listingwrite2 credits / call

    Searches federal awards by date and type, returning recipients, amounts, and award IDs.

    time_period_start
    date · required
    time_period_end
    date · required
    award_type_codes
    array · required
    page
    integer
    sort
    string
    order
    string
    limit
    integer
  • Award Transactions

    act_usaspending_gov_award_transactions_listingwrite2 credits / call

    Returns an award's transaction and modification history with obligation amounts.

    award_id
    string · required
    page
    integer
    sort
    string
    order
    string
    limit
    integer
  • Spending By Agency

    act_usaspending_gov_spending_by_agency_rankingwrite2 credits / call

    Returns top awarding agencies ranked by obligated spending over a date range.

    time_period_start
    date · required
    time_period_end
    date · required
    page
    integer
    limit
    integer
  • Spending By Budget Function

    act_usaspending_gov_spending_by_budget_functionwrite2 credits / call

    Returns total federal spending broken down by budget function category.

    fiscal_year
    integer · required
    fiscal_period
    integer · required

USAspending.gov API questions

Is there an API for USAspending.gov?
USAspending.gov does not offer a public data API for this, but Anakin Wire provides 11 maintained endpoints for usaspending.gov. You call Anakin's REST API with an action ID and parameters and get structured JSON back; Anakin handles the browser, proxies, anti-bot, and parsing.
How do I scrape USAspending.gov data?
POST to https://api.anakin.io/v1/wire/task with your API key, the action ID, and its parameters, then poll GET /v1/wire/jobs/{id} until the job settles. There is nothing to install and no scraper to maintain — when usaspending.gov changes its markup, Anakin updates the action.
Do I need a USAspending.gov account?
No. Every USAspending.gov action listed here runs anonymously — no account and no credentials required.
What does the USAspending.gov API cost?
Usage-based credits, charged per call and refunded automatically when a job fails. New accounts start with 300 free credits and no card. See anakin.io/pricing for the current rates.

More Government Legal APIs

All Government Legal sites