{
  "openapi": "3.0.1",
  "info": {
    "title": "French Companies Search - SIREN, SIRET & NAF B2B Leads",
    "description": "Find French companies by NAF code, postal code or département. Get SIREN, SIRET, address, headcount and activity from the official Insee Sirene database.",
    "version": "0.0",
    "x-build-id": "gBTVcmUlV7jpb8XHa"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/frscrape~french-companies-search/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-frscrape-french-companies-search",
        "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/frscrape~french-companies-search/runs": {
      "post": {
        "operationId": "runs-sync-frscrape-french-companies-search",
        "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/frscrape~french-companies-search/run-sync": {
      "post": {
        "operationId": "run-sync-frscrape-french-companies-search",
        "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": [
          "codesNaf"
        ],
        "properties": {
          "codesNaf": {
            "title": "Codes NAF",
            "type": "array",
            "description": "Un ou plusieurs codes d’activité. Ancien code NAF rév. 2 (ex. 10.71C, boulangerie et boulangerie-pâtisserie) ou nouveau code NAF 2025 (ex. 10.71H) : le robot reconnaît le type tout seul. Listes Insee : https://www.insee.fr/fr/information/2406147 (NAF rév. 2) et https://www.insee.fr/fr/information/8617910 (NAF 2025).",
            "items": {
              "type": "string"
            }
          },
          "codesPostaux": {
            "title": "Codes postaux",
            "type": "array",
            "description": "Un ou plusieurs codes postaux à 5 chiffres, par exemple 69001. Laissez vide si vous utilisez le département. Ne remplissez pas les deux.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "departement": {
            "title": "Département",
            "type": "string",
            "description": "Un code de département, par exemple 69, 2A ou 974. Laissez vide si vous utilisez les codes postaux. Si les deux sont vides, la recherche couvre toute la France."
          },
          "tranchesEffectif": {
            "title": "Tranches d’effectif salarié (optionnel)",
            "type": "array",
            "description": "Ne garder que les entreprises de ces tailles. Laissez vide pour toutes les tailles.",
            "items": {
              "type": "string",
              "enum": [
                "NN",
                "00",
                "01",
                "02",
                "03",
                "11",
                "12",
                "21",
                "22",
                "31",
                "32",
                "41",
                "42",
                "51",
                "52",
                "53"
              ],
              "enumTitles": [
                "Unité non employeuse",
                "0 salarié",
                "1 ou 2 salariés",
                "3 à 5 salariés",
                "6 à 9 salariés",
                "10 à 19 salariés",
                "20 à 49 salariés",
                "50 à 99 salariés",
                "100 à 199 salariés",
                "200 à 249 salariés",
                "250 à 499 salariés",
                "500 à 999 salariés",
                "1 000 à 1 999 salariés",
                "2 000 à 4 999 salariés",
                "5 000 à 9 999 salariés",
                "10 000 salariés et plus"
              ]
            },
            "default": []
          },
          "uniquementActives": {
            "title": "Uniquement les entreprises actives",
            "type": "boolean",
            "description": "Si coché, les entreprises cessées sont exclues.",
            "default": true
          },
          "siegeDansLaZone": {
            "title": "Siège dans la zone",
            "type": "boolean",
            "description": "Si coché, ne garde que les entreprises dont le siège est dans la zone. Si décoché, inclut aussi celles qui y ont seulement un établissement (par exemple une chaîne de boulangeries dont le siège est ailleurs).",
            "default": true
          },
          "maxResultats": {
            "title": "Nombre maximum de résultats",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Le lancement s’arrête dès que ce nombre d’entreprises est atteint (au plus 10 000, limite de l’API).",
            "default": 100
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}