This skill uses XCrawl Map API to discover URLs for a site.
Default behavior is raw passthrough: return upstream API response bodies as-is.
Before using this skill, the user must create a local config file and write XCRAWL_API_KEY into it.
Path: ~/.xcrawl/config.json
{
"XCRAWL_API_KEY": "<your_api_key>"
}
Read API key from local config file only. Do not require global environment variables.
Using XCrawl APIs consumes credits.
If the user does not have an account or available credits, guide them to register at https://dash.xcrawl.com/.
After registration, they can activate the free 1000 credits plan before running requests.
Request runtime permissions for curl and node only.
Do not request Python, shell helper scripts, or other runtime permissions.
POST /v1/maphttps://run.xcrawl.comAuthorization: Bearer API_KEY="$(node -e "const fs=require('fs');const p=process.env.HOME+'/.xcrawl/config.json';const k=JSON.parse(fs.readFileSync(p,'utf8')).XCRAWL_API_KEY||'';process.stdout.write(k)")"
curl -sS -X POST "https://run.xcrawl.com/v1/map" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${API_KEY}" \
-d '{"url":"https://example.com","filter":"/docs/.*","limit":2000,"include_subdomains":true,"ignore_query_parameters":false}'
node -e '
const fs=require("fs");
const apiKey=JSON.parse(fs.readFileSync(process.env.HOME+"/.xcrawl/config.json","utf8")).XCRAWL_API_KEY;
const body={url:"https://example.com",filter:"/docs/.*",limit:3000,include_subdomains:true,ignore_query_parameters:false};
fetch("https://run.xcrawl.com/v1/map",{
method:"POST",
headers:{"Content-Type":"application/json",Authorization:`Bearer ${apiKey}`},
body:JSON.stringify(body)
}).then(async r=>{console.log(await r.text());});
'
POST https://run.xcrawl.com/v1/mapContent-Type: application/jsonAuthorization: Bearer | Field | Type | Required | Default | Description |
|---|---|---|---|---|
| --- | --- | ---: | --- | --- |
url | string | Yes | - | Site entry URL |
filter | string | No | - | Regex filter for URLs |
limit | integer | No | 5000 | Max URLs (up to 100000) |
include_subdomains | boolean | No | true | Include subdomains |
ignore_query_parameters | boolean | No | true | Ignore URLs with query parameters |
| Field | Type | Description |
|---|---|---|
| --- | --- | --- |
map_id | string | Task ID |
endpoint | string | Always map |
version | string | Version |
status | string | completed |
url | string | Entry URL |
data | object | URL list data |
started_at | string | Start time (ISO 8601) |
ended_at | string | End time (ISO 8601) |
total_credits_used | integer | Total credits used |
data fields:
links: URL listtotal_links: URL countcredits_used: credits usedcredits_detail: credit breakdownPOST /v1/map.Return:
POST /v1/map)request_payload used for the requestDo not generate summaries unless the user explicitly requests a summary.
limit is reached.共 1 个版本