{
  "openapi": "3.0.1",
  "info": {
    "title": "Government Tenders & Public Procurement API: SAM.gov, TED, UK",
    "description": "Government tenders, RFPs and contract awards in one feed: SAM.gov (US), TED tenders (EU), UK Find a Tender + Contracts Finder, CanadaBuys and World Bank. Filter by keyword, country, CPV/NAICS/UNSPSC, deadline, value. Daily alerts return only new notices. $2 per 1,000 notices.",
    "version": "1.0",
    "x-build-id": "nTx3Wx33eMZ4NLOZr"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/blueberry_rainstorm~public-tenders-feed/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-blueberry_rainstorm-public-tenders-feed",
        "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/blueberry_rainstorm~public-tenders-feed/runs": {
      "post": {
        "operationId": "runs-sync-blueberry_rainstorm-public-tenders-feed",
        "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/blueberry_rainstorm~public-tenders-feed/run-sync": {
      "post": {
        "operationId": "run-sync-blueberry_rainstorm-public-tenders-feed",
        "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": {
          "keywords": {
            "title": "Keywords",
            "type": "array",
            "description": "Return notices that mention ANY of these words or phrases (title, description or buyer). Leave empty for all notices. SAM.gov and TED search the full notice text on their side; TED matches all EU languages, so CPV codes are more precise there.",
            "items": {
              "type": "string"
            }
          },
          "excludeKeywords": {
            "title": "Exclude keywords",
            "type": "array",
            "description": "Drop notices whose title or description mentions any of these words (e.g. \"catering\", \"vehicle\").",
            "items": {
              "type": "string"
            }
          },
          "strictKeywordMatch": {
            "title": "Strict keyword match",
            "type": "boolean",
            "description": "SAM.gov's own search also matches attachments and standard contract clauses (e.g. every DoD notice mentions cybersecurity certification). On: a SAM notice is kept only when a keyword is in its title, the first 1,500 characters of its description (clause lists removed), or the buyer name. On TED, keywords must be in a title, description or the CPV category name, not only in annexes or standard terms. Off: use each portal's full-text search.",
            "default": true
          },
          "sources": {
            "title": "Sources",
            "type": "array",
            "description": "Official procurement portals to search. Leave empty to search all six.",
            "items": {
              "type": "string",
              "enum": [
                "sam",
                "ted",
                "uk-fts",
                "uk-cf",
                "canadabuys",
                "worldbank"
              ],
              "enumTitles": [
                "SAM.gov (US federal)",
                "TED (European Union + EEA)",
                "Find a Tender (UK)",
                "Contracts Finder (UK)",
                "CanadaBuys (Canada federal)",
                "World Bank (projects worldwide)"
              ]
            },
            "default": []
          },
          "noticeTypes": {
            "title": "Notice types",
            "type": "array",
            "description": "Which stage of the buying process to return.",
            "items": {
              "type": "string",
              "enum": [
                "tender",
                "pre-notice",
                "award",
                "other"
              ],
              "enumTitles": [
                "Open tenders / solicitations / RFPs",
                "Early notices (prior information, sources sought, RFI, expressions of interest)",
                "Contract awards (who won, for how much)",
                "Other (special notices, sole-source, consultations)"
              ]
            },
            "default": [
              "tender",
              "pre-notice"
            ]
          },
          "countries": {
            "title": "Countries (ISO codes)",
            "type": "array",
            "description": "Two-letter country codes of the buyer, e.g. US, GB, CA, DE, FR, IT, ES, PL, KE. Sources that cannot cover these countries are skipped automatically.",
            "items": {
              "type": "string"
            }
          },
          "cpvCodes": {
            "title": "CPV codes (EU + UK)",
            "type": "array",
            "description": "EU Common Procurement Vocabulary codes. Prefix match: 72000000 = all IT services, 45000000 = all construction work, 79400000 = consulting. When set, only TED and UK sources are searched (plus SAM/CanadaBuys if you also give NAICS/UNSPSC).",
            "items": {
              "type": "string"
            }
          },
          "naicsCodes": {
            "title": "NAICS codes (US)",
            "type": "array",
            "description": "US industry codes for SAM.gov, e.g. 541511 (custom programming), 541512 (systems design), 236220 (commercial building). Exact codes.",
            "items": {
              "type": "string"
            }
          },
          "unspscCodes": {
            "title": "UNSPSC codes (Canada)",
            "type": "array",
            "description": "UNSPSC codes for CanadaBuys. Prefix match: 43000000 = all IT hardware and software, 81110000 = computer services.",
            "items": {
              "type": "string"
            }
          },
          "postedWithinDays": {
            "title": "Posted in the last N days",
            "minimum": 1,
            "maximum": 365,
            "type": "integer",
            "description": "Only notices published in the last N days (today counts as day 1).",
            "default": 7
          },
          "postedAfter": {
            "title": "Posted on or after (overrides the above)",
            "type": "string",
            "description": "Only notices published on or after this date (YYYY-MM-DD)."
          },
          "minDaysLeft": {
            "title": "Minimum days left to bid",
            "minimum": 0,
            "type": "integer",
            "description": "Hide tenders whose deadline is closer than this many days. 0 = hide only expired ones. Notices without a published deadline are kept.",
            "default": 0
          },
          "minValueUsd": {
            "title": "Minimum value (USD)",
            "minimum": 0,
            "type": "integer",
            "description": "Hide notices whose estimated value is known and below this amount (converted to USD with today's ECB rates). Notices without a published value are kept."
          },
          "onlyNew": {
            "title": "Only new notices (alerts mode)",
            "type": "boolean",
            "description": "Remember what earlier runs returned and output only notices you have not received yet. Schedule the actor daily for a tender alert feed: you pay only for new notices.",
            "default": false
          },
          "stateKey": {
            "title": "Alert name",
            "type": "string",
            "description": "Name of the alerts memory. Use a different name for each saved search (e.g. \"it-uk\", \"construction-us\").",
            "default": "default"
          },
          "maxResultsPerSource": {
            "title": "Max notices per source",
            "minimum": 1,
            "type": "integer",
            "description": "Newest notices first. Keeps one busy portal from crowding out the others.",
            "default": 50
          },
          "maxResults": {
            "title": "Max notices in total",
            "minimum": 1,
            "type": "integer",
            "description": "Hard cap for the whole run (newest first).",
            "default": 1000
          },
          "includeDescription": {
            "title": "Include description",
            "type": "boolean",
            "description": "Add the notice description (plain text, HTML removed).",
            "default": true
          },
          "descriptionMaxLength": {
            "title": "Description max length",
            "minimum": 100,
            "type": "integer",
            "description": "Longer descriptions are cut to this many characters.",
            "default": 4000
          },
          "includeContacts": {
            "title": "Include buyer contact",
            "type": "boolean",
            "description": "Add the procurement contact point printed in the notice (contactName, contactEmail, contactPhone) where the portal publishes one (SAM.gov, UK, CanadaBuys, World Bank). Use it only to respond to the tender; see Acceptable use.",
            "default": true
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}