LlamaIndex
FunctionTool wrappers for LlamaIndex agents: scrape, search, extract and enrich.
⚠️
Not on npm yet. @superscraper/llamaindex cannot be installed with npm install today.
Until it ships, wrap the REST API in your own FunctionTool. A POST /v1/scrape with the x-api-key header is all it needs.
Install
The package is not on npm yet. It is available on request: contact support@superscraper.dev. It expects llamaindex as a peer.
Scrape in 5 lines
import { createScrapeTool } from '@superscraper/llamaindex';
// Reads SUPERSCRAPER_API_KEY from the environment.
const scrape = await createScrapeTool();
const result = await scrape.call({ url: 'https://example.com' });
console.log(result); // clean markdown + listing + provenanceIn an agent
import { createAllTools } from '@superscraper/llamaindex';
import { ReActAgent, Anthropic } from 'llamaindex';
const tools = await createAllTools();
const agent = new ReActAgent({
tools,
llm: new Anthropic({ model: 'claude-sonnet-4-6' }),
});
const response = await agent.chat({
message: 'Find the top 5 coffee roasters in Portland OR with their contact info',
});Tools
| Factory | Tool name | Endpoint |
|---|---|---|
createScrapeTool() | superscraper_scrape | /v1/scrape |
createSearchTool() | superscraper_search | /v1/search |
createExtractTool() | superscraper_extract | /v1/extract |
createEnrichTool() | superscraper_enrich | /v1/enrich/website |
createAllTools() | all of the above |