ProtectedInternalExecutes the Tavily search.
The action parameters containing:
Days applies toSearch results, and the synthesized answer when requested
Executes the action with the provided parameters.
The action execution parameters including context
Promise resolving to the action result
Action that searches the web through Tavily, a search API built for LLM consumption: results arrive as extracted page content rather than as snippets plus links to go fetch.
Two things distinguish it from the other search actions in this package.
Topic: 'news'gives a date-filtered news index withPublishedDateon every result, which is what makes recency-sensitive questions answerable. AndIncludeAnswerreturns a synthesized answer alongside the results, so a caller that only needs the conclusion does not have to run its own summarization pass.Authentication is
Authorization: Bearer <key>. Tavily also still accepts anapi_keyfield in the request body, but that form is legacy and puts the credential in the payload, so it is not used here.Example