# France Company Registry Search (Official SIREN/SIRET) (`leathered_luna/fr-company-registry-search`) Actor

Search the official French company register (Annuaire des Entreprises / SIRENE) by name, SIREN or SIRET. Company data only — no officers. No API key.

- **URL**: https://apify.com/leathered_luna/fr-company-registry-search.md
- **Developed by:** [SiennaWorks](https://apify.com/leathered_luna) (community)
- **Categories:** Lead generation
- **Features:** Limited permissions
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.50 / 1,000 companies found

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

## France Company Registry Search (Official SIREN / SIRET)

Search **French companies** by name, **SIREN** or **SIRET** against the official **Annuaire des Entreprises** (INSEE / SIRENE open data). No API key needed.

Built for KYB checks, supplier onboarding, lead lists and AI agents that must confirm a French legal entity before a contract or invoice.

### How this is different

- **Straight from the official register.** It calls [recherche-entreprises.api.gouv.fr](https://recherche-entreprises.api.gouv.fr/docs/), the French government's public search API — not a scraped page.
- **Company data only.** Officers (`dirigeants`) are never returned.
- **Partial-diffusion records are handled correctly.** If a unit has asked for *diffusion partielle* under article R123-232-1 of the French commercial code, the Actor returns the legal name and identifiers but **omits the address**, and sets `partial_diffusion: true`. Those addresses must not be reused for prospecting.
- **Local checksum first.** Malformed SIREN/SIRET numbers are rejected before the API is called, and are never charged.
- **Name or number.** 9-digit SIREN and 14-digit SIRET values (spaces allowed) are looked up exactly; anything else is a name search. You can optionally restrict name searches by postal code, department or NAF activity code.

### What you get

`query`, `status`, `siren`, `siret_head_office`, `name`, `legal_name`, `sigle`, `legal_form_code`, `activity_code_naf`, `activity_section`, `administrative_status` (`active` or `closed`), `created_on`, `closed_on`, `employee_band`, `company_category`, establishment counts, `partial_diffusion`, address fields (when publication is allowed), `source_url` (the official Annuaire page), `retrieved_at`, `error_message`.

An example is in [`examples/example_output.json`](examples/example_output.json).

### Input

```json
{
    "queries": ["Société Générale", "552120222"],
    "activeOnly": true,
    "postalCode": "",
    "department": "",
    "nafCode": "",
    "maxResultsPerQuery": 20
}
```

| Field | Meaning |
|---|---|
| `queries` | One company name, SIREN or SIRET per item. Duplicates are removed. |
| `activeOnly` | Default true. Omit closed companies. |
| `postalCode` | Optional 5-digit code, e.g. `75009`. |
| `department` | Optional department code, e.g. `75`. |
| `nafCode` | Optional NAF/APE code, e.g. `62.01Z`. |
| `maxResultsPerQuery` | 1–100, default 20. |

### Pricing (pay-per-event)

**$0.0025 per company found** ($2.50 per 1,000), charged only when a company record is returned. Not-found queries, malformed identifiers and registry outages are returned free. Platform usage is included. Set a **maximum cost per run** in Apify Console for a hard cap. The Actor stops cleanly when the limit is reached.

### Reliability behaviour

| Situation | Behaviour |
|---|---|
| Malformed SIREN/SIRET | `invalid_format`, not sent to the register, not charged. |
| No match | `not_found`, not charged. |
| Registry busy or down | Automatic retries with backoff, then `service_unavailable`, not charged. |
| Partial diffusion | Company identifiers and name are returned; address fields are empty; `partial_diffusion` is `true`. |
| One bad query | Never fails the run. Other queries continue. |

### Legal and notes

- Source: the official [Annuaire des Entreprises](https://annuaire-entreprises.data.gouv.fr/) / [recherche-entreprises API](https://recherche-entreprises.api.gouv.fr/docs/), which publishes INSEE SIRENE open data. A result confirms what the register currently publishes. It is not a full due-diligence check.
- Personal data of officers is not included. You are responsible for handling any remaining personal data (for example a sole trader's published address) in line with GDPR.
- Units with **diffusion partielle** must not have their personal information redistributed in full or used for prospecting (article R123-232-1 of the code de commerce).
- Not affiliated with or endorsed by INSEE, DINUM or the French State.

### Local development

```bash
python -m venv .venv
source .venv/bin/activate
pip install -r requirements-dev.txt
pytest -q
```

### Changelog

- **0.1** — First version: name and SIREN/SIRET search, checksum pre-check, officer fields removed, partial-diffusion address handling, pay-per-event.

# Actor input Schema

## `queries` (type: `array`):

One query per item. A 9-digit SIREN or 14-digit SIRET (spaces allowed) is looked up exactly. Anything else is treated as a name search. Numbers that fail the official checksum are not sent to the register and are not charged.

## `activeOnly` (type: `boolean`):

If on, closed companies are omitted (etat_administratif = A).

## `postalCode` (type: `string`):

Optional. Restrict name searches to a 5-digit French postal code, e.g. 75009.

## `department` (type: `string`):

Optional. Restrict name searches to a department, e.g. 75 for Paris, 13 for Bouches-du-Rhône.

## `nafCode` (type: `string`):

Optional. Restrict name searches to a NAF code, e.g. 62.01Z.

## `maxResultsPerQuery` (type: `integer`):

Cap on companies returned for each name search (1–100). Exact SIREN/SIRET lookups usually return one row.

## Actor input object example

```json
{
  "queries": [
    "Société Générale",
    "552120222"
  ],
  "activeOnly": true,
  "maxResultsPerQuery": 20
}
```

# 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 = {
    "queries": [
        "Société Générale",
        "552120222"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("leathered_luna/fr-company-registry-search").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 = { "queries": [
        "Société Générale",
        "552120222",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("leathered_luna/fr-company-registry-search").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 '{
  "queries": [
    "Société Générale",
    "552120222"
  ]
}' |
apify call leathered_luna/fr-company-registry-search --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,leathered_luna/fr-company-registry-search"
        }
    }
}
```

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/6cMgxzdeA7HyNpnMU/builds/WXxUzCYPFUo39oX7i/openapi.json
