Skip to main content
Every FinanceTools tool has an async variant registered under the same name, so agent.arun() / agent.aprint_response() use them automatically. Providers with a native async client (financialdatasets.ai via httpx) run without a thread; sync-only providers (yfinance) run in a worker thread.
async.py

Run the Example

1

Set up your virtual environment

2

Install dependencies

3

Export your API keys

4

Run the example

Save the code above as async.py, then run:
Full source: cookbook/91_tools/finance/05_async.py