SAM.gov Scraper: Contract Opportunities & Contacts $2/1K avatar

SAM.gov Scraper: Contract Opportunities & Contacts $2/1K

Pricing

from $1.20 / 1,000 opportunities

Go to Apify Store
SAM.gov Scraper: Contract Opportunities & Contacts $2/1K

SAM.gov Scraper: Contract Opportunities & Contacts $2/1K

SAM.gov scraper for federal contract opportunities & RFPs with contact emails. Filter NAICS, set-aside, agency. New-bid alerts. No login. $2 per 1,000.

Pricing

from $1.20 / 1,000 opportunities

Rating

0.0

(0)

Developer

Haniel Azevedo

Haniel Azevedo

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

10 days ago

Last modified

Features

Limited permissions

Share

SAM.gov scraper for US federal contract opportunities and RFPs: every new notice, filtered your way and delivered as clean JSON with contracting officer contacts (name, email, phone). No login or API key, and in monitor mode only the notices you haven't seen yet.

Solicitations, combined synopses, sources sought, presolicitations, special notices, justifications and award notices come from SAM.gov's official public daily extract (not by scraping the website). Filter by keywords, NAICS, PSC, set-aside, agency, state and dates, or turn on monitor mode to get only new or changed notices each run. Resumable downloads, retries and clear error codes keep scheduled runs reliable.

Who it's for

  • Small businesses and government contractors who want a daily list of bids in their NAICS codes, set-asides and states without checking SAM.gov by hand.
  • Capture managers, BD teams and proposal writers who track agencies, sources sought and RFPs and need to hear about new opportunities early.
  • GovCon consultants and bid-matching tools building alerts, CRMs or newsletters on top of federal contract data.
  • Developers and analysts who want typed JSON instead of the 220 MB CSV extract or the rate-limited keyed API.

Try it

Click Start without changing anything. The prefilled input returns the 50 newest open opportunities posted or updated in the last 3 days, across all agencies:

{
"postedWithinDays": 3,
"openOnly": true,
"maxResults": 50
}

It finishes in a few seconds because the Actor stops reading the file once it has enough recent notices. In our test run (31 Oct 2026) it returned 50 notices (22 combined synopses/solicitations, 16 solicitations, 5 special notices, 3 presolicitations, 3 sources sought, 1 justification) for $0.10. An empty input {} uses the same 3-day window and 50-notice limit, but also includes award notices and notices past their deadline. Then add your keywords, naicsCodes, setAsides or states.

How to use it

Search (default): returns every matching notice posted or amended in the date window.

{
"keywords": ["cybersecurity", "zero trust"],
"naicsCodes": ["5415"],
"setAsides": ["ANY"],
"noticeTypes": ["Solicitation", "Combined Synopsis/Solicitation", "Sources Sought"],
"states": ["VA", "MD", "DC"],
"postedWithinDays": 7,
"openOnly": true,
"maxResults": 200
}

Monitor: schedule it daily (Console > Schedules). Each run delivers only notices that are new, or updated (amended, new deadline, award) since the last run, so you pay for each notice once. The memory is kept in the named key-value store samgov-opportunities-state, one entry per saved search (derived from your filters, or set stateKey). With firstRun: "baseline" the first run records what already exists without delivering or charging it.

{ "mode": "monitor", "naicsCodes": ["236220"], "states": ["TX"], "postedWithinDays": 3, "firstRun": "baseline" }

Filters: keywords (word-prefix, case and accent-insensitive, searched in title, solicitation number and description), excludeKeywords, naicsCodes (2-6 digit prefixes), pscCodes (1-4 character prefixes), setAsides (codes plus ANY / NONE), noticeTypes, agencies (name words or CGAC/FPDS/AAC codes), states (place of performance, office, or either), postedFrom / postedTo / postedWithinDays (default 3 days), responseDeadlineFrom / responseDeadlineTo, openOnly. maxResults defaults to 50.

Schedule daily SAM.gov bid alerts (step by step)

  1. In Input, set your filters: NAICS codes, Set-asides, States, Keywords or Agencies.
  2. Set Mode to monitor and Monitor: first run to baseline, so the first run only records what is already open and charges nothing for it.
  3. Click Save as a new task, give it a name, and run it once to create the baseline.
  4. Open Schedules, create a schedule (for example every day at 12:00 UTC, after SAM.gov regenerates its extract around 03:30 UTC) and add the task.
  5. On the task's Integrations tab, add Slack, Gmail, Zapier, Make or a webhook, triggered when a run succeeds.
  6. Each day you get only the notices that are new or changed since the last run, and you pay $0.002 for each one.

Use with AI agents (MCP) and Python

MCP: add this Actor as a tool in Claude Desktop, Cursor, VS Code or any MCP client through the Apify MCP server: https://mcp.apify.com?tools=hanielazevedo/samgov-contract-opportunities (sign in with your Apify account or pass your API token). The agent sees the input schema and can run the Actor and read the dataset itself.

Python (pip install apify-client):

