{
  "openapi": "3.0.1",
  "info": {
    "title": "Excel to JSON - XLSX, XLS & CSV Spreadsheet to JSON Converter",
    "description": "Read Excel file data from a public URL or base64 content and convert Excel to JSON. Convert CSV to JSON too; extract XLSX sheet names, column headers and rows for ETL.",
    "version": "0.8",
    "x-build-id": "JWQ958hlKczRH7B1R"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/gochujang~excel-extractor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-gochujang-excel-extractor",
        "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/gochujang~excel-extractor/runs": {
      "post": {
        "operationId": "runs-sync-gochujang-excel-extractor",
        "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/gochujang~excel-extractor/run-sync": {
      "post": {
        "operationId": "run-sync-gochujang-excel-extractor",
        "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": {
          "fileUrl": {
            "title": "File URL",
            "type": "string",
            "description": "Public direct URL to read Excel file data (XLSX/XLS) or convert CSV to JSON; for a small test use https://raw.githubusercontent.com/plotly/datasets/master/2014_usa_states.csv. The link must return the file itself, not a web page; Google Drive and Dropbox share links are converted automatically."
          },
          "fileUrls": {
            "title": "File URLs (bulk)",
            "type": "array",
            "description": "Up to 100 public XLSX, XLS or CSV URLs per run, processed one by one. A file that fails to download or parse returns one error item (success: false) and is not charged. Combined with fileUrl when both are set.",
            "items": {
              "type": "string"
            }
          },
          "fileBase64": {
            "title": "File (base64)",
            "type": "string",
            "description": "Base64-encoded Excel or CSV file content instead of fileUrl for Excel to JSON or CSV to JSON; for example, encode a local .csv file and set fileName to sample.csv."
          },
          "fileName": {
            "title": "File name",
            "type": "string",
            "description": "Optional filename for format detection, such as report.xlsx or sample.csv. Derived from fileUrl when omitted."
          },
          "includeHeaders": {
            "title": "First row is headers",
            "type": "boolean",
            "description": "Treat the first row as column names and return object rows; for example, Rank,State,Postal,Population becomes four keys. Default: true.",
            "default": true
          },
          "csvDelimiter": {
            "title": "CSV delimiter",
            "enum": [
              "auto",
              "comma",
              "semicolon",
              "tab",
              "pipe"
            ],
            "type": "string",
            "description": "Column separator for CSV/TSV files. auto (default) detects comma, semicolon, tab or pipe from the first 64 KB and falls back to comma (.csv) or tab (.tsv). Set it explicitly when a file is detected wrong, for example semicolon for European Excel exports.",
            "default": "auto"
          },
          "typedCsv": {
            "title": "Typed CSV values",
            "type": "boolean",
            "description": "Convert CSV cells to JSON types: 12 and -3.5 become numbers (1234,5 with a semicolon delimiter too), true/false become booleans, blanks become null, and cells matching dateFormat become ISO 8601 dates. Leading-zero codes such as 00123, digit runs longer than 15 and +49... numbers stay strings. When omitted via API, every CSV cell stays text as before; Excel cells are always typed."
          },
          "dateFormat": {
            "title": "CSV date format (strptime)",
            "type": "string",
            "description": "Optional Python strptime pattern for CSV date cells when typedCsv is on, for example %d/%m/%Y or %m/%d/%Y %H:%M. Matching cells become ISO 8601 (2024-03-05 or 2024-03-05T14:30:00); non-matching cells stay strings. ISO dates in the file pass through unchanged."
          },
          "sheetNames": {
            "title": "Sheets (name or 0-based index)",
            "type": "array",
            "description": "Excel sheets to extract, by name or 0-based index, for example [\"Prices\"] or [\"0\", \"2\"]. An exact name match wins over an index. Leave empty to extract every sheet; CSV input is one sheet named Sheet1.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "maxRowsPerSheet": {
            "title": "Max rows per sheet",
            "minimum": 1,
            "maximum": 500000,
            "type": "integer",
            "description": "Maximum data rows to extract from each sheet. Default: 10000. Agent (MCP) runs left at 10000 return 1000 rows per sheet and mark the sheet_summary item truncated; set another value to override.",
            "default": 10000
          },
          "flatMode": {
            "title": "Flat mode (legacy)",
            "type": "boolean",
            "description": "Legacy switch used only when outputMode is not set: true = one record per row, false = one record per sheet. Prefer outputMode.",
            "default": false
          },
          "maxFileSizeMb": {
            "title": "Max file size (MB)",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Skip any file larger than this, checked from Content-Length and while downloading, before parsing. The skipped file returns an error item and is not charged. Default: 50.",
            "default": 50
          },
          "outputMode": {
            "title": "Output mode",
            "enum": [
              "rows",
              "workbook"
            ],
            "type": "string",
            "description": "Agents: use rows. rows: one dataset item per spreadsheet row with file_url, file_name, sheet and row_number. workbook: one item per sheet with a rows array (best for small sheets). When omitted, agent (MCP) runs get rows; other API runs follow flatMode (false = workbook)."
          },
          "exportFormats": {
            "title": "Export files (Excel to CSV, Markdown)",
            "type": "array",
            "description": "Also save each sheet as a file in the run's key-value store, named <file_stem>__<sheet>.<ext>: csv (Excel to CSV, one file per sheet), jsonl, xlsx or markdown (an LLM-ready table). One extra dataset item per input file lists each file's key, URL and row count. No extra charge. Leave empty for dataset rows only.",
            "items": {
              "type": "string",
              "enum": [
                "csv",
                "jsonl",
                "xlsx",
                "markdown"
              ],
              "enumTitles": [
                "CSV",
                "JSON Lines",
                "XLSX",
                "Markdown table"
              ]
            },
            "default": []
          },
          "csvFormulaSafe": {
            "title": "Formula-safe CSV",
            "type": "boolean",
            "description": "Prefix ' on CSV text cells that start with =, +, -, @, tab or carriage return (plain numbers like -5 are kept), so a spreadsheet never runs them as formulas. Default: true.",
            "default": true
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}