@financialmodelingprep/tools
v1.0.2
Published
Auto-generated Vercel AI SDK tool wrappers for the Financial Modeling Prep API
Maintainers
Readme
FMP Tools
Auto-generated Vercel AI SDK tool definitions wrapping every @financialmodelingprep/sdk API function. Generated by @financialmodelingprep/gen.
Installation
bun add @financialmodelingprep/toolsUsage
[!WARNING] ~100 tools — this module exports all SDK functions as tools. Passing the full
toolsobject togenerateTextmay saturate your prompt with tool definitions. Either pass a selected subset (e.g.,pick(tools, 'searchSymbol', 'companyProfile')) or use a retriever likeai-tool-retrieverto dynamically select tools per request.
import { tools } from '@financialmodelingprep/tools'
import { generateText } from 'ai'
const result = await generateText({
model: openai('<model>'),
tools,
prompt: 'What is the price of AAPL?',
})Each tool wraps an SDK API function with a Zod input schema and an execute handler. Return values can be filtered to specific fields using the values parameter.
Development
To regenerate after SDK changes:
bun run --filter @financialmodelingprep/gen generate:tools
bun run --filter @financialmodelingprep/gen generate:docs