{
  "openapi": "3.0.1",
  "info": {
    "title": "SAM.gov Opportunities & USAspending Awards Scraper",
    "description": "Find federal contract opportunities from SAM.gov (solicitations, RFIs, set-asides, deadlines, contracting officer contacts) and contract awards from USAspending.gov (winners, amounts, competition). Filter by keyword, NAICS, PSC, agency, set-aside and state. No API key.",
    "version": "0.1",
    "x-build-id": "Od26uSSt5x4y2or9R"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/thisisb3~sam-gov-contracts-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-thisisb3-sam-gov-contracts-scraper",
        "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/thisisb3~sam-gov-contracts-scraper/runs": {
      "post": {
        "operationId": "runs-sync-thisisb3-sam-gov-contracts-scraper",
        "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/thisisb3~sam-gov-contracts-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-thisisb3-sam-gov-contracts-scraper",
        "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": {
          "sources": {
            "title": "Sources",
            "type": "array",
            "description": "What to get. Opportunities are open and recent notices from SAM.gov (solicitations, RFIs, presolicitations, award notices). Awards are signed contracts from USAspending.gov (who won, how much, from which agency). Each row has a `type` field: `opportunity` or `award`.",
            "items": {
              "type": "string",
              "enum": [
                "opportunities",
                "awards"
              ],
              "enumTitles": [
                "Contract opportunities (SAM.gov)",
                "Contract awards (USAspending.gov)"
              ]
            },
            "default": [
              "opportunities",
              "awards"
            ]
          },
          "keywords": {
            "title": "Keywords",
            "type": "array",
            "description": "Words or phrases, e.g. `cybersecurity`, `janitorial services`, `cloud migration`. Opportunities match when a keyword appears as a whole word (plurals included) in the title, description or solicitation number. Awards use USAspending's keyword search, which needs at least 3 characters per keyword.",
            "items": {
              "type": "string"
            }
          },
          "naicsCodes": {
            "title": "NAICS codes",
            "type": "array",
            "description": "Industry codes, 2 to 6 digits, e.g. `541512` (Computer Systems Design Services). A shorter code matches every code that starts with it: `5415` covers 541511 to 541519.",
            "items": {
              "type": "string"
            }
          },
          "pscCodes": {
            "title": "Product or service codes (PSC)",
            "type": "array",
            "description": "Exact 4-character product or service codes, e.g. `D302` (IT systems development) or `R499` (other professional support).",
            "items": {
              "type": "string"
            }
          },
          "agencies": {
            "title": "Agencies",
            "type": "array",
            "description": "Federal departments and agencies. Opportunities match the posting department; awards match the awarding agency.",
            "items": {
              "type": "string",
              "enum": [
                "DOD",
                "GSA",
                "VA",
                "USDA",
                "DOI",
                "DHS",
                "DOJ",
                "DOS",
                "HHS",
                "DOT",
                "DOE",
                "NASA",
                "DOC",
                "EPA",
                "TREAS",
                "ED",
                "HUD",
                "DOL",
                "SSA",
                "USAID",
                "NSF",
                "NRC",
                "OPM",
                "SBA",
                "SEC",
                "FDIC",
                "FCC",
                "NARA",
                "EXIM",
                "USAGM",
                "ABMC",
                "CSOSA",
                "MCC",
                "USTDA",
                "DFC",
                "PBGC",
                "FEC",
                "EOP",
                "NTSB",
                "USITC",
                "ABILITYONE",
                "CFPB",
                "NLRB",
                "FMC",
                "CNCS",
                "PC"
              ],
              "enumTitles": [
                "DOD – Department of Defense",
                "GSA – General Services Administration",
                "VA – Department of Veterans Affairs",
                "USDA – Department of Agriculture",
                "DOI – Department of the Interior",
                "DHS – Department of Homeland Security",
                "DOJ – Department of Justice",
                "DOS – Department of State",
                "HHS – Department of Health and Human Services",
                "DOT – Department of Transportation",
                "DOE – Department of Energy",
                "NASA – National Aeronautics and Space Administration",
                "DOC – Department of Commerce",
                "EPA – Environmental Protection Agency",
                "TREAS – Department of the Treasury",
                "ED – Department of Education",
                "HUD – Department of Housing and Urban Development",
                "DOL – Department of Labor",
                "SSA – Social Security Administration",
                "USAID – Agency for International Development",
                "NSF – National Science Foundation",
                "NRC – Nuclear Regulatory Commission",
                "OPM – Office of Personnel Management",
                "SBA – Small Business Administration",
                "SEC – Securities and Exchange Commission",
                "FDIC – Federal Deposit Insurance Corporation",
                "FCC – Federal Communications Commission",
                "NARA – National Archives and Records Administration",
                "EXIM – Export-Import Bank of the United States",
                "USAGM – U.S. Agency for Global Media",
                "ABMC – American Battle Monuments Commission",
                "CSOSA – Court Services and Offender Supervision Agency",
                "MCC – Millennium Challenge Corporation",
                "USTDA – United States Trade and Development Agency",
                "DFC – U.S. International Development Finance Corporation",
                "PBGC – Pension Benefit Guaranty Corporation",
                "FEC – Federal Election Commission",
                "EOP – Executive Office of the President",
                "NTSB – National Transportation Safety Board",
                "USITC – International Trade Commission",
                "ABILITYONE – Committee for Purchase from People Who Are Blind or Severely Disabled",
                "CFPB – Consumer Financial Protection Bureau",
                "NLRB – National Labor Relations Board",
                "FMC – Federal Maritime Commission",
                "CNCS – Corporation for National and Community Service",
                "PC – Peace Corps"
              ]
            }
          },
          "setAsides": {
            "title": "Set-asides",
            "type": "array",
            "description": "Small business set-aside types, e.g. SDVOSB, 8(a), HUBZone or WOSB. For awards this is the set-aside recorded on the contract.",
            "items": {
              "type": "string",
              "enum": [
                "SBA",
                "SBP",
                "8A",
                "8AN",
                "HZC",
                "HZS",
                "SDVOSBC",
                "SDVOSBS",
                "WOSB",
                "WOSBSS",
                "EDWOSB",
                "EDWOSBSS",
                "VSA",
                "VSS",
                "ISBEE",
                "IEE",
                "BICiv",
                "LAS",
                "NONE"
              ],
              "enumTitles": [
                "SBA – Total Small Business Set-Aside (FAR 19.5)",
                "SBP – Partial Small Business Set-Aside (FAR 19.5)",
                "8A – 8(a) Set-Aside (FAR 19.8)",
                "8AN – 8(a) Sole Source (FAR 19.8)",
                "HZC – HUBZone Set-Aside (FAR 19.13)",
                "HZS – HUBZone Sole Source (FAR 19.13)",
                "SDVOSBC – Service-Disabled Veteran-Owned Small Business (SDVOSB) Set-Aside (FAR 19.14)",
                "SDVOSBS – SDVOSB Sole Source (FAR 19.14)",
                "WOSB – Women-Owned Small Business (WOSB) Program Set-Aside (FAR 19.15)",
                "WOSBSS – WOSB Program Sole Source (FAR 19.15)",
                "EDWOSB – Economically Disadvantaged WOSB (EDWOSB) Program Set-Aside (FAR 19.15)",
                "EDWOSBSS – EDWOSB Program Sole Source (FAR 19.15)",
                "VSA – Veteran-Owned Small Business Set-Aside (VA only)",
                "VSS – Veteran-Owned Small Business Sole Source (VA only)",
                "ISBEE – Indian Small Business Economic Enterprise (ISBEE) Set-Aside",
                "IEE – Indian Economic Enterprise (IEE) Set-Aside",
                "BICiv – Buy Indian Set-Aside (Indian Health Service)",
                "LAS – Local Area Set-Aside (FAR 26.2), opportunities only",
                "NONE – No set-aside used"
              ]
            }
          },
          "states": {
            "title": "Place of performance (states)",
            "type": "array",
            "description": "US states or territories where the work is done. Many SAM.gov notices leave the place of performance empty; they are left out when this filter is set.",
            "items": {
              "type": "string",
              "enum": [
                "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",
                "PR",
                "GU",
                "VI",
                "AS",
                "MP"
              ],
              "enumTitles": [
                "Alabama (AL)",
                "Alaska (AK)",
                "Arizona (AZ)",
                "Arkansas (AR)",
                "California (CA)",
                "Colorado (CO)",
                "Connecticut (CT)",
                "Delaware (DE)",
                "District of Columbia (DC)",
                "Florida (FL)",
                "Georgia (GA)",
                "Hawaii (HI)",
                "Idaho (ID)",
                "Illinois (IL)",
                "Indiana (IN)",
                "Iowa (IA)",
                "Kansas (KS)",
                "Kentucky (KY)",
                "Louisiana (LA)",
                "Maine (ME)",
                "Maryland (MD)",
                "Massachusetts (MA)",
                "Michigan (MI)",
                "Minnesota (MN)",
                "Mississippi (MS)",
                "Missouri (MO)",
                "Montana (MT)",
                "Nebraska (NE)",
                "Nevada (NV)",
                "New Hampshire (NH)",
                "New Jersey (NJ)",
                "New Mexico (NM)",
                "New York (NY)",
                "North Carolina (NC)",
                "North Dakota (ND)",
                "Ohio (OH)",
                "Oklahoma (OK)",
                "Oregon (OR)",
                "Pennsylvania (PA)",
                "Rhode Island (RI)",
                "South Carolina (SC)",
                "South Dakota (SD)",
                "Tennessee (TN)",
                "Texas (TX)",
                "Utah (UT)",
                "Vermont (VT)",
                "Virginia (VA)",
                "Washington (WA)",
                "West Virginia (WV)",
                "Wisconsin (WI)",
                "Wyoming (WY)",
                "Puerto Rico (PR)",
                "Guam (GU)",
                "U.S. Virgin Islands (VI)",
                "American Samoa (AS)",
                "Northern Mariana Islands (MP)"
              ]
            }
          },
          "noticeTypes": {
            "title": "Notice types",
            "type": "array",
            "description": "Only these kinds of notices. For bids you can respond to, pick Solicitation, Combined Synopsis/Solicitation, Presolicitation and Sources Sought. Empty = all types.",
            "items": {
              "type": "string",
              "enum": [
                "solicitation",
                "combined",
                "presolicitation",
                "sources-sought",
                "special-notice",
                "award",
                "justification",
                "intent-to-bundle",
                "sale-of-surplus",
                "modification"
              ],
              "enumTitles": [
                "Solicitation",
                "Combined Synopsis/Solicitation",
                "Presolicitation",
                "Sources Sought (RFI)",
                "Special Notice",
                "Award Notice",
                "Justification (J&A, sole source)",
                "Intent to Bundle Requirements",
                "Sale of Surplus Property",
                "Modification/Amendment/Cancel"
              ]
            }
          },
          "postedWithinDays": {
            "title": "Posted in the last (days)",
            "minimum": 0,
            "maximum": 10000,
            "type": "integer",
            "description": "Only notices posted in the last N days, newest first. Use 1 for a daily alert, 14 to 60 for a first look. 0 = every active notice (the whole file, slower).",
            "default": 14
          },
          "excludePastDeadlines": {
            "title": "Skip notices whose deadline has passed",
            "type": "boolean",
            "description": "Leaves out notices whose response deadline is already over. Notices without a deadline (e.g. award and special notices) are kept.",
            "default": true
          },
          "includeDescription": {
            "title": "Include the notice description",
            "type": "boolean",
            "description": "Adds the full notice text (up to about 32,000 characters, as SAM.gov publishes it). Turn off for smaller exports; keywords still search it.",
            "default": true
          },
          "maxOpportunities": {
            "title": "Max opportunities",
            "minimum": 0,
            "maximum": 1000000,
            "type": "integer",
            "description": "Stop after this many opportunity rows. 0 = no limit.",
            "default": 100
          },
          "awardsWithinDays": {
            "title": "Awards signed in the last (days)",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Award date window, counted back from today. Ignored when you set the dates below. USAspending shows Department of Defense awards about 90 days after signing.",
            "default": 365
          },
          "awardDateFrom": {
            "title": "Award date from",
            "type": "string",
            "description": "Start of the award date range (YYYY-MM-DD), e.g. 2024-10-01 for fiscal year 2025. Earliest: 2007-10-01."
          },
          "awardDateTo": {
            "title": "Award date to",
            "type": "string",
            "description": "End of the award date range (YYYY-MM-DD). Empty = today."
          },
          "awardDateType": {
            "title": "Which awards count as in the date range",
            "enum": [
              "new",
              "activity"
            ],
            "type": "string",
            "description": "New awards: contracts first signed in the range. Any activity: contracts with any transaction (modification, new money) in the range, which also catches older contracts that are still active.",
            "default": "new"
          },
          "minAwardAmount": {
            "title": "Minimum award amount (USD)",
            "minimum": 0,
            "type": "integer",
            "description": "Only awards with at least this much obligated."
          },
          "maxAwardAmount": {
            "title": "Maximum award amount (USD)",
            "minimum": 0,
            "type": "integer",
            "description": "Only awards with at most this much obligated."
          },
          "recipients": {
            "title": "Recipients (companies)",
            "type": "array",
            "description": "Company names or UEIs, e.g. `Booz Allen` or `NEKWPBM5VT33`, to research a competitor's or teaming partner's contracts.",
            "items": {
              "type": "string"
            }
          },
          "awardsSortBy": {
            "title": "Award order",
            "enum": [
              "newest",
              "largest"
            ],
            "type": "string",
            "description": "Newest first (by signing date) or largest first (by obligated amount).",
            "default": "newest"
          },
          "includeAwardDetails": {
            "title": "Include competition details",
            "type": "boolean",
            "description": "Adds number of offers received, extent competed, set-aside, contract pricing type, potential value with options, potential end date, parent contract (IDIQ/GWAC/schedule), contracting office and the recipient's parent company. One extra request per award; rows are billed as \"award with details\".",
            "default": false
          },
          "maxAwards": {
            "title": "Max awards",
            "minimum": 0,
            "maximum": 1000000,
            "type": "integer",
            "description": "Stop after this many award rows. 0 = no limit.",
            "default": 100
          },
          "maxItems": {
            "title": "Maximum results",
            "minimum": 0,
            "maximum": 1000000,
            "type": "integer",
            "description": "Stop after this many rows in total (opportunities plus awards). 0 = no limit. You are only charged for rows you receive.",
            "default": 1000
          },
          "maxConcurrency": {
            "title": "Max concurrency",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "Parallel requests to USAspending, also the most started per second. The default is deliberately polite, and the Actor slows down automatically if asked to.",
            "default": 3
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}