{
  "openapi": "3.0.1",
  "info": {
    "title": "SAM.gov Contract Opportunities Monitor - Notices for the US",
    "description": "Extract US federal contract opportunities from the SAM.gov opportunities API. Includes the notice id, title and posted date. Saved NAICS and title filters, including a baseline and a newly delivered notice. Results as JSON, CSV or Excel. Access through API or MCP.",
    "version": "0.2",
    "x-build-id": "WBYGTj80RNWSQ1hsK"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/mmdincer~sam-gov-opportunities-monitor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-mmdincer-sam-gov-opportunities-monitor",
        "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/mmdincer~sam-gov-opportunities-monitor/runs": {
      "post": {
        "operationId": "runs-sync-mmdincer-sam-gov-opportunities-monitor",
        "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/mmdincer~sam-gov-opportunities-monitor/run-sync": {
      "post": {
        "operationId": "run-sync-mmdincer-sam-gov-opportunities-monitor",
        "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",
        "required": [
          "apiKey"
        ],
        "properties": {
          "apiKey": {
            "title": "SAM.gov API key",
            "type": "string",
            "description": "Your own free public API key from SAM.gov Account Details. The Actor sends it only to <code>api.sam.gov</code> and does not write it to the dataset, the run summary or the log. Leave it empty and the run stops before any request. Create a key after signing in at <a href=\"https://sam.gov/\">sam.gov</a>."
          },
          "mode": {
            "title": "Mode",
            "enum": [
              "changes",
              "search"
            ],
            "type": "string",
            "description": "<b>Changes</b> compares notice IDs with the previous run of this watchlist. The first complete run saves a baseline and returns no opportunities. <b>Search</b> returns every match in the posted-date window and does not update the baseline.",
            "default": "changes"
          },
          "naicsCodes": {
            "title": "NAICS codes",
            "type": "array",
            "description": "Optional. 2 to 6 digit NAICS codes, one per line, for example <code>541512</code>. SAM.gov matches the code you send (usually the full 6-digit code). Several codes are combined with OR. Leave empty to skip this filter. Each code is a separate API call.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "keywords": {
            "title": "Title keywords",
            "type": "array",
            "description": "Optional. Words or phrases to send as the official <code>title</code> parameter. SAM.gov does not offer a separate full-text parameter, so this matches the notice title, not the description body. Several keywords are OR. Leave empty to skip this filter.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "setAsides": {
            "title": "Set-aside",
            "type": "array",
            "description": "Optional. Official set-aside codes. One code is sent per request; several codes are OR. Leave empty to include every set-aside, including notices with none.",
            "items": {
              "type": "string",
              "enum": [
                "SBA",
                "SBP",
                "8A",
                "8AN",
                "HZC",
                "HZS",
                "SDVOSBC",
                "SDVOSBS",
                "WOSB",
                "WOSBSS",
                "EDWOSB",
                "EDWOSBSS",
                "LAS",
                "IEE",
                "ISBEE",
                "BICiv",
                "VSA",
                "VSS"
              ],
              "enumTitles": [
                "Total Small Business (SBA)",
                "Partial Small Business (SBP)",
                "8(a) Set-Aside (8A)",
                "8(a) Sole Source (8AN)",
                "HUBZone Set-Aside (HZC)",
                "HUBZone Sole Source (HZS)",
                "SDVOSB Set-Aside (SDVOSBC)",
                "SDVOSB Sole Source (SDVOSBS)",
                "WOSB Set-Aside (WOSB)",
                "WOSB Sole Source (WOSBSS)",
                "EDWOSB Set-Aside (EDWOSB)",
                "EDWOSB Sole Source (EDWOSBSS)",
                "Local Area (LAS)",
                "Indian Economic Enterprise (IEE)",
                "Indian Small Business Economic Enterprise (ISBEE)",
                "Buy Indian (BICiv)",
                "Veteran-Owned Set-Aside (VSA)",
                "Veteran-Owned Sole Source (VSS)"
              ]
            },
            "default": []
          },
          "agency": {
            "title": "Agency",
            "type": "string",
            "description": "Optional. Department or sub-tier name, sent as the official <code>organizationName</code> parameter (a general search). Example: <code>Department of Veterans Affairs</code>. The deprecated department and sub-tier parameters are not used.",
            "default": ""
          },
          "noticeTypes": {
            "title": "Notice types",
            "type": "array",
            "description": "Optional. Procurement types. Several types are OR. Leave empty for every type. The product of NAICS codes, keywords, set-asides and notice types cannot exceed 20 API searches.",
            "items": {
              "type": "string",
              "enum": [
                "o",
                "p",
                "k",
                "r",
                "s",
                "a",
                "u",
                "g",
                "i"
              ],
              "enumTitles": [
                "Solicitation",
                "Presolicitation",
                "Combined Synopsis/Solicitation",
                "Sources Sought",
                "Special Notice",
                "Award Notice",
                "Justification (J&A)",
                "Sale of Surplus Property",
                "Intent to Bundle Requirements (DoD)"
              ]
            },
            "default": []
          },
          "activeOnly": {
            "title": "Active notices only",
            "type": "boolean",
            "description": "Keep only notices SAM.gov marks active. Off by default, so award notices and other rows the API still returns are not hidden.",
            "default": false
          },
          "lookbackDays": {
            "title": "Lookback days",
            "minimum": 1,
            "maximum": 1825,
            "type": "integer",
            "description": "How many Eastern-time days to read, including today, when Posted from and Posted to are empty. A daily schedule can keep this at 7. Ranges longer than one year are split into one-year requests.",
            "default": 7
          },
          "postedFrom": {
            "title": "Posted from",
            "type": "string",
            "description": "Optional start date, <code>MM/dd/yyyy</code>, on the America/New_York calendar. Set both dates, or leave both empty to use Lookback days.",
            "default": ""
          },
          "postedTo": {
            "title": "Posted to",
            "type": "string",
            "description": "Optional end date, <code>MM/dd/yyyy</code>. Must be on or after Posted from. The Actor splits anything longer than one year before calling SAM.gov.",
            "default": ""
          },
          "includeDescription": {
            "title": "Download descriptions",
            "type": "boolean",
            "description": "Also download each delivered notice's description from api.sam.gov. Off by default, because every description is another request against your daily quota. The description URL is always included.",
            "default": false
          },
          "maxOpportunities": {
            "title": "Max opportunities",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Most new rows to return in one Changes run, or most rows in one Search run. Further new notices stay unseen, so a later run can report them. The default covers a filtered week.",
            "default": 2000
          },
          "monitorName": {
            "title": "Watchlist name",
            "type": "string",
            "description": "Name of the saved baseline. Runs with the same name and the same filters share a baseline. Changing the filters starts a new baseline. Example: <code>va-it</code>.",
            "default": "default"
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}