Lever Data API: Extract Structured JSON in 2026
Tutorials

Lever Data API: Extract Structured JSON in 2026

Learn how to build a robust data pipeline using a Lever data API to extract structured JSON job listings, including titles, locations, and salaries.

5 min read
10 views

AlterLab handles this automaticallyscrape any URL with one API call. No infrastructure required.

Try it free

TL;DR: To get structured Lever data via API, use the AlterLab Extract API to send a target URL and a JSON schema. The engine bypasses anti-bot protections and returns validated, typed JSON containing job titles, locations, and other public fields, eliminating the need for manual HTML parsing.

Disclaimer: This guide covers extracting publicly accessible data. Always review a site's robots.txt and Terms of Service before scraping.


Why use Lever data?

Engineering teams and data scientists often require real-time access to job market trends. Because Lever hosts career pages for thousands of high-growth companies, it serves as a primary source for several high-value use cases:

  • AI Training & RAG: Feed current job descriptions into Large Language Models to build specialized recruitment agents or career coaching tools.
  • Competitive Intelligence: Monitor hiring patterns in specific sectors (e.g., "Distributed Systems Engineers in Berlin") to track competitor growth.
  • Market Analytics: Aggregate salary ranges and location data to build macro-economic reports on the tech labor market.
Try it yourself

Extract structured jobs data from Lever

What data can you extract?

When building a Lever data API integration, you aren't just grabbing raw text. You are transforming unstructured HTML into a typed data object. Common fields extracted from public Lever pages include:

FieldTypeDescription
job_titleStringThe official title of the position.
companyStringThe name of the hiring organization.
locationStringPhysical office location or "Remote" status.
salaryStringCompensation ranges if publicly listed.
posted_dateStringWhen the job was first listed.
employment_typeStringFull-time, Contract, or Internship status.

The extraction approach: Why traditional methods fail

Historically, developers used BeautifulSoup or Cheerio to parse HTML. This approach is fragile for two reasons:

  1. DOM Volatility: If Lever changes a single <div> class name, your entire pipeline breaks.
  2. Anti-Bot Interception: Modern career pages utilize sophisticated fingerprinting and rate-limiting. Standard headless browsers often trigger CAPTCHAs or get blocked by Cloudflare.

A dedicated data API shifts the burden from "how do I find this element?" to "what data do I need?". Instead of writing selectors, you define a schema. The platform handles the proxy rotation, browser fingerprinting, and structural changes under the hood.

Quick start with AlterLab Extract API

To begin building your pipeline, you can follow our Getting started guide. The Extract API allows you to pass a URL and a JSON schema to receive structured data immediately.

Python Implementation

The following example demonstrates how to use the Python client to target a Lever job page.

Python
import alterlab

client = alterlab.Client("YOUR_API_KEY")

schema = {
  "type": "object",
  "properties": {
    "job_title": {
      "type": "string",
      "description": "The job title field"
    },
    "company": {
      "type": "string",
      "description": "The company field"
    },
    "location": {
      "type": "string",
      "description": "The location field"
    },
    "salary": {
      "type": "string",
      "description": "The salary field"
    },
    "posted_date": {
      "type": "string",
      "description": "The posted date field"
    },
    "employment_type": {
      "type": "string",
      "description": "The employment type field"
    }
  }
}

result = client.extract(
    url="https://jobs.lever.co/example-company",
    schema=schema,
)
print(result.data)

Expected JSON Output:

JSON
{
  "job_title": "Senior Staff Engineer",
  "company": "Example Corp",
  "location": "San Francisco, CA",
  "salary": "$180,000 - $240,000",
  "posted_date": "2026-01-15",
  "employment_type": "Full-time"
}

cURL Implementation

For shell scripts or lightweight microservices, use the REST endpoint. Refer to the Extract API docs for full parameter details.

Bash
curl -X POST https://api.alterlab.io/v1/extract \
  -H "X-API-Key: YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://jobs.lever.co/example-company",
    "schema": {
      "type": "object",
      "properties": {
        "job_title": {"type": "string"},
        "company": {"type": "string"},
        "location": {"type": "string"}
      }
    }
  }'

Define your schema

The power of the Extract API lies in its ability to validate output against your requirements. By providing a JSON schema, you ensure that your downstream database or AI agent receives predictable data types.

If you define salary as a string, you get "Competitive" or "$100k". If you define it as a number, the engine will attempt to normalize the value. This schema-first approach prevents "dirty data" from entering your production environment.

99.2%Extraction Accuracy
1.4sAvg Response Time
100%Typed JSON Output

Handle pagination and scale

When building a large-scale jobs data API, you rarely extract a single page. You are likely iterating through hundreds of company career portals.

Batching and Async Jobs

For high-volume tasks, do not use synchronous requests. Instead, utilize the asynchronous job pattern. This allows you to submit a list of URLs and poll for results, preventing your local execution from timing out.

Python
import alterlab

client = alterlab.Client("YOUR_API_KEY")

urls = [
    "https://jobs.lever.co/company-a",
    "https://jobs.lever.co/company-b",
    "https://jobs.lever.co/company-c"
]

# Submit jobs in bulk
job_ids = client.extract_batch(
    urls=urls,
    schema=my_job_schema
)

# Poll for completion
for jid in job_ids:
    result = client.get_job_status(jid)
    print(f"Job {jid} status: {result.status}")

Cost Management

Scaling your extraction pipeline requires monitoring your usage. AlterLab uses a transparent pricing model where you pay for what you use. You can estimate costs before running a large batch using the estimate_cost endpoint. For detailed information on how we handle high-volume requests, visit our AlterLab pricing page.

Key takeaways

  • Avoid brittle selectors: Use schema-based extraction to make your pipeline resilient to website redesigns.
  • Standardize your data: Leverage JSON schemas to ensure job_title and location are always returned in the correct format.
  • Scale efficiently: Use asynchronous batching for large-scale data collection to avoid timeouts and maximize throughput.
  • Automate the hard parts: Let the data API handle proxy rotation and anti-bot measures so you can focus on the data itself.

Hit reply if you have questions.

AlterLab // Web Data, Simplified.

Share

Was this article helpful?

Frequently Asked Questions

Lever provides official APIs for enterprise customers to manage their internal recruitment workflows. For extracting publicly available job listings for market research or analytics, the AlterLab Extract API provides a structured JSON alternative.
You can extract any publicly visible information from Lever career pages, such as job_title, company name, location, salary ranges, and posting dates. The output is returned as validated, typed JSON based on your provided schema.
AlterLab uses a pay-as-you-go model where you only pay for the extractions you run. Costs depend on the complexity of the extraction and whether you use a registered BYOK key to manage LLM orchestration fees.