from apify_client import ApifyClient
client = ApifyClient("<YOUR_APIFY_TOKEN>")
run = client.actor("hanielazevedo/samgov-contract-opportunities").call(run_input={
"mode": "search",
"naicsCodes": [
"541512"
],
"setAsides": [
"ANY"
],
"postedWithinDays": 7,
"openOnly": True,
"maxResults": 100
})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
print(item)

Sample output

One record per notice. This item comes from the test run above (description shortened, secondaryContact removed):

{
"noticeId": "ff9c886ead754999bbe7add4b0ad67e1",
"solicitationNumber": "041115-27-0002",
"title": "Pressure Seal V-Fold Mailer",
"noticeType": "Solicitation",
"baseNoticeType": "Solicitation",
"active": true,
"postedDate": "2026-10-30",
"postedAt": "2026-10-30T14:05:49",
"responseDeadline": "2026-11-04T14:00:00-05:00",
"responseDeadlineDate": "2026-11-04",
"responseDeadlineUtc": "2026-11-04T19:00:00.000Z",
"archiveDate": "2026-11-19",
"archiveType": "auto15",
"department": "COMMERCE, DEPARTMENT OF",
"subTier": "US CENSUS BUREAU",
"office": "DEPT OF COMMERCE CENSUS",
"cgacCode": "013",
"fpdsCode": "1323",
"aacCode": "1333LB",
"setAsideCode": "SBA",
"setAside": "Small Business Set Aside - Total",
"naicsCode": "322220",
"pscCode": "7530",
"placeOfPerformance": {
"streetAddress": null,
"city": "Charlestown",
"state": "IN",
"zip": "47111",
"country": "USA"
},
"officeAddress": {
"organizationType": "OFFICE",
"city": "SUITLAND",
"state": "MD",
"zip": "20746",
"countryCode": "USA"
},
"award": null,
"primaryContact": {
"title": null,
"fullName": "Andrea Begens",
"email": "andrea.f.begens@census.gov",
"phone": null,
"fax": null
},
"additionalInfoLink": null,
"samUrl": "https://sam.gov/opp/ff9c886ead754999bbe7add4b0ad67e1/view",
"description": "The Government is currently reviewing vendor questions and coordinating responses with the requiring activity. Responses to submitted questions, along with any applicable amendment(s) to the solicitation, are anticipated to be posted next w…",
"descriptionLength": 1428,
"changeType": null,
"fingerprint": "09c721882440",
"sourceFileLastModified": "2026-10-31T03:30:30.000Z",
"retrievedAt": "2026-10-31T21:10:13.617Z"
}

What you get (fields)

One record per notice (about 70,000 active notices in the extract at any time):

FieldExample
noticeId, solicitationNumber, titleb5b75f61..., 36C78627Q0031, S208--Request for Information...
noticeType, baseNoticeTypeSources Sought
postedDate, postedAt2026-10-30, 2026-10-30T12:40:50 (US Eastern, as published)
responseDeadline, responseDeadlineDate, responseDeadlineUtcraw value, 2026-11-13, 2026-11-13T21:30:00.000Z
department, subTier, office, cgacCode, fpdsCode, aacCodeVETERANS AFFAIRS, DEPARTMENT OF, 036, 3600, 36C786
setAsideCode, setAsideSDVOSBC, Service-Disabled Veteran-Owned Small Business (SDVOSB) Set-Aside (FAR 19.14)
naicsCode, pscCode561730, S208
placeOfPerformance{ streetAddress, city, state, zip, country }
officeAddress{ organizationType, city, state, zip, countryCode }
award{ number, date, amount, awardee, awardeeWithheld } or null
primaryContact, secondaryContact{ title, fullName, email, phone, fax } or null
description, descriptionLengthfull plain-text description (optional, can be truncated)
samUrl, additionalInfoLinkhttps://sam.gov/opp/<noticeId>/view
changeTypemonitor mode: new or updated
fingerprint, sourceFileLastModified, retrievedAtprovenance

Values are cleaned: dates are ISO, deadlines with a time zone are converted to UTC, set-aside codes are unwrapped (["SBA"] becomes SBA), emails are lowercased, PSC codes are uppercased, and text typed into phone/fax fields that is not a phone number is dropped.

How much does it cost to scrape SAM.gov?

Pay per event:

EventPriceWhen
apify-actor-start$0.00005Once per run (default 256 MB memory)
opportunity$0.002Each notice delivered to the dataset

Runs that deliver nothing (no matches, monitor runs with nothing new, baselines, or a failed download) cost only the start fee. maxResults and the run's maximum charge both cap what you pay, and the Actor stops reading as soon as either is reached.

JobCalculationCost
The prefilled input (50 notices)50 × $0.002$0.10
1,000 notices1,000 × $0.002$2.00
10,000 notices10,000 × $0.002$20.00
Daily monitor, about 20 new matching notices a day, for 30 days600 × $0.002 + 30 × $0.00005$1.20
Monitor baseline on the first run (firstRun: "baseline")start fee only$0.00005

