# TED Tender Changes (`thescrapelab/ted-tender-changes`) Actor

Track EU tender bid-deadline changes by lot using official TED daily XML. Filter by CPV category and buyer country, compare published deadlines, and export old/new dates with time zones and both source notices.

- **URL**: https://apify.com/thescrapelab/ted-tender-changes.md
- **Developed by:** [Inus Grobler](https://apify.com/thescrapelab) (community)
- **Categories:** Business
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.40 / 1,000 lot deadline changes

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## TED Tender Changes

A TED tender deadline scraper and change monitor for EU procurement at lot level. TED Tender Changes compares linked public notices from TED's official daily XML packages and returns only changes to explicitly published tender-submission deadlines.

Suppliers can filter procurement categories and buyer countries, then send the resulting JSON, CSV or Excel data into their bid-tracking workflow. Each change includes both source notices, the affected lot, buyer, CPV codes, and old/new deadlines with the published time-zone offsets and normalized UTC values.

### Input — run a watch

1. Open **Input**. Optionally enter CPV prefixes such as `38` (laboratory equipment) or `72` (IT services), and buyer country codes such as `POL` or `FRA`.
2. Choose the number of recent publication days and maximum new changes.
3. Run the Actor. Export the default dataset from **Storage**.

```json
{"cpvCodes":["38"],"countries":["POL"],"daysBack":2,"maxResults":10}
```

Empty category/country lists cover all categories/countries. The default checks two publication days and returns at most one new change. A result limit is a maximum, not a promise that enough amendments exist.

| Input | Default | Meaning |
|---|---|---|
| `cpvCodes` | `[]` | Two-to-eight-digit CPV codes or prefixes; matches lot CPV values. |
| `countries` | `[]` | Three-letter TED buyer country codes, e.g. `FRA`, `POL`, `DEU`. |
| `daysBack` | `2` | Recent publication issues, up to 30; weekends do not count as issues. |
| `maxResults` | `1` | Maximum new lot deadline changes, up to 1,000. |

Repeat the same category/country watch to discover new changes. Already delivered event IDs are suppressed while the watch's persistent storage remains available. Completed older publication issues are checkpointed; the latest issue is always fetched again. Changing only the lookback or result limit continues the same watch. Concurrent runs of the same watch are refused; different watches have separate history and can overlap.

### Output

One record represents one lot's bid-submission deadline change. Awards, question deadlines, request-to-participate deadlines, and unchanged lots do not become bid-deadline alerts.

This abbreviated example is a real published amendment, not an invented tender:

```json
{
  "procedureId":"afbc9a05-b467-4c2c-8822-85ebfb107176",
  "lotId":"LOT-0001",
  "field":"bid_submission_deadline",
  "buyer":[{"id":"ORG-0001","name":"CINOR","country":"FRA"}],
  "cpv":["77310000"],
  "oldDeadline":{"dateRaw":"2026-11-20+01:00","timeRaw":"12:00:00+01:00","local":"2026-11-20T12:00:00+01:00","utc":"2026-11-20T11:00:00+00:00"},
  "newDeadline":{"dateRaw":"2026-11-25+01:00","timeRaw":"12:00:00+01:00","local":"2026-11-25T12:00:00+01:00","utc":"2026-11-25T11:00:00+00:00"},
  "oldNotice":"778448-2026",
  "newNotice":"788322-2026",
  "oldSource":"https://ted.europa.eu/en/notice/-/detail/778448-2026",
  "newSource":"https://ted.europa.eu/en/notice/-/detail/788322-2026"
}
```

Flat `oldBidDeadline` and `newBidDeadline` fields make the published zoned times easy to use in tables and CSV. Full records also contain a stable `eventId`, `collectedAt` UTC timestamp , `sourceWarnings`, the current notice’s official `sourcePackage` download link, and both XML hashes for verification. Buyer names/IDs and CPV lists come from the actual notice; missing optional source values remain null or empty.

**Time-zone caveat:** the CINOR notices above contain structured `+01:00` offsets but wording referring to local noon in Réunion. The Actor preserves the structured values and warns about possible wording conflicts. Confirm source documents before scheduling operational reminders.

Source: Publications Office of the European Union, [Tenders Electronic Daily](https://ted.europa.eu/). This Actor is independent of TED. Both official notice links are retained for attribution and verification.

Buyer `id` values are local references within a notice, not global company identifiers. `lotTitle` preserves the source lot name when available.

### Coverage and limitations

- This is a deadline-change monitor, not a complete tender search or award feed. An award never becomes an open bid because it has a future date or an “open procedure” label.
- An explicit predecessor, same procedure, same lot ID, and two parseable zoned deadlines are required. Added/removed lots and first-time deadlines are not reported as deadline changes.
- Both source XML documents are used for emitted changes. Official Search API metadata locates older issues and conservatively skips uniformly unchanged deadlines; metadata arrays are never assumed to align by index.
- Official packages can be large even for one matching change. Source timeouts, missing predecessor notices or bounded history limits can yield partial coverage. Check `RUN_SUMMARY`; incomplete coverage is reported as a failed run, with any valid delivered rows retained.
- The current archive safety bound is 40 issues and the application time budget starts at 60 seconds and can grow by three seconds per delivered change, to at most 14 minutes. Large lookbacks can require repeated runs and are not guaranteed to exhaust the source in one run.
- Non-immediate amendment chains that conflict with previously observed deadlines are withheld for review rather than presented as verified immediate changes.
- Preserving event history prevents normal replay duplicates. Deleting watch storage resets that history. Do not run overlapping watches if you need account-wide deduplication.
- Historical reconstruction is limited to available public XML and explicit links. This is not a complete legal procurement history or a guarantee of bid eligibility.

### Pricing

The Actor charges **$0.015 per run at the default 1 GB**, plus **$0.0004 for each newly delivered lot deadline change** ($0.40 per 1,000 changes). Platform usage is included; there are no proxy or external API charges.

| New changes in one run | Price at 1 GB |
|---:|---:|
| 0 | $0.015 |
| 1 | $0.0154 |
| 10 | $0.019 |
| 100 | $0.055 |
| 1,000 | $0.415 |

The run charge covers checking official publication packages even when a narrow watch finds no new changes. A replay with no new output pays only the run charge. Previously delivered event IDs are not appended or billed again within the same watch. Different, overlapping watches have separate history.

The automatic startup event is charged per GB, minimum one. Keep the default 1 GB; allocations above 1 GB are not supported. The minimum spending limit is $0.0154. If your spending limit is reached, the Actor stops and records `BUDGET_LIMIT` rather than claiming full coverage. No bulk discount tiers are currently configured.

### Python API

```python
import os
from apify_client import ApifyClient

client = ApifyClient(os.environ["APIFY_TOKEN"])
run = client.actor("thescrapelab/ted-tender-changes").call(
    run_input={"cpvCodes":["38"], "countries":["POL"], "maxResults":10}
)
for change in client.dataset(run.default_dataset_id).iterate_items():
    print(change["lotId"], change["oldDeadline"]["local"], change["newDeadline"]["local"])
```

### Use cases

- Update supplier bid calendars from published deadline changes, after checking source wording and time zones.
- Track matching CPV categories and buyer countries in procurement spreadsheets or a CRM.
- Keep both notice links and XML hashes alongside each lot change for later verification.

### FAQ

**Does a run with no rows mean there are no amendments?** Only if `RUN_SUMMARY.status` is `COMPLETE`; otherwise review partial coverage. An unchanged or previously delivered amendment also produces no new row.

**Can I monitor different categories?** Yes. CPV prefixes and country lists define a watch. Use Apify scheduling after selecting your desired inputs; this Actor does not create schedules automatically.

**How is this different from TED email alerts?** It returns structured, lot-specific before/after bid deadlines with links to both notices for downstream automations. TED's free notice alerts remain useful for general procurement discovery.

**What should I include in a support request?** The run URL, affected notice URLs and expected lot ID. Never send API keys or other credentials.

### Enriched change fields

CSV exports now include `buyerName`, `buyerCountry`, explicitly designated `primaryCpvCode`, `changeDirection`, signed `deadlineChangeHours`, and both notice publication dates. Multiple distinct buyers/countries are joined with `|` for display; the original arrays remain authoritative. Missing source values remain null. Movement hours compare UTC instants, including offset changes; publication dates are calendar dates, not invented timestamps.

`sourceWarningDetails` contains rule codes, original wording, source notice/language and geographic evidence. Rule-based phrase checks cover all24 EU official languages; arbitrary wording, translations and ambiguous lot references are not fully understood. Warnings based on performance location are possible conflicts, not confirmed submission locations. Geographic checks use explicit region overrides only; unknown geography is reported unresolved. `warningAssessment` discloses unassessed languages and rule/tzdata versions. Published deadlines are never corrected automatically.

The `coverage` object in RUN_SUMMARY separates fresh XML lot comparisons, changed/unchanged/uncomparable lots, metadata skips, checkpointed issues, duplicate suppression and newly delivered changes. These are run-local counters, not historical totals. Summary diagnostics are not paid dataset rows. `watchExhausted` is false for partial runs and spending/result/time limits.

# Actor input Schema

## `cpvCodes` (type: `array`):

CPV codes or prefixes. Empty means all categories.

## `countries` (type: `array`):

Three-letter TED buyer country codes, for example POL or FRA. Empty means all countries.

## `daysBack` (type: `integer`):

Recent publication days to inspect; weekends are skipped.

## `maxResults` (type: `integer`):

Maximum unique lot deadline changes delivered.

## Actor input object example

```json
{
  "cpvCodes": [],
  "countries": [],
  "daysBack": 2,
  "maxResults": 1
}
```

# Actor output Schema

## `changes` (type: `string`):

No description

## `summary` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {};

// Run the Actor and wait for it to finish
const run = await client.actor("thescrapelab/ted-tender-changes").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {}

# Run the Actor and wait for it to finish
run = client.actor("thescrapelab/ted-tender-changes").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{}' |
apify call thescrapelab/ted-tender-changes --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,thescrapelab/ted-tender-changes"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/mRjNhQ3Xcy9a4HBpm/builds/kPImTl3QcQYdxgi0w/openapi.json
