{
  "openapi": "3.0.1",
  "info": {
    "title": "TED (Tenders Electronic Daily) Notice Feed, unofficial",
    "description": "Unofficial feed of public procurement notices from the TED Search API. Filter by notice type, buyer country, CPV code and contract nature. Each run resumes from the last saved publication day.",
    "version": "0.1",
    "x-build-id": "2gdnbWRQ5NEVkWSyc"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/amplelabs~ted-notice-feed/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-amplelabs-ted-notice-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/amplelabs~ted-notice-feed/runs": {
      "post": {
        "operationId": "runs-sync-amplelabs-ted-notice-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/amplelabs~ted-notice-feed/run-sync": {
      "post": {
        "operationId": "run-sync-amplelabs-ted-notice-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": {
          "stateKey": {
            "title": "Feed name (keeps your place between runs)",
            "pattern": "^[a-z0-9-]{3,40}$",
            "type": "string",
            "description": "Runs with the same feed name and filters share one saved position in your named key-value store 'ted-notice-feed-state-<stateKey>'.",
            "default": "default"
          },
          "noticeTypes": {
            "title": "Notice types",
            "type": "array",
            "description": "competition = cn-*; award = can-standard/can-social/can-desg/veat; modification = can-modif; planning = pin-*.",
            "items": {
              "type": "string",
              "enum": [
                "competition",
                "award",
                "modification",
                "planning",
                "other"
              ]
            },
            "default": [
              "competition",
              "award"
            ]
          },
          "buyerCountries": {
            "title": "Buyer countries (ISO 3166 alpha-3)",
            "type": "array",
            "description": "ISO 3166 alpha-3 codes. Empty means every country. Each code is checked against ^[A-Z]{3}$ before it is placed in the query.",
            "items": {
              "type": "string",
              "pattern": "^[A-Z]{3}$"
            },
            "default": []
          },
          "cpvCodes": {
            "title": "CPV codes (prefix match, 2–8 digits)",
            "type": "array",
            "description": "2–8 digits. Empty means every CPV. Each code is matched as a prefix.",
            "items": {
              "type": "string",
              "pattern": "^[0-9]{2,8}$"
            },
            "default": []
          },
          "contractNature": {
            "title": "Contract nature",
            "type": "array",
            "description": "works, supplies, or services. Empty means all three.",
            "items": {
              "type": "string",
              "enum": [
                "works",
                "supplies",
                "services"
              ]
            },
            "default": []
          },
          "minEstimatedValue": {
            "title": "Minimum estimated value (in the notice's currency)",
            "minimum": 0,
            "type": "integer",
            "description": "Applied after download (values are per lot and per currency). Notices without a value are dropped unless 'Keep notices with no value' is on."
          },
          "includeUnknownValue": {
            "title": "Keep notices with no value",
            "type": "boolean",
            "description": "When a minimum estimated value is set, keep notices that have no parseable value.",
            "default": true
          },
          "includeWinnerNames": {
            "title": "Include award winner names (opt-in)",
            "type": "boolean",
            "description": "Off by default (business records only). Winner organisation names and tenderer organisation names on award notices. A winner can be a sole trader, i.e. a person's name. Do not use this output for unsolicited direct marketing to individuals (natural persons, including sole traders).",
            "default": false
          },
          "dateFrom": {
            "title": "First run: publication date from",
            "type": "string",
            "description": "YYYY-MM-DD. Default: the latest publication day. Used only with no saved position or with resetState."
          },
          "maxBackfillDays": {
            "title": "Max publication days per run",
            "minimum": 1,
            "maximum": 30,
            "type": "integer",
            "description": "Publication days to read in one run, from 1 to 30. A scheduled run continues from the last saved day.",
            "default": 1
          },
          "maxResults": {
            "title": "Max notices per run",
            "minimum": 1,
            "maximum": 50000,
            "type": "integer",
            "description": "Stop after this many notices. The saved position is kept.",
            "default": 1000
          },
          "resetState": {
            "title": "Forget saved position",
            "type": "boolean",
            "description": "Forget the saved position for this feed name and these filters. Applied once per run, including after a restart of that same run.",
            "default": false
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}