{
  "openapi": "3.0.1",
  "info": {
    "title": "EU Tender Watch: TED Deadlines & Amendments",
    "description": "Watch EU public tenders on TED by buyer country, CPV code and keyword. Get new notices plus change rows when a tracked tender's deadline, estimated value, title or status (award, cancellation) changes, with previous and current values. Dedupes across runs.",
    "version": "0.1",
    "x-build-id": "K0aDR3bCRCd2ShnvC"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/glaciological_huddle~eu-ted-tender-watch/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-glaciological_huddle-eu-ted-tender-watch",
        "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/glaciological_huddle~eu-ted-tender-watch/runs": {
      "post": {
        "operationId": "runs-sync-glaciological_huddle-eu-ted-tender-watch",
        "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/glaciological_huddle~eu-ted-tender-watch/run-sync": {
      "post": {
        "operationId": "run-sync-glaciological_huddle-eu-ted-tender-watch",
        "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": {
          "countries": {
            "title": "Buyer countries",
            "type": "array",
            "description": "3-letter ISO codes of the buyer's country, e.g. DEU, FRA, ITA, ESP, POL, NLD (2-letter codes such as DE or FR are converted). Leave empty for all countries.",
            "default": [
              "DEU"
            ],
            "items": {
              "type": "string"
            }
          },
          "cpvCodes": {
            "title": "CPV codes (prefix match)",
            "type": "array",
            "description": "Common Procurement Vocabulary codes or prefixes. \"72\" = all IT services, \"722\" = software programming and consultancy, \"72200000\" = exactly that code. Matches the main and the additional CPV codes of a notice. Leave empty for all sectors.",
            "default": [
              "72"
            ],
            "items": {
              "type": "string"
            }
          },
          "keywords": {
            "title": "Keywords (full text)",
            "type": "array",
            "description": "Words or phrases searched in the full text of the notice by TED (any of them matches), e.g. \"cloud\", \"data centre\", \"SAP\". Notices are mostly in the buyer's language, so add translations (e.g. \"Rechenzentrum\").",
            "items": {
              "type": "string"
            }
          },
          "noticeStages": {
            "title": "Notice stages for new rows",
            "type": "array",
            "description": "Which kinds of notices start a new row. Default: calls for competition (contract notices, including their change notices). Later award, cancellation and change notices of tenders the watch already tracks are always reported as amendment rows, whatever you pick here.",
            "items": {
              "type": "string",
              "enum": [
                "competition",
                "planning",
                "result",
                "direct-award",
                "modification"
              ],
              "enumTitles": [
                "Competition: contract notices (open tenders)",
                "Planning: prior information notices",
                "Result: contract award notices",
                "Direct award: voluntary ex-ante transparency notices",
                "Modification: contract modification notices"
              ]
            },
            "default": [
              "competition"
            ]
          },
          "daysBack": {
            "title": "Days back (publication date)",
            "minimum": 1,
            "maximum": 30,
            "type": "integer",
            "description": "Read notices published in the last N days (1 to 30). 3 is a good daily setting (it covers weekends); a first run with 30 builds a baseline so later deadline changes and awards can be matched.",
            "default": 3
          },
          "deadlineAfter": {
            "title": "Only tenders with a deadline on or after",
            "pattern": "^$|^(?:[Tt][Oo][Dd][Aa][Yy]|\\d{4}-\\d{2}-\\d{2})$",
            "type": "string",
            "description": "Optional: keep only new notices with a submission deadline on or after this date (YYYY-MM-DD), or type \"today\" for tenders that are still open. Notices without a deadline (e.g. award notices) are then left out. Does not apply to amendment rows."
          },
          "minEstimatedValue": {
            "title": "Minimum estimated value",
            "minimum": 0,
            "type": "number",
            "description": "Optional: keep only new notices whose estimated value is at least this amount (in the notice's currency, usually EUR). Does not apply to amendment rows."
          },
          "includeMissingValue": {
            "title": "Keep notices without an estimated value",
            "type": "boolean",
            "description": "Many notices do not disclose a value. With a minimum value set, keep them (on) or drop them (off).",
            "default": true
          },
          "onlyNew": {
            "title": "Watch mode (only new and changed)",
            "type": "boolean",
            "description": "On: remember every notice output under the watch name and never output it again; later notices of the same procedure become amendment rows. Off: one-off report of the whole window (changes are still detected within the window), nothing remembered.",
            "default": true
          },
          "watchName": {
            "title": "Watch name",
            "type": "string",
            "description": "Name of the memory used by watch mode. Use one name per shortlist (e.g. \"de-it-services\"). Runs with the same name share what has been seen.",
            "default": "default"
          },
          "maxItems": {
            "title": "Max rows per run",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Stop after this many rows (each row is one charged event). Rows not output are picked up by the next run in watch mode.",
            "default": 50
          },
          "maxNoticesScanned": {
            "title": "Max notices scanned",
            "minimum": 1,
            "maximum": 15000,
            "type": "integer",
            "description": "Upper bound on notices read from TED in one run (250 per request), whether or not they become rows.",
            "default": 1000
          },
          "followTrackedTenders": {
            "title": "Follow tracked tenders",
            "type": "boolean",
            "description": "Also ask TED for later notices of open tenders this watch already tracks (50 procedures per request), so award and cancellation notices are reported even when they would not match your filters.",
            "default": true
          },
          "maxTrackedChecked": {
            "title": "Max tracked tenders followed",
            "minimum": 0,
            "maximum": 500,
            "type": "integer",
            "description": "How many open tracked tenders (most recently seen first) are followed per run.",
            "default": 100
          },
          "includeUnchangedFollowUps": {
            "title": "Output follow-up notices without tracked changes",
            "type": "boolean",
            "description": "A later notice of a tracked tender that changes none of deadline, value, title or status (e.g. a corrected document link) is normally only remembered, not output (and not charged). Turn on to output it as an amendment row with an empty change list.",
            "default": false
          },
          "expertQuery": {
            "title": "Advanced: TED expert query",
            "type": "string",
            "description": "Optional TED expert-search query that REPLACES countries, CPV codes, keywords and stages, e.g. buyer-country IN (AUT CHE) AND classification-cpv IN (45*) AND procedure-type=open. The publication-date window and sorting are added by the Actor (do not use SORT BY). Test it on ted.europa.eu/en/search/expert-search."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}