Home/Tools/@tpmjs/registry-search

registrySearchTool

@tpmjs/registry-search

Search the TPMJS tool registry to find AI SDK tools. Returns tool metadata including toolId for use with registryExecuteTool.

Official
api-integration
v0.1.5
MIT

Interactive Playground

Test @tpmjs/registry-search (registrySearchTool) with AI-powered execution

0/2000 characters

Installation & Usage

Install this tool and use it with the AI SDK

1. Install the package

npm install @tpmjs/registry-search
pnpm add @tpmjs/registry-search
yarn add @tpmjs/registry-search
bun add @tpmjs/registry-search
deno add npm:@tpmjs/registry-search

2. Import the tool

import { registrySearchTool } from '@tpmjs/registry-search';

3. Use with AI SDK

import { generateText } from 'ai';
import { openai } from '@ai-sdk/openai';
import { registrySearchTool } from '@tpmjs/registry-search';

const result = await generateText({
  model: openai('gpt-4o'),
  tools: { registrySearchTool },
  prompt: 'Your prompt here...',
});

console.log(result.text);

AI Agent Integration

How AI agents can use this tool

Use Case

Use when you need to find a tool for a specific task. Search returns toolIds that can be executed with registryExecuteTool.

Examples

  • Search for 'web scraping' to find scraping tools
  • Search for 'weather' to find weather API tools
  • Search for 'database' to find database tools

Signature

(query: string, limit?: number) => Promise<unknown>

Tags

ai-sdk
api-integration
find
including
metadata
registry
registryexecutetool
sdk
search
toolid
tpmjs
vercel-ai

Parameters

Available configuration options

Auto-extracted
query
Required
Type: string

Search query (keywords, tool names, descriptions)

category
Optional
Type: string

Filter by category (optional)

limit
Optional
Type: number

Maximum results (1-20, default 5)

Schema extracted: 3/1/2026, 4:25:46 AM

README

@tpmjs/registry-search

Search the TPMJS tool registry from any AI SDK agent. Discover thousands of tools dynamically.

Installation

npm install @tpmjs/registry-search
# or
pnpm add @tpmjs/registry-search

Usage

import { streamText } from 'ai';
import { anthropic } from '@ai-sdk/anthropic';
import { registrySearchTool } from '@tpmjs/registry-search';
import { registryExecuteTool } from '@tpmjs/registry-execute';

const result = streamText({
  model: anthropic('claude-sonnet-4-20250514'),
  tools: {
    registrySearch: registrySearchTool,
    registryExecute: registryExecuteTool,
  },
  system: `You have access to the TPMJS tool registry.
Use registrySearch to find tools, then registryExecute to run them.`,
  prompt: 'Search for web scraping tools and scrape https://example.com',
});

// The agent can now:
// 1. Search for tools: registrySearch({ query: "web scraping" })
// 2. Execute found tools: registryExecute({ toolId: "@firecrawl/ai-sdk::scrapeTool", params: { url: "..." } })

Tool: registrySearchTool

Search the TPMJS registry to find AI SDK tools.

Parameters

NameTypeRequiredDescription
querystringYesSearch query (keywords, tool names, descriptions)
categorystringNoFilter by category
limitnumberNoMax results (1-20, default 5)

Categories

  • web-scraping
  • data-processing
  • file-operations
  • communication
  • database
  • api-integration
  • image-processing
  • text-analysis
  • automation
  • ai-ml
  • security
  • monitoring

Returns

{
  "query": "web scraping",
  "matchCount": 3,
  "tools": [
    {
      "toolId": "@firecrawl/ai-sdk::scrapeTool",
      "name": "scrapeTool",
      "package": "@firecrawl/ai-sdk",
      "description": "Scrape any website into clean markdown",
      "category": "web-scraping",
      "requiredEnvVars": ["FIRECRAWL_API_KEY"],
      "healthStatus": "HEALTHY",
      "qualityScore": 0.9
    }
  ]
}

Understanding requiredEnvVars

The requiredEnvVars field tells you which API keys a tool needs to function. When executing a tool with @tpmjs/registry-execute, pass these keys in the env parameter:

// 1. Search finds a tool that needs FIRECRAWL_API_KEY
const searchResult = await registrySearchTool.execute({ query: 'web scraping' });
// searchResult.tools[0].requiredEnvVars = ["FIRECRAWL_API_KEY"]

// 2. Execute the tool with the required key
const result = await registryExecuteTool.execute({
  toolId: '@firecrawl/ai-sdk::scrapeTool',
  params: { url: 'https://example.com' },
  env: { FIRECRAWL_API_KEY: 'fc-xxx' }  // Pass required keys here
});

Tools with an empty requiredEnvVars array don't need any API keys.

Environment Variables

VariableDefaultDescription
TPMJS_API_URLhttps://tpmjs.comBase URL for the registry API

Self-Hosted Registry

To use your own TPMJS registry:

export TPMJS_API_URL=https://registry.mycompany.com

Related

License

MIT

Statistics

Downloads/month

648

GitHub Stars

0

Quality Score

89%

Bundle Size

NPM Keywords

tpmjs
ai-sdk
vercel-ai
registry
search

Maintainers

thomasdavis(thomasalwyndavis@gmail.com)

Frameworks

vercel-ai