Tools

DOCX to JSON API

Submit any Word document. Get back text content as searchable chunks, metadata, author, title, and a thumbnail as structured JSON.

Try it below:

FILEDrop a file or click to upload

Production-ready

Private by design

Security-first

Scalable

Production-ready

Private by design

Security-first

Scalable

Production-ready

Private by design

Security-first

Scalable

Turn Word documents into structured JSON

Upload a DOCX file or submit a URL, get structured JSON back.

{
  "kind": "document",
  "name": "Sarah Chen — CV",
  "state": "completed",
  "extraction": {
    "common": {
      "mimeType": "application/pdf",
      "size": 156672,
      "thumbnail": "https://cdn.exabase.io/...",
      "chunkCount": 14
    },
    "document": {
      "pages": 2,
      "author": "Sarah Chen",
      "title": "Sarah Chen — CV",
      "creationDate": "2025-04-12T00:00:00.000Z",
      "pdfRender": { "url": "https://cdn.exabase.io/..." },
      "documentType": "resume",
      "structured": {
        "name": "Sarah Chen",
        "email": "sarah.chen@example.com",
        "phone": "+1 (415) 555-0182",
        "summary": "Full-stack engineer with 6 years of experience building data pipelines and developer tools. Previously at Stripe and Vercel.",
        "experience": [
          {
            "company": "Vercel",
            "title": "Senior Software Engineer",
            "startDate": "2022-03",
            "endDate": "2025-04",
            "description": "Led development of the edge middleware runtime. Reduced cold start latency by 40%."
          },
          {
            "company": "Stripe",
            "title": "Software Engineer",
            "startDate": "2019-06",
            "endDate": "2022-02",
            "description": "Built internal tools for payment reconciliation. Processed $2B+ in daily transaction volume."
          }
        ],
        "education": [
          {
            "institution": "UC Berkeley",
            "degree": "B.S. Computer Science",
            "graduationDate": "2019"
          }
        ],
        "skills": ["TypeScript", "Python", "PostgreSQL", "AWS", "Kubernetes", "React", "Node.js"]
      }
    }
  }
}

What is Exabase's DOCX to JSON API?

Submit a DOCX file to the Exabase Extract API and get structured JSON back. The response includes the document title, author, page count, creation date, MIME type, file size, a CDN-hosted thumbnail, a rendered PDF version, and the full text content split into searchable chunks. The API handles the parsing. No python-docx, no mammoth.js, no LibreOffice on your end.

This is the same POST /v2/extract endpoint used for all content types. When the API recognises a Word document, it extracts the text, generates a rendered version, and returns structured output. For Word documents containing invoices, contracts, or resumes, the API also detects the document type and populates extraction.document.structured with type-specific fields, just as it does for PDFs.

What you get back

The response includes the document metadata (title, author, page count, creation date), a CDN-hosted thumbnail, a rendered PDF version, and the full text as searchable chunks. Each chunk has a sequence number, the extracted text, and a page number. For recognised document types, structured fields appear alongside the metadata. The API reference has the complete response schema.

One multi-modal API

The same POST /v2/extract endpoint handles every content type Exabase supports. For DOCX files, it returns text chunks with page numbers and document metadata. For PDFs, it does the same with structured field extraction for recognised types. For EPUBs, it returns book metadata and text chunks. For audio and video, it generates transcripts with timestamps. For images, it runs OCR. For web pages, it renders JavaScript and extracts the content.

The submission flow is identical across all types: one endpoint, one SDK method, one webhook configuration. You learn the pattern once and use it for everything. The Extract docs cover each content type in detail.

What you can build with it

The structured chunks are the same format used across the Exabase platform. Feed them into a RAG pipeline so your agent can reference and cite specific passages. Build a document management system where uploaded Word files are parsed and indexed automatically. Process internal reports, proposals, and memos and make them searchable across your organisation.

Store extracted documents as Resources in a Base and the content becomes searchable through Deep Search at the paragraph level. Workers can process new uploads on a schedule, keeping your knowledge base current without manual work.

Beyond extraction

The Extract API returns more than text chunks. You get a CDN-hosted thumbnail, a rendered PDF version, and standard document metadata. Store the output as a Resource and it's searchable through Deep Search immediately. Extract key details into Memory so your agent retains what it read between sessions.

How do I use it?

  1. Get your API key

Free, no credit card:

Sign up at exabase.io and copy your API key from the dashboard.

  1. Submit a Word document

