USAspending.gov Recipient API

Recipient (awardee) profile and search data.

Documentation

Specifications

OpenAPI Specification

usaspending-recipient-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: USAspending Agency Recipient API
  description: The USAspending API provides free, public, unauthenticated access to U.S. federal spending data - contracts, grants, loans, direct payments, and other financial assistance awards, plus agency budgets, federal account (Treasury Account Symbol) data, recipient profiles, and disaster/emergency (including COVID-19) relief spending. USAspending.gov is operated by the Treasury Department's Bureau of the Fiscal Service to implement the DATA Act's federal spending transparency mandate. Most search and listing endpoints accept a POST with a JSON body describing filters, fields, sort, and pagination, because filter combinations are too complex for query strings; simpler single-resource lookups use GET with path parameters. This document is a representative, hand-authored subset of the full API grounded directly in the official API Blueprint contracts published in the usaspending-api GitHub repository - it is not a complete mirror of every endpoint and field.
  version: v2
  contact:
    name: USAspending.gov / Bureau of the Fiscal Service
    url: https://www.usaspending.gov
  license:
    name: Open source (CC0 / public domain, U.S. Government work)
    url: https://github.com/fedspendingtransparency/usaspending-api/blob/master/LICENSE.md
servers:
- url: https://api.usaspending.gov/api/v2
  description: Production (no authentication required)
tags:
- name: Recipient
  description: Recipient (awardee) profile and search data.
paths:
  /recipient/:
    post:
      operationId: listRecipients
      tags:
      - Recipient
      summary: List / search recipients
      description: Returns a paged list of recipients, their level, UEI (and deprecated DUNS), and award amount. Supports keyword search on name, UEI, or DUNS.
      requestBody:
        required: false
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/RecipientListRequest'
            example:
              order: desc
              sort: amount
              page: 1
              limit: 50
              award_type: all
      responses:
        '200':
          description: Paged recipient listing.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RecipientListResponse'
components:
  schemas:
    RecipientListResponse:
      type: object
      properties:
        page_metadata:
          $ref: '#/components/schemas/PageMetadata'
        results:
          type: array
          items:
            $ref: '#/components/schemas/RecipientListing'
    RecipientListing:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
        duns:
          type: string
          nullable: true
        uei:
          type: string
          nullable: true
        recipient_level:
          type: string
        amount:
          type: number
    RecipientListRequest:
      type: object
      properties:
        order:
          type: string
          enum:
          - asc
          - desc
          default: desc
        sort:
          type: string
          enum:
          - name
          - duns
          - amount
          default: amount
        limit:
          type: integer
          default: 50
          maximum: 1000
        page:
          type: integer
          default: 1
        keyword:
          type: string
          description: Searches on name, UEI, or DUNS.
        award_type:
          type: string
          enum:
          - all
          - contracts
          - grants
          - loans
          - direct_payments
          - other_financial_assistance
          default: all
    PageMetadata:
      type: object
      properties:
        page:
          type: integer
        next:
          type: integer
          nullable: true
        previous:
          type: integer
          nullable: true
        hasNext:
          type: boolean
        hasPrevious:
          type: boolean
        total:
          type: integer