{
  "openapi": "3.0.1",
  "info": {
    "title": "TED EU Procurement Notices Scraper",
    "description": "Structured EU public procurement data: tenders, contract awards, notices from ted.europa.eu — filter by country, CPV code, date or free text. Built on the official TED API.",
    "version": "0.1",
    "x-build-id": "OXMseB0GzmfsCqPzE"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/alwaysprimedev~ted-eu-procurement-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-alwaysprimedev-ted-eu-procurement-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/alwaysprimedev~ted-eu-procurement-scraper/runs": {
      "post": {
        "operationId": "runs-sync-alwaysprimedev-ted-eu-procurement-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/alwaysprimedev~ted-eu-procurement-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-alwaysprimedev-ted-eu-procurement-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",
        "properties": {
          "searchText": {
            "title": "Free-text search",
            "type": "string",
            "description": "Phrase to search inside the notice title (e.g. 'cloud services', 'medical equipment'). Leave blank to ignore."
          },
          "cpvCodes": {
            "title": "CPV codes",
            "uniqueItems": true,
            "type": "array",
            "description": "Common Procurement Vocabulary codes to filter on (e.g. 72000000 for IT services, 33100000 for medical equipment). Multiple codes are OR-combined.",
            "items": {
              "type": "string"
            }
          },
          "buyerCountries": {
            "title": "Buyer countries",
            "uniqueItems": true,
            "type": "array",
            "description": "ISO 3166-1 alpha-3 country codes of contracting authorities (e.g. POL, DEU, FRA). Multiple codes are OR-combined.",
            "items": {
              "type": "string"
            }
          },
          "noticeTypes": {
            "title": "Notice types",
            "uniqueItems": true,
            "type": "array",
            "description": "TED notice types to include (e.g. cn-standard for contract notice, can-standard for contract award). Leave blank for all types.",
            "items": {
              "type": "string"
            }
          },
          "dateFrom": {
            "title": "Published from",
            "type": "string",
            "description": "Earliest publication date to include, format YYYY-MM-DD. Mutually exclusive with 'Days back'."
          },
          "dateTo": {
            "title": "Published to",
            "type": "string",
            "description": "Latest publication date to include, format YYYY-MM-DD."
          },
          "daysBack": {
            "title": "Days back",
            "minimum": 0,
            "type": "integer",
            "description": "Shortcut: only include notices published in the last N days. Ignored if 'Published from' is set.",
            "default": 7
          },
          "scope": {
            "title": "Scope",
            "enum": [
              "ACTIVE",
              "ALL",
              "LATEST"
            ],
            "type": "string",
            "description": "Which set of notices to search: ALL = every notice ever published, ACTIVE = currently active, LATEST = only the most recent OJ S release.",
            "default": "ACTIVE"
          },
          "language": {
            "title": "Preferred language",
            "enum": [
              "eng",
              "deu",
              "fra",
              "spa",
              "ita",
              "pol",
              "ces",
              "nld",
              "por",
              "swe",
              "fin",
              "dan",
              "ron"
            ],
            "type": "string",
            "description": "Three-letter ISO 639-3 code used to pick titles, descriptions and PDFs from multilingual fields. Falls back to English if the requested language is not available.",
            "default": "eng"
          },
          "onlyLatestVersions": {
            "title": "Latest versions only",
            "type": "boolean",
            "description": "When a notice is corrected and re-published, deduplicate to only the latest version. Recommended for most users.",
            "default": true
          },
          "maxItems": {
            "title": "Max results",
            "minimum": 0,
            "type": "integer",
            "description": "Hard cap on the number of records returned. Set to 0 for unlimited (the actor will paginate through every matching notice).",
            "default": 1000
          },
          "pageSize": {
            "title": "Page size (advanced)",
            "minimum": 1,
            "maximum": 250,
            "type": "integer",
            "description": "Number of notices fetched per API call. Up to 250. Increase for fewer round-trips on large queries.",
            "default": 100
          },
          "concurrency": {
            "title": "Concurrency (advanced)",
            "minimum": 1,
            "maximum": 25,
            "type": "integer",
            "description": "Number of parallel API requests. The TED API is fast and has generous limits; 5 is safe.",
            "default": 5
          },
          "fields": {
            "title": "Custom fields (advanced)",
            "uniqueItems": true,
            "type": "array",
            "description": "Override the default field set with custom TED API field names. Leave blank to use the recommended defaults. See https://docs.ted.europa.eu for the full field reference.",
            "items": {
              "type": "string"
            }
          },
          "query": {
            "title": "Expert query (advanced)",
            "type": "string",
            "description": "Raw TED expert-search query string. When set, this overrides every other filter on this form. See https://ted.europa.eu/en/search/expert-search for the syntax."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}