{
  "openapi": "3.0.1",
  "info": {
    "title": "SIRET Company Scraper",
    "description": "Search French companies by name, SIREN or SIRET. Get official SIRENE data (status, NAF, address, directors) as flat rows, with monitor mode for changes. Pay per result.",
    "version": "0.1",
    "x-build-id": "jVX5e6w4j5FI4OYt1"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/redomic~siret-company-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-redomic-siret-company-scraper",
        "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/redomic~siret-company-scraper/runs": {
      "post": {
        "operationId": "runs-sync-redomic-siret-company-scraper",
        "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/redomic~siret-company-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-redomic-siret-company-scraper",
        "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 query",
            "type": "string",
            "description": "Company name, brand, address keyword, or a SIREN (9 digits) / SIRET (14 digits) to look up. You can also use 'queries' for multiple terms."
          },
          "queries": {
            "title": "Queries",
            "type": "array",
            "description": "Multiple search terms, SIREN or SIRET numbers to process in one run. Each gets its own status row.",
            "items": {
              "type": "string"
            },
            "default": []
          },
          "sirenOrSiret": {
            "title": "SIREN or SIRET list",
            "type": "array",
            "description": "Bulk list of SIREN (9 digits) or SIRET (14 digits) identifiers to fetch directly.",
            "items": {
              "type": "string"
            },
            "default": []
          },
          "mode": {
            "title": "Mode",
            "enum": [
              "search",
              "detail",
              "monitor"
            ],
            "type": "string",
            "description": "search/detail = return matching companies now. monitor = compare current results to the previous run for the same input and report new, changed and removed companies (state stored in a named key-value store). In monitor mode only changes are billed.",
            "default": "search"
          },
          "maxItems": {
            "title": "Max items per query",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Maximum company rows to return per query. The API caps pagination at 10,000 results per search; narrow filters to cover larger segments.",
            "default": 50
          },
          "department": {
            "title": "Department filter",
            "type": "string",
            "description": "Optional department code to filter results (e.g. 75, 13, 2A).",
            "default": ""
          },
          "postalCode": {
            "title": "Postal code filter",
            "type": "string",
            "description": "Optional postal code to filter results (e.g. 75013, 13008).",
            "default": ""
          },
          "commune": {
            "title": "Commune (INSEE code) filter",
            "type": "string",
            "description": "Optional INSEE commune code to filter results (e.g. 75113 for Paris 13e, 13055 for Marseille).",
            "default": ""
          },
          "region": {
            "title": "Region filter",
            "type": "string",
            "description": "Optional region code to filter results (e.g. 11 for Île-de-France).",
            "default": ""
          },
          "activityCode": {
            "title": "Activity code (NAF/APE)",
            "type": "string",
            "description": "Optional NAF activity code filter (e.g. 10.71C for boulangerie-pâtisserie).",
            "default": ""
          },
          "legalStatus": {
            "title": "Administrative status",
            "enum": [
              "",
              "A",
              "C"
            ],
            "type": "string",
            "description": "Filter by administrative status: A = active, C = ceased/closed.",
            "default": ""
          },
          "employeeRange": {
            "title": "Employee range (tranche effectif)",
            "type": "string",
            "description": "Optional employee range code as used by SIRENE (e.g. 00, 01, 02, 03, 11, 12, 21...).",
            "default": ""
          },
          "companyCategory": {
            "title": "Company category",
            "enum": [
              "",
              "PME",
              "ETI",
              "GE"
            ],
            "type": "string",
            "description": "Optional company size category: PME, ETI, GE.",
            "default": ""
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}