{
  "openapi": "3.0.1",
  "info": {
    "title": "EU TED Tenders — Public Procurement Notice Scraper",
    "description": "Fetches structured public procurement notices from the official EU TED (Tenders Electronic Daily) API. Filter by country, CPV code, date, value, and notice type. Free, unauthenticated API; clean JSON output ready for CRM/dashboard ingestion.",
    "version": "0.5",
    "x-build-id": "Mdkuj8aCcVjK1SqRj"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/foxlabs~ted-tenders/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-foxlabs-ted-tenders",
        "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/foxlabs~ted-tenders/runs": {
      "post": {
        "operationId": "runs-sync-foxlabs-ted-tenders",
        "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/foxlabs~ted-tenders/run-sync": {
      "post": {
        "operationId": "run-sync-foxlabs-ted-tenders",
        "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": {
          "datePreset": {
            "title": "Date range",
            "enum": [
              "last_24_hours",
              "last_7_days",
              "last_30_days",
              "last_90_days",
              "ytd",
              "custom"
            ],
            "type": "string",
            "description": "Quick date filter. Pick 'Custom' to use the From/To fields below.",
            "default": "last_7_days"
          },
          "publicationDateFrom": {
            "title": "Custom from date",
            "pattern": "^[0-9]{8}$",
            "type": "string",
            "description": "YYYYMMDD format (e.g. 20260501). Only used when Date range = Custom."
          },
          "publicationDateTo": {
            "title": "Custom to date",
            "pattern": "^[0-9]{8}$",
            "type": "string",
            "description": "YYYYMMDD format. Only used when Date range = Custom. Leave empty for 'today'."
          },
          "countries": {
            "title": "Buyer countries",
            "type": "array",
            "description": "Filter by country of the contracting authority. Leave empty for all EU.",
            "items": {
              "type": "string",
              "enum": [
                "DEU",
                "FRA",
                "ITA",
                "ESP",
                "POL",
                "ROU",
                "NLD",
                "BEL",
                "CZE",
                "GRC",
                "PRT",
                "SWE",
                "HUN",
                "AUT",
                "BGR",
                "DNK",
                "FIN",
                "SVK",
                "IRL",
                "HRV",
                "LTU",
                "SVN",
                "LVA",
                "EST",
                "CYP",
                "LUX",
                "MLT",
                "NOR",
                "ISL",
                "LIE",
                "CHE"
              ],
              "enumTitles": [
                "Germany",
                "France",
                "Italy",
                "Spain",
                "Poland",
                "Romania",
                "Netherlands",
                "Belgium",
                "Czechia",
                "Greece",
                "Portugal",
                "Sweden",
                "Hungary",
                "Austria",
                "Bulgaria",
                "Denmark",
                "Finland",
                "Slovakia",
                "Ireland",
                "Croatia",
                "Lithuania",
                "Slovenia",
                "Latvia",
                "Estonia",
                "Cyprus",
                "Luxembourg",
                "Malta",
                "Norway (EEA)",
                "Iceland (EEA)",
                "Liechtenstein (EEA)",
                "Switzerland (EFTA)"
              ]
            },
            "default": []
          },
          "cpvCodes": {
            "title": "Sector (CPV main division)",
            "type": "array",
            "description": "Filter by sector using CPV (Common Procurement Vocabulary) main divisions. Multi-select OK. Leave empty for all sectors. Note: exact CPV match — selecting '72000000 — IT services' returns notices tagged with that exact code (sub-codes like 72100000 not included unless you also select them via Advanced query).",
            "items": {
              "type": "string",
              "enum": [
                "72000000",
                "45000000",
                "33000000",
                "71000000",
                "79000000",
                "80000000",
                "85000000",
                "30000000",
                "34000000",
                "50000000",
                "55000000",
                "60000000",
                "64000000",
                "66000000",
                "73000000",
                "75000000",
                "90000000",
                "48000000",
                "31000000",
                "32000000",
                "44000000",
                "15000000",
                "22000000",
                "24000000",
                "39000000",
                "42000000",
                "70000000",
                "92000000",
                "63000000",
                "65000000"
              ],
              "enumTitles": [
                "72 — IT services & software",
                "45 — Construction work",
                "33 — Healthcare & medical",
                "71 — Architecture, engineering, planning",
                "79 — Business services (legal, consulting, marketing)",
                "80 — Education & training",
                "85 — Health & social work",
                "30 — Office & computing machinery",
                "34 — Transport equipment",
                "50 — Repair & maintenance services",
                "55 — Hotel, restaurant, retail",
                "60 — Transport services",
                "64 — Postal & telecom",
                "66 — Financial & insurance",
                "73 — Research & development",
                "75 — Public administration services",
                "90 — Environmental, sewage, waste",
                "48 — Software packages & info systems",
                "31 — Electrical machinery",
                "32 — Radio, TV, communications",
                "44 — Construction structures & materials",
                "15 — Food & beverages",
                "22 — Printed matter",
                "24 — Chemical products",
                "39 — Furniture & cleaning supplies",
                "42 — Industrial machinery",
                "70 — Real estate services",
                "92 — Recreation, culture, sports",
                "63 — Transport support services",
                "65 — Public utilities (water, energy)"
              ]
            },
            "default": []
          },
          "noticeTypes": {
            "title": "Notice type",
            "type": "array",
            "description": "Filter by notice type. Leave empty for all types.",
            "items": {
              "type": "string",
              "enum": [
                "cn",
                "can-standard",
                "can-modif",
                "pin-only",
                "pin-cfc-standard",
                "corr",
                "subco",
                "bri"
              ],
              "enumTitles": [
                "Contract notice (new tender open for bids)",
                "Contract award (winner announced)",
                "Contract award — modification",
                "Prior information notice (planning, pre-tender)",
                "PIN as call for competition",
                "Corrigendum (correction)",
                "Subcontract",
                "Concession notice"
              ]
            },
            "default": []
          },
          "language": {
            "title": "Output language",
            "enum": [
              "ENG",
              "DEU",
              "FRA",
              "ITA",
              "ESP",
              "POL",
              "NLD",
              "POR",
              "SWE",
              "DAN",
              "FIN",
              "CES",
              "ELL",
              "HUN",
              "RON",
              "SLK",
              "SLV",
              "BUL",
              "HRV",
              "EST",
              "LAV",
              "LIT",
              "GLE",
              "MLT"
            ],
            "type": "string",
            "description": "Language for localized fields (title, description, buyer name). Falls back to English if a notice has no translation.",
            "default": "ENG"
          },
          "maxResults": {
            "title": "Max results",
            "minimum": 0,
            "type": "integer",
            "description": "Hard cap on dataset rows. Helps control cost. Set to 0 for unlimited.",
            "default": 500
          },
          "query": {
            "title": "Advanced — TED expert query",
            "type": "string",
            "description": "POWER USERS ONLY. Native TED DSL. Examples: 'publication-date>=20260101 AND buyer-country=DEU', 'total-value>=1000000 AND classification-cpv=72000000'. If filled, OVERRIDES all filters above. Leave empty for normal use.",
            "default": ""
          },
          "pageSize": {
            "title": "Advanced — API page size",
            "minimum": 1,
            "maximum": 250,
            "type": "integer",
            "description": "Notices fetched per API call. TED max is 250. Default 100 is usually fine.",
            "default": 100
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}