Reliability and error codes

  • The extract (about 220 MB) is streamed and parsed on the fly. Because it is sorted newest first, the Actor stops reading once rows fall out of your date window: a 3-day search reads only the top of the file.
  • Dropped connections and stalls are resumed from the last byte (HTTP Range + If-Match), alternating between the SAM.gov endpoint and its public S3 mirror, with exponential backoff.
  • If SAM.gov regenerates the file mid-download, the run restarts once on the new file without duplicating output.
  • Columns are mapped by name, so a reordered or extended extract keeps working. A missing required column fails clearly.
  • An empty extract (0 bytes, or a header row with no notices) fails with SOURCE_EMPTY instead of "succeeding" with 0 items.
  • Every run writes a SUMMARY record (key-value store) with counts, bytes read, the source file timestamp and an error code.
CodeMeaning
INVALID_INPUTAn input value is invalid (the message says which). Run fails, nothing charged beyond the start.
SOURCE_TIMEOUT, SOURCE_UNAVAILABLE, SOURCE_HTTP_ERROR, SOURCE_TRUNCATEDSAM.gov could not be read after retries. Run fails.
SOURCE_EMPTYSAM.gov published an empty extract (no rows, or headers only). Run fails, nothing charged; retry in a few hours. Monitor state is left unchanged.
SOURCE_SCHEMA_CHANGEDSAM.gov changed the extract format (an HTML error page, or required columns missing). Run fails.
SOURCE_STALEWarning: the extract has not been regenerated for more than 48 hours.
MAX_RESULTS_REACHED, CHARGE_LIMIT_REACHEDStopped at your limit. In monitor mode the rest is delivered next run.
NO_RESULTSNothing matched (or nothing new).
BASELINE_CREATEDMonitor baseline saved; nothing delivered.
STATE_ERRORMonitor state could not be read or saved.

Data source, freshness and terms

  • Source: the Contract Opportunities full CSV extract published by GSA on SAM.gov Data Services (public, no login, privacy=Public). It is regenerated once a day (about 03:30 UTC), so notices posted after the last regeneration appear the next day. It contains active notices only. For real-time needs use the official SAM.gov Opportunities API.
  • Terms: the SAM.gov Terms of Use state that SAM.gov data is available "via APIs and extracts" and that "if you want to share data publicly, only share data from public versions of APIs"; this Actor uses only the public extract and does not scrape the website. They also state: "Most material on our site is free of copyright and may be copied and distributed without permission... Citation of the GSA site and a link back is much appreciated." Source: GSA, SAM.gov (https://sam.gov). Every record links back to its SAM.gov page.
  • D&B data: the terms note that base award notices with an award date before 4 April 2022 may contain Dun & Bradstreet data that must not be redistributed in bulk. For those notices the Actor withholds the awardee name (award.awardee: null, award.awardeeWithheld: true); amounts, dates and award numbers are kept.
  • This is an independent tool, not an official GSA or SAM.gov product. Notice content is written by contracting offices; always confirm details on SAM.gov before bidding.

FAQ

What happens if SAM.gov is down or publishes an empty file? Downloads are retried and resumed. If SAM.gov still can't be read, the run fails with SOURCE_TIMEOUT, SOURCE_UNAVAILABLE or SOURCE_HTTP_ERROR. GovCon users have reported that the public CSV extract sometimes ships with headers only. The Actor detects that (and 0-byte files) and fails with SOURCE_EMPTY rather than returning 0 items as if nothing matched. Nothing is charged, monitor state is not touched, and the next scheduled run picks up where you left off.

What are the limits? maxResults (default 50, up to 1,000,000) and your Maximum cost per run cap each run. The extract holds about 70,000 active notices. It is regenerated once a day, so it is not real-time. Archived notices older than the extract are not included.

How does monitor mode work? With mode: "monitor" on a daily schedule, each run delivers only notices that are new or changed since the previous run, and you pay for each once. If a run hits maxResults, the rest arrives in the next run. Use firstRun: "baseline" to skip what already exists, and stateKey to name a saved search.

Where does the data come from? Is this legal? From the official public Contract Opportunities extract on SAM.gov Data Services, which GSA publishes for reuse. No login, no API key and no website scraping. See Data source, freshness and terms for the terms quotes and how Dun & Bradstreet data is withheld.

Which output formats can I export? The dataset exports to JSON, CSV, Excel, XML, RSS or HTML, and you can fetch it through the API. Nested fields (placeOfPerformance, award, contacts) are flattened in CSV/Excel.

What can I connect it to? Apify Schedules and webhooks, Zapier, Make, n8n, Google Sheets, Slack or email alerts (through those tools), the Apify API and SDKs, and the Apify MCP server for AI agents. A common setup is a daily monitor run that posts new notices to Slack or a spreadsheet.

Why "scraper" if it reads an extract? "SAM.gov scraper" is what people search for. This Actor gives the same result more reliably by reading the official public extract instead of the website.

Other Actors by Haniel