{
  "openapi": "3.0.1",
  "info": {
    "title": "TED, SAM.gov & Grants Bid Alerts Scraper",
    "description": "Start with a TED-only quickstart, then scrape TED tenders, SAM.gov opportunities, and grants notices into one public-sector bid-alert dataset with deadlines, buyers, values, award watch, rebid watch signals, and webhook-ready summaries.",
    "version": "0.1",
    "x-build-id": "gtlp6z8KGUh2uleOI"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/taroyamada~procurement-intel-actor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-taroyamada-procurement-intel-actor",
        "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/taroyamada~procurement-intel-actor/runs": {
      "post": {
        "operationId": "runs-sync-taroyamada-procurement-intel-actor",
        "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/taroyamada~procurement-intel-actor/run-sync": {
      "post": {
        "operationId": "run-sync-taroyamada-procurement-intel-actor",
        "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": {
          "jurisdictions": {
            "title": "Sources to search (comma-separated)",
            "type": "string",
            "description": "Use eu for TED tenders, grants for Grants.gov notices, and us for SAM.gov opportunities. If us is present without a SAM.gov key, the actor warns and skips that source instead of failing the whole run.",
            "default": "eu"
          },
          "keywords": {
            "title": "Search terms (comma-separated)",
            "type": "string",
            "description": "Themes sent to TED notice titles, SAM.gov opportunity titles, and Grants.gov queries. Keep terms narrow enough to return a reviewable bid-alert queue.",
            "default": "cloud,cybersecurity,IT services"
          },
          "watchTerms": {
            "title": "Watch terms (comma-separated)",
            "type": "string",
            "description": "Highlights buyers, incumbents, frameworks, or competitor terms in summaries and notice signals without changing upstream source queries."
          },
          "cpvCodes": {
            "title": "TED CPV codes (comma-separated)",
            "type": "string",
            "description": "Optional TED filters for public-sector tender categories.",
            "default": "72000000,72220000"
          },
          "naicsCodes": {
            "title": "SAM.gov NAICS codes (comma-separated)",
            "type": "string",
            "description": "Optional SAM.gov NAICS filters for the US federal opportunity lane.",
            "default": "541512,541519"
          },
          "tedFields": {
            "title": "TED fields (comma-separated)",
            "type": "string",
            "description": "Requested TED API fields used to explain buyer, deadline, value, and notice type.",
            "default": "notice-identifier,notice-title,publication-date,deadline,buyer-name,buyer-country,estimated-value-proc,classification-cpv,notice-type"
          },
          "minValue": {
            "title": "Minimum estimated value",
            "minimum": 0,
            "type": "number",
            "description": "Hide smaller notices when an estimated value is present.",
            "default": 100000
          },
          "daysAhead": {
            "title": "Deadline window (days)",
            "minimum": 1,
            "maximum": 365,
            "type": "integer",
            "description": "Keep notices closing within this window so the dataset reads like a current bid-alert queue.",
            "default": 21
          },
          "maxItemsPerSource": {
            "title": "Max items per source",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Upper bound fetched per source request.",
            "default": 40
          },
          "delivery": {
            "title": "Delivery mode",
            "enum": [
              "dataset",
              "webhook"
            ],
            "type": "string",
            "description": "Use dataset for review runs or webhook for downstream routing.",
            "default": "dataset"
          },
          "webhookUrl": {
            "title": "Webhook URL",
            "type": "string",
            "description": "Required only when delivery is webhook."
          },
          "includeAwarded": {
            "title": "Include awarded / closed notices",
            "type": "boolean",
            "description": "Turn this on for award watch, incumbent movement, or rebid monitoring.",
            "default": false
          },
          "samApiKey": {
            "title": "SAM.gov API key",
            "type": "string",
            "description": "SAM.gov API key from Account Details. If missing, the actor warns and skips the US lane instead of failing the whole run."
          },
          "samApiUrl": {
            "title": "SAM.gov API URL",
            "type": "string",
            "description": "SAM opportunities endpoint used for the US federal lane.",
            "default": "https://api.sam.gov/opportunities/v2/search"
          },
          "tedApiUrl": {
            "title": "TED API URL",
            "type": "string",
            "description": "TED notices search endpoint.",
            "default": "https://api.ted.europa.eu/v3/notices/search"
          },
          "grantsApiKey": {
            "title": "Grants.gov API key",
            "type": "string",
            "description": "Optional X-API-Key header for Simpler.Grants.gov requests."
          },
          "grantsApiUrl": {
            "title": "Grants.gov API URL",
            "type": "string",
            "description": "Simpler.Grants.gov opportunities search endpoint.",
            "default": "https://api.simpler.grants.gov/v1/opportunities/search"
          },
          "grantsApplicantTypes": {
            "title": "Grants applicant types (comma-separated)",
            "type": "string",
            "description": "Optional Simpler.Grants.gov applicant_type filters for the grants lane."
          },
          "grantsFundingInstruments": {
            "title": "Grants funding instruments (comma-separated)",
            "type": "string",
            "description": "Optional Simpler.Grants.gov funding_instrument filters for the grants expansion path."
          },
          "grantsOpportunityStatuses": {
            "title": "Grants statuses (comma-separated)",
            "type": "string",
            "description": "Optional Simpler.Grants.gov opportunity_status filters such as posted or forecasted.",
            "default": "posted,forecasted"
          },
          "grantsAlertClosingSoonDays": {
            "title": "Grants closing-soon threshold (days)",
            "minimum": 1,
            "maximum": 90,
            "type": "integer",
            "description": "For recurring grants runs, emit a closing_soon alert when a tracked grant crosses inside this deadline window.",
            "default": 7
          },
          "grantsAlertStateStoreName": {
            "title": "Grants alert state store name",
            "type": "string",
            "description": "Named Apify key-value store used to persist grants snapshots across recurring runs so deadline and status alerts stay comparable.",
            "default": "procurement-intel-grants-state"
          },
          "grantsAlertStateKey": {
            "title": "Grants alert state key",
            "type": "string",
            "description": "Optional override for the grants snapshot key. Leave blank to auto-derive a stable key from grants filters and keywords."
          },
          "samFixturePath": {
            "title": "Testing: SAM fixture path",
            "type": "string",
            "description": "Local JSON fixture path for offline SAM verification."
          },
          "tedFixturePath": {
            "title": "Testing: TED fixture path",
            "type": "string",
            "description": "Local JSON fixture path for offline TED verification."
          },
          "grantsFixturePath": {
            "title": "Testing: Grants fixture path",
            "type": "string",
            "description": "Local JSON fixture path for offline Simpler.Grants.gov verification."
          },
          "nowIso": {
            "title": "Testing: Override current time (ISO)",
            "type": "string",
            "description": "Optional deterministic run time override for fixtures and repeatable validation."
          },
          "dryRun": {
            "title": "Testing: Dry run",
            "type": "boolean",
            "description": "Skip dataset writes and webhook delivery side effects while validating inputs.",
            "default": false
          }
        }
      },
      "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}