{
  "openapi": "3.0.1",
  "info": {
    "title": "SAM.gov Federal Contract & Award Notice Scraper",
    "description": "Search US federal contract notices on SAM.gov by keyword, NAICS code, set-aside type and posting date, or fetch a specific notice by ID, covering solicitations, sources sought, awards and set-aside designations.",
    "version": "1.0",
    "x-build-id": "rrmdtbUsqvOpaJhvp"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/crawlyth-forge~sam-gov-federal-contract-and-award-notice-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-crawlyth-forge-sam-gov-federal-contract-and-award-notice-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/crawlyth-forge~sam-gov-federal-contract-and-award-notice-scraper/runs": {
      "post": {
        "operationId": "runs-sync-crawlyth-forge-sam-gov-federal-contract-and-award-notice-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/crawlyth-forge~sam-gov-federal-contract-and-award-notice-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-crawlyth-forge-sam-gov-federal-contract-and-award-notice-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": {
          "operation": {
            "title": "Operation",
            "enum": [
              "search",
              "getNoticeDetails"
            ],
            "type": "string",
            "description": "Search notices with filters, or fetch specific notices by ID or sam.gov URL.",
            "default": "search"
          },
          "mode": {
            "title": "Legacy mode",
            "type": "string",
            "description": "Legacy mode value accepted for backward compatibility. Use `operation` instead."
          },
          "searchQuery": {
            "title": "Search keywords",
            "type": "string",
            "description": "Words to match in notice titles and descriptions. Leave empty to browse by filters only."
          },
          "matchMode": {
            "title": "Keyword matching",
            "enum": [
              "ALL",
              "ANY",
              "EXACT"
            ],
            "type": "string",
            "description": "How multiple keywords must match. Best match sorting uses relevance when keywords are set.",
            "default": "ALL"
          },
          "noticeType": {
            "title": "Notice type",
            "enum": [
              "",
              "a",
              "k",
              "o",
              "p",
              "r",
              "s",
              "g",
              "i",
              "u"
            ],
            "type": "string",
            "description": "Restrict results to one notice type, such as solicitations or award notices.",
            "default": ""
          },
          "naicsCode": {
            "title": "NAICS code",
            "type": "string",
            "description": "One or more NAICS codes, comma-separated. Ranges are accepted, e.g. 541511,541512 or 561730-561740."
          },
          "pscCode": {
            "title": "Product Service Code (PSC)",
            "type": "string",
            "description": "One or more PSC codes, comma-separated, e.g. D302 or 7A21."
          },
          "setAside": {
            "title": "Set-aside",
            "enum": [
              "",
              "SBA",
              "SBP",
              "8A",
              "8AN",
              "HZC",
              "HZS",
              "SDVOSBC",
              "SDVOSBS",
              "WOSB",
              "WOSBSS",
              "EDWOSB",
              "EDWOSBSS",
              "IEE",
              "ISBEE",
              "LAS"
            ],
            "type": "string",
            "description": "Small-business and socioeconomic set-aside designation.",
            "default": ""
          },
          "organizationId": {
            "title": "Organization ID",
            "type": "string",
            "description": "Optional SAM.gov federal organization ID, or a comma-separated list, to restrict results to specific departments, agencies or offices."
          },
          "placeOfPerformanceState": {
            "title": "Place of performance state",
            "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",
              "AS",
              "GU",
              "MP",
              "PR",
              "VI"
            ],
            "type": "string",
            "description": "US state or territory where the work will be performed.",
            "default": ""
          },
          "placeOfPerformanceCountry": {
            "title": "Place of performance country",
            "type": "string",
            "description": "Three-letter country code, e.g. USA. Leave empty for all countries."
          },
          "postedFrom": {
            "title": "Posted from",
            "type": "string",
            "description": "Only notices published on or after this date (YYYY-MM-DD)."
          },
          "postedTo": {
            "title": "Posted to",
            "type": "string",
            "description": "Only notices published on or before this date (YYYY-MM-DD)."
          },
          "responseFrom": {
            "title": "Response deadline from",
            "type": "string",
            "description": "Only notices whose response deadline is on or after this date (YYYY-MM-DD)."
          },
          "responseTo": {
            "title": "Response deadline to",
            "type": "string",
            "description": "Only notices whose response deadline is on or before this date (YYYY-MM-DD)."
          },
          "activeOnly": {
            "title": "Active notices only",
            "type": "boolean",
            "description": "Keep only currently active notices. Turn off to include archived and inactive notices.",
            "default": true
          },
          "sort": {
            "title": "Sort results",
            "enum": [
              "-modifiedDate",
              "modifiedDate",
              "-relevance",
              "title",
              "-title"
            ],
            "type": "string",
            "description": "Order of returned notices. Best match needs search keywords.",
            "default": "-modifiedDate"
          },
          "awardNumber": {
            "title": "Award or delivery order number",
            "type": "string",
            "description": "Filter award notices by contract award number or task/delivery order number."
          },
          "awardeeState": {
            "title": "Awardee state",
            "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",
              "AS",
              "GU",
              "MP",
              "PR",
              "VI"
            ],
            "type": "string",
            "description": "US state or territory of the awardee. Applies to award notices.",
            "default": ""
          },
          "awardAmountFrom": {
            "title": "Award amount from",
            "type": "string",
            "description": "Minimum award amount in US dollars, e.g. 100000."
          },
          "awardAmountTo": {
            "title": "Award amount to",
            "type": "string",
            "description": "Maximum award amount in US dollars, e.g. 5000000."
          },
          "includeDetails": {
            "title": "Include full notice details",
            "type": "boolean",
            "description": "Fetch each notice's detail page for NAICS/PSC, set-aside, award amount, contacts and description. Adds one request per notice.",
            "default": true
          },
          "includeAttachments": {
            "title": "Include attachment list",
            "type": "boolean",
            "description": "List each notice's attachments with public download links. Adds one request per notice.",
            "default": true
          },
          "noticeIds": {
            "title": "Notice IDs or URLs",
            "type": "array",
            "description": "Used in fetch mode. Paste SAM.gov notice IDs, solicitation numbers, or sam.gov/opp/<id>/view URLs.",
            "items": {
              "type": "string"
            }
          },
          "maxItems": {
            "title": "Maximum notices",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Maximum number of notices to return (1-10,000). SAM.gov caps any single query at 10,000 records.",
            "default": 25
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}