Prerequisites
The following examples requires the linkup-sdk library and an API key from Linkup.Example
The following agent will search the web for the latest news in French politics and print the response.cookbook/tools/linkup_tools.py
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
You are viewing v1 docs. For the latest documentation, visit docs.agno.com
The toolkit enables an Agent to search the web using the Linkup API
pip install -U linkup-sdk
export LINKUP_API_KEY=***
from agno.agent import Agent
from agno.tools.linkup import LinkupTools
agent = Agent(tools=[LinkupTools()], show_tool_calls=True)
agent.print_response("What's the latest news in French politics?", markdown=True)
| Function | Description |
|---|---|
web_search_with_linkup | Searches the web for a query using Linkup API. Takes a query string and optional depth/output_type parameters. Returns search results as a string. |
| Parameter | Type | Default | Description |
|---|---|---|---|
api_key | Optional[str] | None | API key for authentication. If not provided, will check LINKUP_API_KEY environment variable. |
depth | Literal["standard", "deep"] | "standard" | Depth of the search. Use ‘standard’ for fast and affordable web search or ‘deep’ for comprehensive, in-depth web search. |
output_type | Literal["sourcedAnswer", "searchResults"] | "searchResults" | Type of output. ‘sourcedAnswer’ provides a comprehensive natural language answer to the query along with citations to the source material. ‘searchResults’ returns the raw search context data without synthesis. |
Was this page helpful?