{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/orbisearch-com/json-schema/orbisearch-com-company-bulk-status-response-schema.json",
  "title": "CompanyBulkStatusResponse",
  "description": "Status snapshot of a bulk company-enrichment job.",
  "x-generated": "2026-11-22",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/orbisearch-com-openapi.json#/components/schemas/CompanyBulkStatusResponse",
  "properties": {
    "job_id": {
      "type": "string",
      "format": "uuid",
      "title": "Job Id",
      "description": "Unique job identifier."
    },
    "status": {
      "type": "string",
      "enum": [
        "running",
        "completed"
      ],
      "title": "Status",
      "description": "Job status: running (still processing) or completed (all rows done)."
    },
    "total_rows": {
      "type": "integer",
      "title": "Total Rows",
      "description": "Total input rows submitted (repeats included; unique companies are what was charged)."
    },
    "total_processed": {
      "type": "integer",
      "title": "Total Processed",
      "description": "Input rows answered so far."
    },
    "credits_consumed": {
      "type": "number",
      "title": "Credits Consumed",
      "description": "Credits deducted for this job: 1 credit per distinct input, charged once at submit and never refunded after acceptance. Failed rows stay charged; invalid rows were never charged."
    },
    "summary": {
      "$ref": "#/$defs/CompanyBulkSummary",
      "description": "Per-outcome counts."
    },
    "created_at": {
      "type": "string",
      "title": "Created At",
      "description": "Job submission timestamp (UTC)."
    },
    "finished_at": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Finished At",
      "description": "Timestamp of the last processed row (UTC). Null while running."
    }
  },
  "type": "object",
  "required": [
    "job_id",
    "status",
    "total_rows",
    "total_processed",
    "credits_consumed",
    "summary",
    "created_at"
  ],
  "$defs": {
    "CompanyBulkSummary": {
      "properties": {
        "total_found": {
          "type": "integer",
          "title": "Total Found",
          "description": "Input rows where a company record was returned (repeats included)."
        },
        "total_not_found": {
          "type": "integer",
          "title": "Total Not Found",
          "description": "Input rows that were read (a company URL or a website domain) but no company matches them (repeats included)."
        },
        "total_error": {
          "type": "integer",
          "title": "Total Error",
          "description": "Input rows our infrastructure could not answer (repeats included)."
        },
        "total_invalid_url": {
          "type": "integer",
          "title": "Total Invalid Url",
          "description": "Input rows skipped at submit (a numeric-ID or malformed URL, a name over 200 characters, a domain cell that is not a website domain, or a blank row), repeats included. Counted as processed and charged nothing."
        }
      },
      "type": "object",
      "required": [
        "total_found",
        "total_not_found",
        "total_error",
        "total_invalid_url"
      ],
      "title": "CompanyBulkSummary",
      "description": "Per-outcome counts for a bulk company-enrichment job."
    }
  }
}