Quickstart
Make your first Bitparse API call in under a minute.
Get structured data from a document in three steps.
1. Create an Account
Sign up at bitparse.ai and navigate to the Dashboard.
2. Get Your API Key
Open Settings > API Keys in the dashboard and click Create Key. Copy the key immediately — it is only shown once.
Your key starts with bp_ and is passed via the X-API-Key header on every request.
3. Parse a Document
Upload a PDF, PNG, or JPEG to the /parse endpoint.
curl -X POST https://api.bitparse.ai/parse \
-H "X-API-Key: bp_YOUR_API_KEY" \
-F "file=@report.pdf"import requests
resp = requests.post(
"https://api.bitparse.ai/parse",
headers={"X-API-Key": "bp_YOUR_API_KEY"},
files={"file": open("report.pdf", "rb")},
)
data = resp.json()
print(data["pages"][0]["text"])const fs = require("fs");
const FormData = require("form-data");
const form = new FormData();
form.append("file", fs.createReadStream("report.pdf"));
const resp = await fetch("https://api.bitparse.ai/parse", {
method: "POST",
headers: { "X-API-Key": "bp_YOUR_API_KEY" },
body: form,
});
const data = await resp.json();
console.log(data.pages[0].text);Example Response
The response is a JSON envelope containing enriched XML for each page.
{
"pages": [
{
"page_number": 1,
"text": "<title id=\"page1_elem0\">Quarterly Report</title>\n\n<text id=\"page1_elem1\">Revenue grew 18% year-over-year...</text>\n\n<table id=\"page1_elem2\">\n| Quarter | Revenue |\n|---------|---------|\n| Q1 | $4.2M |\n| Q2 | $4.9M |\n</table>",
"elements": [
{"id": "page1_elem0", "type": "title", "content": "Quarterly Report", "image_data": ""},
{"id": "page1_elem1", "type": "text", "content": "Revenue grew 18% year-over-year...", "image_data": ""},
{"id": "page1_elem2", "type": "table", "content": "| Quarter | Revenue |\n|---------|---------|\n| Q1 | $4.2M |\n| Q2 | $4.9M |", "image_data": ""}
]
}
],
"total_pages": 1,
"processing_time_ms": 1823,
"credits_used": 1,
"credits_remaining": 499
}Each page's text field contains enriched XML where every element — text, tables, equations, figures — is wrapped in a semantic tag with a unique ID. The elements array provides the same data in a structured list for programmatic access.
Next Steps
- Authentication — Learn how API keys work
- Parse Endpoint — Full endpoint reference