feat: add Tavily search provider to config and API layer#6
Open
tavily-integrations wants to merge 2 commits into
Open
Conversation
added 2 commits
May 15, 2026 15:09
… and REST API to support Tavily API key
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds Tavily as a configurable search provider alongside existing providers (SearXNG, Brave, SerpAPI, DuckDuckGo). This is an additive change — no existing provider logic is removed or modified.
What changed
server/src/services/ConfigManager.ts: ExtendedAppConfig.search.preferred_providerunion type to include'tavily'; addedtavily_api_key: stringfield with empty-string default.server/src/routes/searchRoutes.ts: Accepttavily_api_keyin POST/api/search/providers/configbody; callconfigureProvider('tavily', ...)when provided; added'tavily'to the priority maps for both preferred-provider promotion and auto-mode default priorities.server/src/index.ts: On startup, readTAVILY_API_KEYfrom env (or saved config) and callconfigureProvider('tavily', { apiKey, enabled: true }); added'tavily'to the preferred-provider priority bump map..env.example: AddedTAVILY_API_KEY=entry under the Web Search section.Files changed
server/src/services/ConfigManager.tsserver/src/routes/searchRoutes.tsserver/src/index.ts.env.exampleDependency changes
None — Tavily provider implementation (SDK dependency) is handled in a separate migration unit.
Environment variable changes
TAVILY_API_KEYreference in.env.exampleand startup config loadingNotes for reviewers
tsc --noEmit).Automated Review
as stringcast in index.ts is valid since the enclosing condition guarantees a truthy value. No regressions, no dead code, and no unintended changes were found.