-
Crawl4AI Cloud (
cloud.*, https://api.crawl4ai.com): the key is a Cloud API key (sk_live_..., crawl4ai.com → Get a free API key; 1,000 free credits a month). Runs cost credits (scrape 0.1 to a few, serp 1 a Google page, price 5 a site);cloud.tools.estimateprices a run first. Finding and reading tools is free. Every run answers{ tool, request_id, took_ms, usage: { credits }, rows?, data? }. -
Self-hosted server (
server.*): rundocker run -p 11235:11235 --shm-size=1g -e CRAWL4AI_API_TOKEN=<token> unclecode/crawl4aiand connect with that token as the key and the server’s address asserver_url(https, or http on localhost). Without a token the server only listens on its own loopback. An account with aserver_urlholds the server’s token, which never goes to the Cloud: use a second account forcloud.*. -
Site tools.
cloud.tools.list(search withq, orsourcefor one site) finds tested tools for 47 sites (Amazon, LinkedIn, YouTube, Google Maps, Zillow …);cloud.tools.getshows a tool’s inputs and columns;cloud.tools.runruns it. -
Jobs.
cloud.site,cloud.batchand job-type site tools returndata.job_id; follow it withcloud.jobs.getand read rows withcloud.jobs.results(500 a page,after= the lastseq+ 1). On the server,server.crawlJobs.createandserver.llmJobs.createqueue work read back with.get, or call awebhook_config.webhook_url. -
Files.
server.screenshotandserver.pdfreturn the PNG or PDF as a file;server.crawlStreamandcloud.jobs.resultsreturn their NDJSON lines as{ items }. -
Risk. Runs are metered reads (
read).cloud.watchandcloud.monitors.updatearewrite(each check costs credits), deleting a watch and cancelling a job aredestructive, as arecloud.billing.topup(charges the saved card) andcloud.billing.subscribe.server.executeJsiswrite(scripts can click and submit), killing a pool browser and resetting stats aredestructive. -
Webhooks. The server doesn’t sign job webhooks. Create jobs with
webhook_config.webhook_headers: { "X-Webhook-Secret": "<secret>" }and give the plugin the same secret aswebhookSecret; deliveries without it are refused.
- 66 typed API operations
- 1 incoming webhook event types
Setup
1
Install
2
Add the plugin
corsair.ts
multiTenancy: true, scope calls with corsair.withTenant(id). See Quick start for KEK + Hub keys, and Multi-tenancy for account isolation.3
Choose authentication
- API Key (Recommended)
Store the Crawl4AI API key before the first call: More: API Key
pnpm corsair setup --plugin=crawl4ai --tenant=acme api_key=<your-key> (leave out --tenant without multiTenancy), or pass it as key in the plugin options. With Hub, each tenant enters their own key on the connect page. See API key auth.4
Connect a tenant
Mint a connect link and send the tenant to it. Hub hosts the page and delivers the result to your app — see Connect / OAuth.
Example API calls
Scrape a page as MarkdownWebhooks
This plugin registers 1 webhook event type. Configure the provider to POST to your Corsair HTTP handler, then usewebhookHooks on the plugin factory.
See Webhooks for every event path and payload shape, and Webhooks concept for routing.
What’s next
API reference
Every
crawl4ai.api.* operation with input and output types.Webhooks
Event paths, payloads, and
webhookHooks examples.Connect / OAuth
createLink, Hub delivery, and tenant connect flows.
Use with agents
Expose this plugin’s operations as MCP tools.