# French Insolvency Monitor (BODACC) (`tjasmin/french-insolvency-monitor`) Actor

Get alerted when a French customer or supplier enters insolvency (safeguard, receivership, liquidation). Daily BODACC watch with creditor guidance.

- **URL**: https://apify.com/tjasmin/french-insolvency-monitor.md
- **Developed by:** [JASMIN Tony](https://apify.com/tjasmin) (community)
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage, which gets cheaper the higher subscription plan you have.

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

## 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

## French Insolvency Monitor (BODACC)

**Get told when one of your French customers or suppliers enters a collective insolvency procedure.**

This Actor is a *monitor*, not just an extractor. Give it the SIREN numbers you care about (or a département, or nothing at all), schedule it daily, and each run returns **only the announcements you have not seen before**: safeguard, receivership (redressement), liquidation, rescue plans, closures and claims notices published in the official French gazette, the **BODACC** (Bulletin officiel des annonces civiles et commerciales).

Every row comes with a plain-language explanation (English and French) and **what it means for you as a creditor**.

### Data source

The public open-data API of the DILA (the French government publisher of the BODACC), dataset `annonces-commerciales`, restricted to the "collective procedures" family. No scraping, no API key, no AI call. Data is published by DILA under the French *Licence Ouverte / Open Licence v2.0*. **Source: BODACC, DILA (Direction de l'information légale et administrative)**; keep this attribution if you reuse the data. Each row links to the original notice (`noticeUrl`). This Actor is not affiliated with or endorsed by DILA.

### Use cases

1. **Watch your customers.** Load your customer SIREN list, schedule a daily run, and get a row the day one of them enters safeguard, receivership or liquidation, with the claim-filing deadline to act on.
2. **Watch your suppliers.** Know before a key supplier fails, so you can find alternatives, stop prepayments or secure stock.
3. **Monitor a portfolio.** Follow a loan book, a list of investments or acquisition targets, or all new receiverships and liquidations in a département, without any SIREN filter.

### Example inputs

**Monitor mode** (schedule it daily; returns only what is new since the last run):

```json
{
  "mode": "monitor",
  "watchName": "my-suppliers",
  "sirens": ["878235308", "820394062"],
  "procedureTypes": ["receivership", "liquidation"],
  "initialDays": 7,
  "maxResults": 1000
}
```

**Search mode** (one-off, no state). With an empty input, it returns the 20 most recent announcements of the last 7 days. Explicit date range:

```json
{
  "mode": "search",
  "departments": ["37", "14"],
  "dateFrom": "2026-10-01",
  "dateTo": "2026-10-31",
  "includeNaturalPersons": false
}
```

### Input

| Field | Description | Default |
|---|---|---|
| `mode` | `search` (date range, the default) or `monitor` (new since last run). The former French values `surveillance` / `recherche` are still accepted. | `search` |
| `watchName` | Name of the watch. **Each watch keeps its own state**: two watches never share their "already seen" list. | `default` |
| `sirens` | 9-digit SIREN list (a 14-digit SIRET is shortened). Empty = no SIREN filter. | – |
| `departments` | Département codes (`75`, `2A`, `971`…). | all |
| `procedureTypes` | `safeguard`, `receivership`, `liquidation`, `plan`, `closure`, `claims`, `other`. | all |
| `initialDays` | First run of a watch: look back N days. | `7` |
| `dateFrom` / `dateTo` | Search mode: publication date range. | – / today |
| `lastDays` | Search mode: when `dateFrom` is empty, return the last N days (today included). | `7` |
| `maxResults` | Hard cap per run (cost control). Raise it for real use. | `20` |
| `includeNaturalPersons` | See "Personal data" below. | `true` |
| `stateStoreName` | Named key-value store holding the state. | `french-insolvency-monitor-state` |

#### How monitor mode works

The state key is `watchName` + a hash of your filters, stored in a **named key-value store** (it survives between runs). Consequences:

- Changing `watchName` or any filter (SIREN, département, types, natural persons) starts a **new** watch, whose first run looks back `initialDays`.
- Each run re-scans the last 3 days to catch late or corrected notices; notices already returned are never returned twice (deduplicated by `noticeId`).
- If `maxResults` is reached, the rest comes out on the next run (nothing is lost).
- A failed run does not advance the watch.

#### Personal data (`includeNaturalPersons`)

The BODACC also publishes procedures of **natural persons** (sole traders, *entrepreneurs individuels*). They are included **by default** because a sole trader going into liquidation is as relevant to a creditor as a company. These rows contain a person's name (`denomination` = "SURNAME Firstname") and sometimes a trade name. If you only follow companies, or if you do not want to process personal data, set `includeNaturalPersons` to `false`. Rows for natural persons are personal data. The data comes from a public gazette, but you remain responsible for your own GDPR compliance.

### Output (one row per announcement)

| Field | Meaning |
|---|---|
| `siren`, `denomination`, `tradeName`, `personType` | Identity (`legalEntity` / `naturalPerson`). `siren` is `null` when the notice does not carry one. |
| `procedureCategory` | Normalized: `safeguard`, `receivership`, `liquidation`, `plan`, `closure`, `claims`, `other`. |
| `procedureNature`, `judgmentFamily` | Original wording from the BODACC (French). |
| `isConversion` | `true` when a procedure is converted or a plan is cancelled (e.g. receivership → liquidation). |
| `explanationEn`, `explanationFr` | What the announcement means. |
| `creditorActionEn`, `creditorActionFr` | What it means for a creditor. |
| `judgmentDate`, `judgmentDateRaw` | ISO date (`null` if unreadable) and the raw value. |
| `judgmentDetails` | Free text of the judgment (administrator, claim filing details…). |
| `tribunal`, `city`, `postalCode`, `department`, `departmentName` | Court and location. |
| `publicationDate`, `noticeId`, `noticeUrl` | Publication date and link to the BODACC notice. |
| `noticeType` | `initial`, `correction` or `cancellation`. |
| `previousNoticeId`, `previousNoticeUrl`, `previousNoticeDate` | For corrections and cancellations: the notice being corrected. |

Example (abridged):

```json
{
  "siren": "820394062",
  "denomination": "LANCELIN ET FILS",
  "procedureCategory": "receivership",
  "procedureNature": "Jugement d'ouverture d'une procédure de redressement judiciaire",
  "isConversion": false,
  "explanationEn": "Receivership (redressement judiciaire): the company has stopped paying its debts but may be rescued…",
  "creditorActionEn": "File your claim with the creditors’ representative within 2 months of publication…",
  "judgmentDate": "2026-11-18",
  "tribunal": "Greffe du Tribunal de Commerce de Caen",
  "department": "14",
  "publicationDate": "2026-11-26",
  "noticeId": "A202602272502",
  "noticeType": "initial"
}
```

### Good to know

- The `other` category is a heuristic catch-all (director bans, appeals, miscellaneous judgments): category rules are deterministic keyword matches, so some notices may land in `other` or in a neighbouring category. The original wording is always in `procedureNature`.
- Category rules are deterministic (keywords on the judgment nature). Generic natures ("Autre jugement…") fall back on the start of the judgment text.
- SIREN is missing on about 7 % of notices (`siren` is `null`). The Actor also searches the persons block, and rows without a SIREN are only kept when you do not filter by SIREN.
- BODACC publication lags the court decision by days or weeks: `judgmentDate` is the decision, `publicationDate` is when you can know.
- Explanations are general information, **not legal advice**. Check deadlines with a lawyer or the court-appointed representative.

### Cost

Plain HTTP calls to a public API, no browser, no proxy: runs use minimal compute (a daily watch on a few dozen SIREN is a few API calls). `maxResults` bounds the worst case.

# Actor input Schema

## `mode` (type: `string`):

<b>search</b> (default): returns everything published in a date range (the last N days, or dateFrom–dateTo), no state. <b>monitor</b>: returns only announcements not seen by this watch before (state kept in a named key-value store); schedule it daily.

## `watchName` (type: `string`):

Monitor mode only. Name of this watch. Each watch keeps its own state, so two watches never share their 'already seen' list. The state key is the watch name plus a hash of the filters: changing the filters starts a fresh watch.

## `sirens` (type: `array`):

Optional. The 9-digit SIREN of your customers or suppliers (spaces allowed, a 14-digit SIRET is shortened to its SIREN). Leave empty to watch everything matching the other filters.

## `departments` (type: `array`):

Optional. French département codes, e.g. 75, 2A, 971. Leave empty for all of France.

## `procedureTypes` (type: `array`):

Optional. Keep only these normalized categories. Leave empty for all.

## `initialDays` (type: `integer`):

Monitor mode only. On the very first run of a watch, return announcements published in the last N days.

## `dateFrom` (type: `string`):

Search mode only. First publication date (YYYY-MM-DD). Leave empty to use 'Last N days'.

## `dateTo` (type: `string`):

Search mode only. Last publication date (YYYY-MM-DD). Defaults to today.

## `lastDays` (type: `integer`):

Search mode only. Used when 'Publication date from' is empty: returns announcements published in the last N days (today included).

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

Hard cap on the number of rows returned by a run (cost control). In monitor mode, announcements beyond the cap are returned on the next run.

## `includeNaturalPersons` (type: `boolean`):

Default: true. Includes sole traders and other individuals (entrepreneurs individuels, personnes physiques) whose procedures are published in the BODACC. These rows contain a person's name, which is personal data: untick this box if you only follow companies.

## `stateStoreName` (type: `string`):

Advanced. Name of the named key-value store holding the monitor state. Named stores are kept until you delete them.

## Actor input object example

```json
{
  "mode": "search",
  "watchName": "default",
  "initialDays": 7,
  "lastDays": 7,
  "maxResults": 20,
  "includeNaturalPersons": true,
  "stateStoreName": "french-insolvency-monitor-state"
}
```

# Actor output Schema

## `results` (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 = {
    "lastDays": 7,
    "maxResults": 20
};

// Run the Actor and wait for it to finish
const run = await client.actor("tjasmin/french-insolvency-monitor").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 = {
    "lastDays": 7,
    "maxResults": 20,
}

# Run the Actor and wait for it to finish
run = client.actor("tjasmin/french-insolvency-monitor").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 '{
  "lastDays": 7,
  "maxResults": 20
}' |
apify call tjasmin/french-insolvency-monitor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,tjasmin/french-insolvency-monitor"
        }
    }
}
```

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/dIxgLhQeizI352z7V/builds/XMgYBkUTGdDx3qKCY/openapi.json
