$5 free credits when you sign up Claim now
Marlin 2b now available Test it!
MiniMax H3 now available! Test it!
MiniMax Music 3 now available! Test it!
Browse all Models
Browse all
Browse all
Browse all

Web Content Extraction API Clean Page Text for LLMs

Send a list of URLs to the deAPI Contents API and get the main text of each page as JSON. PDF files work too. Ask for excerpts or a summary instead when your prompt has no room for whole pages.

$5 in free credits to start. No credit card required.

per page and content type, only for pages that load
$0.0012
full text, excerpts or a summary
3 types
in one call, each with its own status
20 URLs

Extract Text from a URL with One API Call

POST the URLs and the content you want. The response returns one result per URL, in the same order.

Request
curl -X POST 'https://api.deapi.ai/api/v2/web/contents' \
  -H 'Content-Type: application/json' \
  -H 'Authorization: Bearer YOUR_API_TOKEN' \
  -d '{
    "urls": [
      "https://example.com/blog/pricing-update",
      "https://example.com/whitepaper.pdf"
    ],
    "text": true
  }'
import requests

response = requests.post(
    "https://api.deapi.ai/api/v2/web/contents",
    headers={"Authorization": "Bearer YOUR_API_TOKEN"},
    json={
        "urls": [
            "https://example.com/blog/pricing-update",
            "https://example.com/whitepaper.pdf",
        ],
        "text": True,
    },
    timeout=60,
)

for page in response.json()["results"]:
    if page["status"] == "ok":
        print(page["title"], len(page["text"]))
const response = await fetch("https://api.deapi.ai/api/v2/web/contents", {
  method: "POST",
  headers: {
    "Authorization": "Bearer YOUR_API_TOKEN",
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    urls: [
      "https://example.com/blog/pricing-update",
      "https://example.com/whitepaper.pdf",
    ],
    text: true,
  }),
});

const { results } = await response.json();
results
  .filter((page) => page.status === "ok")
  .forEach((page) => console.log(page.title, page.text.length));
Response, shortened
{
  "request_id": "a41d97c3-…",
  "cost": 0.0012,
  "results": [
    {
      "url": "https://example.com/blog/pricing-update",
      "status": "ok",
      "title": "New plans from 1 November",
      "published_at": "2026-10-28T08:00:00+00:00",
      "text": "Starting 1 November, the Team plan
        costs $24 per seat per month…"
    },
    {
      "url": "https://example.com/whitepaper.pdf",
      "status": "not_found"
    }
  ]
}

Illustrative values. Only pages with status "ok" are charged.

Full Text, Excerpts or a Summary per Page

Content type What you get Use it for
text The main text of the page. Set max_length to cap it. RAG ingestion, long-context prompts, archiving
excerpts The passages most relevant to a query you pass Short prompts and quick answers with a quote
summary A short summary, steered by an optional query Price tracking, lead lists, page comparisons

Each content type costs $0.0012 per page, so text plus a summary for one page is $0.0024. Pages that fail to load are not charged.

Ask a Question, Get a Summary of the Answer

Pass a query with the summary and it focuses on what you asked. One call turns a pricing page into a list you can paste into a prompt or a spreadsheet.

Request
{
  "urls": ["https://example.com/pricing"],
  "summary": {
    "query": "List every plan with its monthly price."
  }
}
Summary field, shortened
"summary": "Summary:
- Starter: free, 1 project.
- Team: $24 per seat per month.
- Business: $59 per seat per month,
  with SSO and audit logs."

Illustrative values from an example pricing page. A summary takes a few seconds per page.

Batches, Statuses and Text Length

  • Up to 20 URLs per call

    Send a list and get one result per URL, in the same order. Larger lists go in several calls.

  • Status for every URL

    Each URL comes back as ok, not_found or unknown. One broken link does not fail the whole request.

  • Cap the text length

    Set max_length on the text to keep long pages within your prompt.

What Teams Build with a Content Extraction API

  • LLM input

    Feed pages to a model

    Give an agent or a RAG pipeline the text of the pages it found, without HTML parsing or a headless browser to run.

  • Extraction

    Pull facts from many pages

    Ask the same summary query across product, job or pricing pages with very different layouts and compare the answers.

  • Monitoring

    Watch competitor pages

    Fetch pricing and feature pages on a schedule and compare the summaries between runs.

Need the URLs first? The Search API finds pages for a query and can return their text in the same call.

Billing, Spend Limits and Errors

  • Pay per page that loads

    Pages with status not_found or unknown are free. A request that fails on our side is not charged, and the amount reserved against your key limit is released.

  • Spend limit per key

    Give each key a daily, weekly or monthly limit. Over the limit the API answers 402 and the request does not run.

  • Errors you can retry

    Busy or timed-out requests return 503 or 504 with a Retry-After header, so your code knows when to try again. Limits go up after the first payment.

  • $5 in free credits
  • No credit card required
  • Prepaid, no subscription

Turn Any URL into Text Your Model Can Read

$5 in credits after email verification, no card. The same key works for page content, search and every other deAPI endpoint.

See also Web Search API, YouTube Transcript API and Video Analysis API.

Frequently Asked Questions

Pages, formats and billing

Send the URL to the deAPI Contents API with text set to true. The response has the page title, publish date and main text as JSON. One request can carry up to 20 URLs.
$0.0012 per page for each content type you ask for: text, excerpts or a summary. Pages that do not load are free. Ask the price endpoint for a quote before you send a request.
Yes. Pass the link to a PDF like any other URL and you get its text back.
Yes, up to 20. Each one gets its own result and status, in the same order.
Yes. Set max_length on the text, or ask for excerpts or a summary instead of the whole page.
It returns the readable content of the pages you send, not raw HTML. It does not crawl a whole site: send the URLs you need, or get them from a Search API result.