{
  "openapi": "3.0.1",
  "info": {
    "title": "French Company Search (SIREN, Sirene)",
    "description": "Search French companies in the government's open register API: by name, SIREN/SIRET, NAF activity code, postal code, department, legal form, employee range or around a point. One clean row per company with SIREN, legal form, NAF, headquarters address and coordinates, VAT. No API key.",
    "version": "0.1",
    "x-build-id": "r9PfGSn5u3bmF4589"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/darikami~french-company-search/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-darikami-french-company-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/darikami~french-company-search/runs": {
      "post": {
        "operationId": "runs-sync-darikami-french-company-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/darikami~french-company-search/run-sync": {
      "post": {
        "operationId": "run-sync-darikami-french-company-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",
        "properties": {
          "query": {
            "title": "Search text, SIREN or SIRET",
            "type": "string",
            "description": "Words of the company name, trade name or address (\"boulangerie paris 11\"), or a SIREN (9 digits) or SIRET (14 digits). Only the company's own name and address count: a company that matches only through a person (a manager) is not returned. Leave empty to search by filters only."
          },
          "activityCodes": {
            "title": "Activity codes (NAF rev. 2)",
            "type": "array",
            "description": "NAF/APE codes of the main activity, such as 62.01Z (computer programming) or 56.10A. 6201Z is also accepted. Up to 50.",
            "items": {
              "type": "string"
            }
          },
          "postalCodes": {
            "title": "Postal codes",
            "type": "array",
            "description": "5-digit French postal codes. A company matches when one of its establishments is there. Up to 100.",
            "items": {
              "type": "string"
            }
          },
          "departments": {
            "title": "Departments",
            "type": "array",
            "description": "Department codes: 01-95, 2A, 2B, 971-974, 976. A company matches when one of its establishments is there.",
            "items": {
              "type": "string"
            }
          },
          "legalForms": {
            "title": "Legal forms (INSEE codes)",
            "type": "array",
            "description": "4-digit INSEE legal category codes, such as 5710 (SAS), 5499 (SARL), 5599 (SA). Sole traders (1000) are never returned.",
            "items": {
              "type": "string"
            }
          },
          "employeeRanges": {
            "title": "Employee ranges",
            "type": "array",
            "description": "INSEE employee ranges (tranches d'effectifs) of the company.",
            "items": {
              "type": "string",
              "enum": [
                "11",
                "12",
                "21",
                "22",
                "31",
                "32",
                "41",
                "42",
                "51",
                "52",
                "53",
                "NN",
                "00",
                "01",
                "02",
                "03"
              ],
              "enumTitles": [
                "10-19 employees",
                "20-49 employees",
                "50-99 employees",
                "100-199 employees",
                "200-249 employees",
                "250-499 employees",
                "500-999 employees",
                "1,000-1,999 employees",
                "2,000-4,999 employees",
                "5,000-9,999 employees",
                "10,000 employees or more",
                "Non-employer unit (no employees in the reference year)",
                "0 employees (employees during the year, none at 31 December)",
                "1-2 employees",
                "3-5 employees",
                "6-9 employees"
              ]
            }
          },
          "categories": {
            "title": "Company size category",
            "type": "array",
            "description": "INSEE category: PME (small and medium), ETI (intermediate), GE (large).",
            "items": {
              "type": "string",
              "enum": [
                "PME",
                "ETI",
                "GE"
              ],
              "enumTitles": [
                "PME - small and medium-sized",
                "ETI - intermediate-sized",
                "GE - large"
              ]
            }
          },
          "activeOnly": {
            "title": "Active companies only",
            "type": "boolean",
            "description": "On: ceased companies are left out. Around a point, a company also needs an open establishment in the radius.",
            "default": true
          },
          "near": {
            "title": "Around a point",
            "type": "object",
            "description": "Companies with an establishment near a point: { \"lat\": 48.8566, \"lon\": 2.3522, \"radiusKm\": 1 }. The radius is 0.001-50 km (default 5). Combines only with activity codes and \"Active companies only\"."
          },
          "maxPages": {
            "title": "Maximum pages",
            "minimum": 1,
            "maximum": 400,
            "type": "integer",
            "description": "25 companies a page. The API returns at most 10,000 results (400 pages).",
            "default": 4
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}