{
  "openapi": "3.0.1",
  "info": {
    "title": "Government Tenders Scraper: SAM.gov & EU TED",
    "description": "Get US federal contract opportunities from SAM.gov and EU public tenders from TED in one clean format. Filter by keyword, country, CPV/NAICS code and date. Only new tenders on each run.",
    "version": "0.3",
    "x-build-id": "3WRX2GOVjLUqF36L3"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/carmentara~procurement-radar/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-carmentara-procurement-radar",
        "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/carmentara~procurement-radar/runs": {
      "post": {
        "operationId": "runs-sync-carmentara-procurement-radar",
        "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/carmentara~procurement-radar/run-sync": {
      "post": {
        "operationId": "run-sync-carmentara-procurement-radar",
        "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",
        "required": [
          "sources"
        ],
        "properties": {
          "sources": {
            "title": "Sources",
            "type": "array",
            "description": "Data sources to query",
            "items": {
              "type": "string",
              "enum": [
                "sam",
                "ted"
              ],
              "enumTitles": [
                "US SAM.gov",
                "EU TED"
              ]
            }
          },
          "includeClosed": {
            "title": "Include closed (past deadline) notices",
            "type": "boolean",
            "description": "When false (default), exclude notices whose deadline has passed."
          },
          "keywords": {
            "title": "Keywords",
            "type": "array",
            "description": "Keywords to match in title/description",
            "items": {
              "type": "string"
            }
          },
          "cpvCodes": {
            "title": "CPV codes (TED)",
            "type": "array",
            "description": "List of CPV codes to filter by (TED only), e.g. 72000000",
            "items": {
              "type": "string"
            }
          },
          "naicsCodes": {
            "title": "NAICS codes (SAM.gov)",
            "type": "array",
            "description": "List of NAICS codes to filter by (SAM only), e.g. 541511",
            "items": {
              "type": "string"
            }
          },
          "countries": {
            "title": "Countries",
            "type": "array",
            "description": "ISO country codes (e.g. US, DE). For TED, buyer or contract location; for SAM, place of performance.",
            "items": {
              "type": "string"
            }
          },
          "dateFilter": {
            "title": "Date filter",
            "enum": [
              "publicationDate",
              "deadline"
            ],
            "type": "string",
            "description": "Which date field to constrain by (publication or deadline)."
          },
          "dateFrom": {
            "title": "Date from (ISO)",
            "type": "string",
            "description": "Start date inclusive, e.g. 2026-01-01 or 2026-01-01T00:00:00Z"
          },
          "dateTo": {
            "title": "Date to (ISO)",
            "type": "string",
            "description": "End date inclusive, e.g. 2026-12-31 or 2026-12-31T23:59:59Z"
          },
          "noticeTypes": {
            "title": "Notice types",
            "type": "array",
            "description": "Filter by source-specific notice types (e.g., Contract notice, Prior information notice, Sources Sought, Presolicitation). Leave empty for all.",
            "items": {
              "type": "string"
            }
          },
          "includeAwardResults": {
            "title": "Include award/result notices",
            "type": "boolean",
            "description": "When false (default), exclude award/result notices (e.g., can-standard) from open-tender results."
          },
          "maxResults": {
            "title": "Max results",
            "minimum": 0,
            "maximum": 50000,
            "type": "integer",
            "description": "Stop after emitting this many results total across sources (0 means no cap)."
          },
          "onlyNew": {
            "title": "Only new since last run",
            "type": "boolean",
            "description": "Emit only new notices since the last successful run (per-source dedupe using KV store)."
          },
          "includeRaw": {
            "title": "Include raw record",
            "type": "boolean",
            "description": "Include a `raw` field with the source payload. GDPR-safe fields only are normalized; raw may contain PII which is stripped before output."
          },
          "samApiKey": {
            "title": "SAM.gov API key",
            "type": "string",
            "description": "Your SAM.gov Opportunities API key. Required when querying SAM.gov."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}