{
  "openapi": "3.0.1",
  "info": {
    "title": "US Federal Awards Search — Contracts & Grants Winners",
    "description": "Find who wins US federal contracts, grants and loans, from the open USAspending.gov API. Filter by keyword, agency, dates, amount, state, NAICS and recipient. One flat row per award with recipient address, amounts and links.",
    "version": "0.1",
    "x-build-id": "QM4Uj2ykF7Gqd8zAN"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/openregistry~us-federal-awards-search/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-openregistry-us-federal-awards-search",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/openregistry~us-federal-awards-search/runs": {
      "post": {
        "operationId": "runs-sync-openregistry-us-federal-awards-search",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/openregistry~us-federal-awards-search/run-sync": {
      "post": {
        "operationId": "run-sync-openregistry-us-federal-awards-search",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "keywords": {
            "title": "Keywords",
            "type": "array",
            "description": "Words or phrases searched in the award description, recipient and codes, e.g. cybersecurity, solar, broadband. At least 3 characters each. An award matches if it contains any of them.",
            "items": {
              "type": "string"
            }
          },
          "awardTypes": {
            "title": "Award types",
            "type": "array",
            "description": "Each type is searched separately and the results are interleaved, so every type you pick is represented.",
            "items": {
              "type": "string",
              "enum": [
                "contracts",
                "idvs",
                "grants",
                "direct_payments",
                "loans",
                "other"
              ],
              "enumTitles": [
                "Contracts",
                "Indefinite delivery vehicles (IDV)",
                "Grants",
                "Direct payments",
                "Loans",
                "Other financial assistance"
              ]
            },
            "default": [
              "contracts",
              "grants"
            ]
          },
          "awardingAgencies": {
            "title": "Awarding agencies",
            "type": "array",
            "description": "Full name or abbreviation of top-tier agencies, e.g. Department of Defense, DOD, NASA, HHS. Unknown names stop the run with suggestions.",
            "items": {
              "type": "string"
            }
          },
          "fundingAgencies": {
            "title": "Funding agencies",
            "type": "array",
            "description": "Same format as awarding agencies, for the agency that pays.",
            "items": {
              "type": "string"
            }
          },
          "dateFrom": {
            "title": "From date",
            "type": "string",
            "description": "Start of the period (YYYY-MM-DD). The search covers awards from 2007-10-01 onward."
          },
          "dateTo": {
            "title": "To date",
            "type": "string",
            "description": "End of the period (YYYY-MM-DD)."
          },
          "dateType": {
            "title": "What the dates apply to",
            "enum": [
              "action",
              "newAwards",
              "lastModified",
              "signed"
            ],
            "type": "string",
            "description": "Pick New awards only to list fresh winners, e.g. for a weekly watch.",
            "default": "action"
          },
          "minAmount": {
            "title": "Minimum amount (USD)",
            "type": "integer",
            "description": "Keep awards of at least this amount."
          },
          "maxAmount": {
            "title": "Maximum amount (USD)",
            "type": "integer",
            "description": "Keep awards of at most this amount."
          },
          "recipientStates": {
            "title": "Recipient states",
            "type": "array",
            "description": "Two-letter codes of the states where recipients are located, e.g. TX, VA.",
            "items": {
              "type": "string"
            }
          },
          "performanceStates": {
            "title": "Place of performance states",
            "type": "array",
            "description": "Two-letter codes of the states where the work is performed.",
            "items": {
              "type": "string"
            }
          },
          "recipientNames": {
            "title": "Recipient names or UEI",
            "type": "array",
            "description": "Recipient name fragments or UEI numbers, e.g. Leidos, to follow specific companies or competitors.",
            "items": {
              "type": "string"
            }
          },
          "naicsCodes": {
            "title": "NAICS codes",
            "type": "array",
            "description": "Industry codes for contracts, e.g. 541512 (computer systems design). A shorter prefix such as 5415 covers the whole group.",
            "items": {
              "type": "string"
            }
          },
          "pscCodes": {
            "title": "Product or Service Codes (PSC)",
            "type": "array",
            "description": "Contract PSC codes, e.g. D302, R425.",
            "items": {
              "type": "string"
            }
          },
          "assistanceListings": {
            "title": "Assistance listing numbers (CFDA)",
            "type": "array",
            "description": "Program numbers for grants, loans and payments, e.g. 10.855.",
            "items": {
              "type": "string"
            }
          },
          "sortBy": {
            "title": "Sort by",
            "enum": [
              "amount",
              "startDate",
              "endDate",
              "lastModified",
              "recipient"
            ],
            "type": "string",
            "description": "With a maximum number of results, the sort decides which awards you get first.",
            "default": "amount"
          },
          "sortOrder": {
            "title": "Sort order",
            "enum": [
              "desc",
              "asc"
            ],
            "type": "string",
            "description": "Direction of the sort.",
            "default": "desc"
          },
          "maxResults": {
            "title": "Maximum awards",
            "minimum": 1,
            "maximum": 1000000,
            "type": "integer",
            "description": "The run stops once this many awards are delivered, so you control the cost.",
            "default": 100
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}