Using the SDK (Node.js):

import { Exabase } from "@exabase/sdk";
import { createReadStream } from "fs";

const api = new Exabase({
  apiKey: process.env.EXABASE_API_KEY,
});

const job = await api.extract.createFromFile({
  file: createReadStream("./project-proposal.docx"),
  name: "Project Proposal — Q3 2026",
});

console.log(job.id);    // extraction job id
console.log(job.state); // "pending"
  1. Get the result

Poll the job until state reaches completed, or skip polling entirely with webhooks.

const result = await api.extract.get({ jobId: job.id });

if (result.state === "completed") {
  console.log(result.extraction?.document?.title);
  console.log(result.extraction?.document?.author);
  console.log(result.extraction?.document?.pages);
  console.log(result.extraction?.common?.chunkCount);
  console.log(result.extraction?.common?.thumbnail);
}

One API call. No python-docx, no mammoth.js, no LibreOffice.

What you get back

Field

Type

Description

state

string

completed or failed

kind

string

document

[...].mimeType

string

application/vnd.openxmlformats-officedocument.wordprocessingml.document

[...].size

number

File size in bytes

[...].thumbnail

string

CDN-hosted thumbnail URL

[...].chunkCount

number

Number of text chunks

[...].pages

number

Page count

[...].author

string

Document author

[...].title

string

Document title

[...].creationDate

string

Document creation date

[...].pdfRender.url

string

CDN-hosted rendered PDF URL

Text chunks are retrieved separately via GET /v2/extract/{jobId}/chunks.

Each chunk includes a sequence number, the extracted text, and a page number.

API quick reference

Endpoint

Method

Description

/v2/extract

POST

Submit extraction job

/v2/extract

GET

List extraction jobs

/v2/extract/{jobId}

GET

Poll for result

/v2/extract/{jobId}/chunks

GET

Fetch text chunks

/v2/extract-settings

PUT

Configure webhook

Auth: X-Api-Key header on all requests.

File retention: Stored files are retained for 1 day from job creation. Download or copy anything you need before they expire.

Need file extraction or full page content?

Exabase offers a full set of tools to extract content from any media, document or website.

All your data extraction needs in one place.

Why Exabase

Use cases

FAQs

What is Exabase?

Exabase is infrastructure for AI agents. It gives your agents memory, versioned file storage, AI deep search, and context automation through a set of APIs. Store what your agent learns, search inside any content type, and keep knowledge bases current automatically. Built for production use. Give your agent precise context and cut your token spend by up to 81%.

Who uses Exabase?

Developers and teams building AI agents, copilots, and RAG applications. If your agent needs to remember things between sessions, store and retrieve files, search across documents and media, or stay up to date without manual maintenance, Exabase handles that infrastructure so you can focus on your product.

Does it handle .doc files (old Word format)?

The API is optimised for .docx (Office Open XML). Older .doc files (binary format) may be supported but .docx is recommended for best results.

Does it extract tables and images from the document?

The API extracts text content, including text from tables. Embedded images are not extracted as separate files, but the rendered PDF preserves the full visual layout.

Does it detect document types (invoices, contracts, resumes)?

Yes. If the Word document contains an invoice, contract, or resume, the API detects the type and populates extraction.document.structured with type-specific fields, just as it does for PDFs.

Can I submit a URL instead of uploading a file?

Yes. Pass a url field in the request body pointing to a publicly accessible DOCX file.

Do I have to poll for results?

No. You can configure a webhook URL and Exabase will POST the full result to your server when processing completes. The webhooks guide covers setup.

What happens if extraction fails?

The job state moves to failed. Call the reprocess endpoint to retry without re-uploading.

How long are files retained?

Stored files are retained for 1 day from job creation, then permanently deleted. Download or copy anything you need before the retention window expires.

Is there an SDK?

Yes. The @exabase/sdk package for Node.js/TypeScript handles file streaming, job polling, and chunk retrieval. Install with npm install @exabase/sdk. Or call the REST API directly from any language.

What other file types does Extract recognise?

PDFs, EPUBs, PPTX, images (with OCR), audio (with transcription), video (with transcription), and web pages. The same POST /v2/extract endpoint handles all of them.

Deciding?

Ask your favourite AI about Exabase:

Cut your token spend and give your agent precise context.

Get started in minutes.

Cut your token spend and give your agent precise context.

Get started in minutes.