{
  "openapi": "3.0.1",
  "info": {
    "title": "Government Tenders Scraper: SAM.gov, TED & UK Contracts",
    "description": "Government tenders and contract opportunities from SAM.gov (US federal), TED (EU) and the UK's Find a Tender and Contracts Finder in one search: buyer, deadline, value, CPV and NAICS codes, set-aside, contact email and phone. Public procurement data. Export to JSON, CSV or Excel, or via API.",
    "version": "1.0",
    "x-build-id": "pIAqRQ6U1pvRk8hMb"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/steadyscrape~government-tenders-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-steadyscrape-government-tenders-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/steadyscrape~government-tenders-scraper/runs": {
      "post": {
        "operationId": "runs-sync-steadyscrape-government-tenders-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/steadyscrape~government-tenders-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-steadyscrape-government-tenders-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",
        "required": [
          "sources"
        ],
        "properties": {
          "sources": {
            "title": "Sources",
            "type": "array",
            "description": "The official sources to search, all at once, each one's newest notices first. Every row names its source and licence. <b>SAM.gov</b> is read from its public daily extract (all US federal contract opportunities), <b>TED</b> through its anonymous search API (EU and EEA public procurement), <b>Find a Tender</b> and <b>Contracts Finder</b> through their OCDS APIs (UK).",
            "items": {
              "type": "string",
              "enum": [
                "sam-gov",
                "ted",
                "find-a-tender",
                "contracts-finder"
              ],
              "enumTitles": [
                "US federal – SAM.gov",
                "EU – TED",
                "UK – Find a Tender",
                "UK – Contracts Finder"
              ]
            },
            "default": [
              "sam-gov",
              "ted",
              "find-a-tender",
              "contracts-finder"
            ]
          },
          "postedWithinDays": {
            "title": "Published in the last N days",
            "minimum": 1,
            "maximum": 365,
            "type": "integer",
            "description": "Notices published from this many days ago up to today. Ignored when the dates below are set.",
            "default": 7
          },
          "postedFrom": {
            "title": "Published from (optional)",
            "pattern": "^(\\d{4}-\\d{2}-\\d{2})?$",
            "type": "string",
            "description": "The first publication day, YYYY-MM-DD. Leave empty to count back from the last day."
          },
          "postedTo": {
            "title": "Published to (optional)",
            "pattern": "^(\\d{4}-\\d{2}-\\d{2})?$",
            "type": "string",
            "description": "The last publication day, YYYY-MM-DD. Leave empty for today."
          },
          "noticeKinds": {
            "title": "Kinds of notice",
            "type": "array",
            "description": "<b>Open opportunities</b> are calls to bid (solicitations, contract notices, UK tender notices). <b>Planned</b> are early notices (pre-solicitations, sources sought, prior information, pipeline and planned procurement). <b>Awards</b> name who won and for how much. <b>Other</b> are corrections, modifications, cancellations and justifications. Each row says its kind in <code>noticeKind</code> and the source's own type in <code>noticeType</code>.",
            "items": {
              "type": "string",
              "enum": [
                "opportunity",
                "planned",
                "award",
                "other"
              ],
              "enumTitles": [
                "Open opportunities",
                "Planned and early notices",
                "Awards",
                "Other notices"
              ]
            },
            "default": [
              "opportunity"
            ]
          },
          "keywords": {
            "title": "Keywords",
            "type": "array",
            "description": "Only notices whose title or description contains any of these words or phrases, from the start of a word, case and accents aside: <code>cybersecurity</code>, <code>road maintenance</code>, <code>cleaning</code>. TED matches them in its full text in every EU language, translations included. Leave empty for every notice.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "onlyOpen": {
            "title": "Only notices still open",
            "type": "boolean",
            "description": "Leave out opportunities and planned notices whose response deadline has passed. Notices without a deadline are kept.",
            "default": false
          },
          "countries": {
            "title": "Buyer countries",
            "type": "array",
            "description": "Only buyers in these countries, as ISO codes: <code>DE</code>, <code>FR</code>, <code>PL</code>, <code>US</code>, <code>GB</code>. A source that holds no buyer there is not read, and a free row says so (SAM.gov is US, Find a Tender and Contracts Finder are GB, TED covers the EU, the EEA and more). Leave empty for every country.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "cpvCodes": {
            "title": "CPV codes (EU and UK)",
            "type": "array",
            "description": "Only notices classified under these CPV codes or their sub-codes: <code>45000000</code> (construction work) also matches 45210000; <code>72</code> is all IT services. CPV is used by TED, Find a Tender and Contracts Finder; with CPV codes and no NAICS code, SAM.gov is not read.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "naicsCodes": {
            "title": "NAICS codes (US)",
            "type": "array",
            "description": "Only SAM.gov notices under these NAICS codes or their prefixes: <code>541512</code>, <code>2382</code>, <code>54</code>. With NAICS codes or set-asides and no CPV code, the EU and UK sources are not read.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "setAsides": {
            "title": "Set-asides (US)",
            "type": "array",
            "description": "Only SAM.gov notices with one of these set-asides (small business, 8(a), HUBZone, SDVOSB, WOSB…).",
            "items": {
              "type": "string",
              "enum": [
                "SBA",
                "SBP",
                "8A",
                "8AN",
                "HZC",
                "HZS",
                "SDVOSBC",
                "SDVOSBS",
                "WOSB",
                "WOSBSS",
                "EDWOSB",
                "EDWOSBSS",
                "VSA",
                "VSS",
                "LAS",
                "IEE",
                "ISBEE",
                "BICiv",
                "NONE"
              ],
              "enumTitles": [
                "Small Business Set Aside - Total",
                "Small Business Set Aside - Partial",
                "8(a) Set-Aside",
                "8(a) Sole Source",
                "HUBZone Set-Aside",
                "HUBZone Sole Source",
                "Service-Disabled Veteran-Owned Small Business (SDVOSB) Set-Aside",
                "SDVOSB Sole Source",
                "Women-Owned Small Business (WOSB) Set-Aside",
                "WOSB Sole Source",
                "Economically Disadvantaged WOSB (EDWOSB) Set-Aside",
                "EDWOSB Sole Source",
                "Veteran-Owned Small Business Set-Aside (VA)",
                "Veteran-Owned Small Business Sole Source (VA)",
                "Local Area Set-Aside",
                "Indian Economic Enterprise",
                "Indian Small Business Economic Enterprise",
                "Buy Indian Set-Aside (IHS)",
                "No set-aside used"
              ]
            },
            "default": []
          },
          "maxResultsPerSource": {
            "title": "Max notices per source",
            "minimum": 0,
            "type": "integer",
            "description": "Stop reading a source after this many notices. 0 for no limit.",
            "default": 50
          },
          "maxResults": {
            "title": "Max notices in total",
            "minimum": 0,
            "type": "integer",
            "description": "Stop the run after this many notices across every source. 0 for no limit.",
            "default": 500
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}