{
  "openapi": "3.0.1",
  "info": {
    "title": "French Public Tenders & Contracts – BOAMP + DECP",
    "description": "French public procurement in one Actor: open tenders from BOAMP with buyer contacts, CPV, estimated value, lots and documents link; awarded contracts from DECP with winners and amounts; market analysis (top winners, buyers, sectors); alerts for new tenders.",
    "version": "0.1",
    "x-build-id": "D7o1aRRccfvpxPK57"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/yck69~french-public-procurement/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-yck69-french-public-procurement",
        "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/yck69~french-public-procurement/runs": {
      "post": {
        "operationId": "runs-sync-yck69-french-public-procurement",
        "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/yck69~french-public-procurement/run-sync": {
      "post": {
        "operationId": "run-sync-yck69-french-public-procurement",
        "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": [
          "mode"
        ],
        "properties": {
          "mode": {
            "title": "What do you want?",
            "enum": [
              "tenders",
              "contracts",
              "analysis"
            ],
            "type": "string",
            "description": "<b>Tenders</b>: notices from BOAMP (open calls for tenders, award results…) with buyer contacts, CPV, estimated value, lots and documents link.<br><b>Awarded contracts</b>: who won which contract and for how much (DECP, 3+ million contracts).<br><b>Market analysis</b>: top winners, buyers, sectors or months for your filters, with totals and market shares.",
            "default": "tenders"
          },
          "keywords": {
            "title": "Keywords",
            "type": "array",
            "description": "One search per line; a notice matches if it contains <b>all the words</b> of <b>any line</b>. Example: <code>nettoyage</code> and <code>entretien locaux</code>.",
            "items": {
              "type": "string"
            }
          },
          "cpvCodes": {
            "title": "CPV codes",
            "type": "array",
            "description": "EU procurement codes, full or partial: <code>72</code> (all IT services), <code>4521</code>, <code>90911000</code>.",
            "items": {
              "type": "string"
            }
          },
          "contractTypes": {
            "title": "Contract types",
            "type": "array",
            "description": "Works, services or supplies.",
            "items": {
              "type": "string",
              "enum": [
                "works",
                "services",
                "supplies"
              ],
              "enumTitles": [
                "Works",
                "Services",
                "Supplies"
              ]
            }
          },
          "departments": {
            "title": "Departments",
            "type": "array",
            "description": "Department codes, e.g. <code>69</code>, <code>75</code>, <code>2A</code>, <code>971</code>. Tenders: the notice's departments. Contracts: the buyer's department or the place of performance.",
            "items": {
              "type": "string"
            }
          },
          "buyerName": {
            "title": "Buyer name contains",
            "type": "string",
            "description": "Part of the buyer's name, e.g. <code>Lyon</code>, <code>CHU</code>, <code>Département du Nord</code>."
          },
          "noticeTypes": {
            "title": "Notice types",
            "type": "array",
            "description": "Default: open calls for tenders only.",
            "items": {
              "type": "string",
              "enum": [
                "APPEL_OFFRE",
                "ATTRIBUTION",
                "PRE-INFORMATION",
                "RECTIFICATIF",
                "ANNULATION",
                "MODIFICATION"
              ],
              "enumTitles": [
                "Calls for tenders",
                "Award results",
                "Prior information",
                "Corrections",
                "Cancellations",
                "Contract modifications"
              ]
            },
            "default": [
              "APPEL_OFFRE"
            ]
          },
          "openOnly": {
            "title": "Only tenders still open",
            "type": "boolean",
            "description": "Keep only calls for tenders whose response deadline hasn't passed.",
            "default": true
          },
          "publishedAfter": {
            "title": "Published after",
            "type": "string",
            "description": "A date (<code>2026-10-01</code>) or a duration (<code>7 days</code>, <code>3 months</code>)."
          },
          "publishedBefore": {
            "title": "Published before",
            "type": "string",
            "description": "A date or a duration, like \"Published after\"."
          },
          "searchIn": {
            "title": "Search keywords in",
            "enum": [
              "everywhere",
              "title"
            ],
            "type": "string",
            "description": "Searching the whole notice finds more; the title is more precise.",
            "default": "everywhere"
          },
          "families": {
            "title": "Contract size / regime",
            "type": "array",
            "description": "The legal regime, which depends on the estimated value.",
            "items": {
              "type": "string",
              "enum": [
                "MAPA",
                "FNS",
                "JOUE",
                "DSP",
                "DIVERS"
              ],
              "enumTitles": [
                "Under €90k (MAPA)",
                "€90k to EU thresholds",
                "Above EU thresholds (JOUE)",
                "Public service delegations (DSP)",
                "Other"
              ]
            }
          },
          "minEstimatedValue": {
            "title": "Minimum estimated value (€)",
            "type": "integer",
            "description": "Notices without an estimated value are excluded when this is set."
          },
          "maxEstimatedValue": {
            "title": "Maximum estimated value (€)",
            "type": "integer",
            "description": "Notices without an estimated value are excluded when this is set."
          },
          "onlyNew": {
            "title": "Only notices not seen in previous runs (alerts)",
            "type": "boolean",
            "description": "Remembers the notices already returned, so a scheduled run only outputs new ones. Combine with a schedule and an email/Slack integration for tender alerts.",
            "default": false
          },
          "monitorName": {
            "title": "Alert name",
            "type": "string",
            "description": "Keeps separate memories for separate alerts, e.g. <code>cleaning-lyon</code>. Defaults to one memory per set of filters."
          },
          "includeRawNotice": {
            "title": "Include the full original notice",
            "type": "boolean",
            "description": "Adds the complete notice as published (large).",
            "default": false
          },
          "awardedAfter": {
            "title": "Awarded after",
            "type": "string",
            "description": "A date (<code>2025-01-01</code>) or a duration (<code>12 months</code>)."
          },
          "awardedBefore": {
            "title": "Awarded before",
            "type": "string",
            "description": "A date or a duration, like \"Awarded after\"."
          },
          "regions": {
            "title": "Buyer regions",
            "type": "array",
            "description": "Region of the buyer.",
            "items": {
              "type": "string",
              "enum": [
                "11",
                "24",
                "27",
                "28",
                "32",
                "44",
                "52",
                "53",
                "75",
                "76",
                "84",
                "93",
                "94",
                "01",
                "02",
                "03",
                "04",
                "06"
              ],
              "enumTitles": [
                "Île-de-France",
                "Centre-Val de Loire",
                "Bourgogne-Franche-Comté",
                "Normandie",
                "Hauts-de-France",
                "Grand Est",
                "Pays de la Loire",
                "Bretagne",
                "Nouvelle-Aquitaine",
                "Occitanie",
                "Auvergne-Rhône-Alpes",
                "Provence-Alpes-Côte d'Azur",
                "Corse",
                "Guadeloupe",
                "Martinique",
                "Guyane",
                "La Réunion",
                "Mayotte"
              ]
            }
          },
          "buyerIds": {
            "title": "Buyer SIRET / SIREN",
            "type": "array",
            "description": "Exact SIRET (14 digits) or SIREN (9 digits, matches all its establishments).",
            "items": {
              "type": "string"
            }
          },
          "buyerCategories": {
            "title": "Buyer types",
            "type": "array",
            "description": "Type of public buyer.",
            "items": {
              "type": "string",
              "enum": [
                "Commune",
                "Groupement de communes",
                "Département",
                "Région",
                "État",
                "EPIC",
                "Établissement hospitalier",
                "Syndicat mixte",
                "Département outre-mer"
              ],
              "enumTitles": [
                "Municipality",
                "Group of municipalities",
                "Department",
                "Region",
                "State",
                "Public industrial body (EPIC)",
                "Hospital",
                "Joint syndicate",
                "Overseas department"
              ]
            }
          },
          "winnerName": {
            "title": "Winner name contains",
            "type": "string",
            "description": "Track a competitor, e.g. <code>Onet</code>, <code>Capgemini</code>."
          },
          "winnerIds": {
            "title": "Winner SIRET / SIREN",
            "type": "array",
            "description": "Exact SIRET (14 digits) or SIREN (9 digits, matches all its establishments).",
            "items": {
              "type": "string"
            }
          },
          "winnerCategories": {
            "title": "Winner size",
            "type": "array",
            "description": "Size category of the winning company (INSEE).",
            "items": {
              "type": "string",
              "enum": [
                "PME",
                "ETI",
                "GE"
              ],
              "enumTitles": [
                "SME (PME)",
                "Mid-size (ETI)",
                "Large (GE)"
              ]
            }
          },
          "minAmount": {
            "title": "Minimum amount (€)",
            "type": "integer",
            "description": "Contract amount in euros, excluding VAT as declared by the buyer."
          },
          "maxAmount": {
            "title": "Maximum amount (€)",
            "type": "integer",
            "description": "Contract amount in euros."
          },
          "procedures": {
            "title": "Procedures",
            "type": "array",
            "description": "How the contract was awarded.",
            "items": {
              "type": "string",
              "enum": [
                "open",
                "restricted",
                "adapted",
                "negotiated",
                "competitiveDialogue",
                "noCompetition"
              ],
              "enumTitles": [
                "Open call for tenders",
                "Restricted call for tenders",
                "Adapted procedure (MAPA)",
                "Negotiated",
                "Competitive dialogue",
                "Without prior competition"
              ]
            }
          },
          "frameworkOnly": {
            "title": "Framework agreements only",
            "type": "boolean",
            "description": "Keep only framework agreements (accords-cadres), which often run for several years.",
            "default": false
          },
          "excludeAbnormalAmounts": {
            "title": "Exclude aberrant amounts",
            "type": "boolean",
            "description": "The dataset flags amounts that are clearly wrong (e.g. typos with extra zeros). Recommended for totals and rankings.",
            "default": true
          },
          "groupBy": {
            "title": "Analyse by",
            "enum": [
              "winner",
              "buyer",
              "cpv",
              "buyerDepartment",
              "winnerDepartment",
              "month",
              "year",
              "procedure",
              "contractType",
              "winnerCategory"
            ],
            "type": "string",
            "description": "One row per winner, buyer, sector, department, month… with contracts, totals and market share.",
            "default": "winner"
          },
          "cpvLevel": {
            "title": "Sector detail (when analysing by CPV)",
            "enum": [
              "2",
              "3",
              "4",
              "5",
              "8"
            ],
            "type": "string",
            "description": "How detailed the sectors are when analysing by CPV.",
            "default": "2"
          },
          "sortBy": {
            "title": "Rank by",
            "enum": [
              "totalAmount",
              "contracts"
            ],
            "type": "string",
            "description": "How the analysis rows are ranked.",
            "default": "totalAmount"
          },
          "maxResults": {
            "title": "Maximum results",
            "minimum": 1,
            "maximum": 500000,
            "type": "integer",
            "description": "Notices, contracts or analysis rows.",
            "default": 100
          },
          "countOnly": {
            "title": "Count only (free preview)",
            "type": "boolean",
            "description": "Only count matching notices or contracts and estimate the cost. Nothing is charged.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}