Skip to content

Added a Brave Search connector#245329

Merged
seanstory merged 8 commits intomainfrom
seanstory/add-brave-search-v2-connector
Dec 15, 2025
Merged

Added a Brave Search connector#245329
seanstory merged 8 commits intomainfrom
seanstory/add-brave-search-v2-connector

Conversation

@seanstory
Copy link
Member

@seanstory seanstory commented Dec 4, 2025

Summary

Adds a connector for Brave Search to the new "v2" framework.

This is an API we've found useful for doing web search in workflows and with Agent Builder.

Checklist

Check the PR satisfies following conditions.

Reviewers should verify this PR satisfies this list as well.

Release Notes

Introduces a connector for web search via Brave Search

@seanstory seanstory requested a review from a team December 4, 2025 23:58
@seanstory seanstory added backport:skip This PR does not require backporting release_note:feature Makes this part of the condensed release notes labels Dec 4, 2025
@seanstory seanstory marked this pull request as ready for review December 5, 2025 18:23
@seanstory seanstory requested review from a team as code owners December 5, 2025 18:23
@github-actions
Copy link
Contributor

github-actions bot commented Dec 5, 2025

.describe('Result offset for pagination'),
}),
output: z.object({
query: z.any().describe('Original query information'),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The remote API does have a strict definition:

https://api-dashboard.search.brave.com/app/documentation/web-search/responses

Do we want to be loose to avoid breaking on any changes from that API and only fixing any downstream users of this response?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's my instinct, yeah. At least for now. Maybe we'll want to tighten this if/when we build an OOTB workflow that needs to depend on specific fields.

@seanstory seanstory force-pushed the seanstory/add-brave-search-v2-connector branch from 0b41c8c to 33fffa5 Compare December 11, 2025 21:49
@seanstory seanstory requested a review from a team as a code owner December 11, 2025 21:49
@seanstory seanstory force-pushed the seanstory/add-brave-search-v2-connector branch from 33fffa5 to 8213616 Compare December 12, 2025 18:56
@seanstory seanstory requested review from a team and kibanamachine as code owners December 12, 2025 18:56
@seanstory seanstory changed the base branch from main to seanstory/add-v2-tests-docs-and-i18n December 12, 2025 18:57
Base automatically changed from seanstory/add-v2-tests-docs-and-i18n to main December 12, 2025 20:53
Add docs, tests, and internationalization

Add brave search docs to the TOC

Add brave search do stack connectors snippet

Fix the syntax issue
@seanstory seanstory force-pushed the seanstory/add-brave-search-v2-connector branch from fdff411 to 00711ac Compare December 12, 2025 21:38
@seanstory seanstory removed the request for review from a team December 12, 2025 21:40
@seanstory seanstory removed the request for review from a team December 13, 2025 16:24
@seanstory seanstory removed the request for review from kibanamachine December 15, 2025 15:33
@@ -2314,6 +2314,7 @@ src/platform/packages/shared/kbn-connector-specs/src/all_specs.ts
src/platform/packages/shared/kbn-connector-specs/src/connector_icons_map.ts
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@seanstory could you please add this line? thanks!

Suggested change
src/platform/packages/shared/kbn-connector-specs/src/connector_icons_map.ts
src/platform/packages/shared/kbn-connector-specs/src/connector_icons_map.ts
src/platform/packages/shared/kbn-connector-specs/src/specs/** @elastic/workflows-eng
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no - we don't want every new spec to require the review of the workflows-eng folks. If my team (E&T) adds a new connector (like this Brave Search connector) I shouldn't need the Workflow team's approval. Ideally, I wouldn't need anyone's approval but my own team.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Then we should keep it empty, otherwise it requires a review from the Response Ops team, like in this PR.
FYI, CODEOWNERS rules are applied from the main branch, not from the PR branch.

src/platform/packages/shared/kbn-connector-specs/src/specs/**
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

src/platform/packages/shared/kbn-connector-specs/src/specs/**
src/platform/packages/shared/kbn-connector-specs/src/all_specs.ts
src/platform/packages/shared/kbn-connector-specs/src/connector_icons_map.ts
src/platform/packages/shared/kbn-connector-specs/src/specs/alienvault_otx/** @elastic/workflows-eng
src/platform/packages/shared/kbn-connector-specs/src/specs/brave_search/** @elastic/workchat-eng

vs

src/platform/packages/shared/kbn-connector-specs/src/all_specs.ts
src/platform/packages/shared/kbn-connector-specs/src/connector_icons_map.ts
src/platform/packages/shared/kbn-connector-specs/src/specs/alienvault_otx/** @elastic/workflows-eng
src/platform/packages/shared/kbn-connector-specs/src/specs/brave_search/** @elastic/workchat-eng

vs

src/platform/packages/shared/kbn-connector-specs/src/specs/alienvault_otx/** @elastic/workflows-eng
src/platform/packages/shared/kbn-connector-specs/src/specs/brave_search/** @elastic/workchat-eng

Are all functionally equivalent, AFAICT? And yes, right now they all end up requiring a review from response ops when new connectors are added, because all_specs.ts and connector_icons_map.ts always get changed. There's not a good single-team owner for these, I don't think. The only solution IMO is to adjust these files to automatically detect specs/icons based on the folders available, rather than on new code lines that must be added. OR, response-ops has to always approve new connectors, and at least doesn't get bothered when existing connectors are modified.

WDYT?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm know sure if they are equivalent, because rules listed below overrides the top rules.

src/platform/packages/shared/kbn-connector-specs @elastic/response-ops <- set a default owner 

src/platform/packages/shared/kbn-connector-specs/src/all_specs.ts <- removes any team as owner (it works!)
src/platform/packages/shared/kbn-connector-specs/src/connector_icons_map.ts <- removes any team as owner (it works!)
src/platform/packages/shared/kbn-connector-specs/src/specs/** <- should also remove any team as owner
src/platform/packages/shared/kbn-connector-specs/src/specs/alienvault_otx/** @elastic/workflows-eng <- set ownership per folder spec
Copy link
Contributor

@florent-leborgne florent-leborgne left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM from a docs perspective. Thanks for updating this with the structure we discussed in the other PR 🚢

@elasticmachine
Copy link
Contributor

💛 Build succeeded, but was flaky

Failed CI Steps

Test Failures

  • [job] [logs] FTR Configs #133 / Serverless Observability - Deployment-agnostic AI Assistant API integration tests observability AI Assistant tool: retrieve_elastic_doc POST /internal/observability_ai_assistant/chat/complete The second request - Sending the user prompt should send 1 document to the llm

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
stackConnectors 607 610 +3
workflowsManagement 1118 1119 +1
total +4

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
stackConnectors 1.1MB 1.1MB +6.7KB
workflowsManagement 1.2MB 1.2MB +1.6KB
total +8.4KB

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
stackConnectors 76.0KB 76.1KB +66.0B
Unknown metric groups

async chunk count

id before after diff
stackConnectors 116 117 +1

History

@seanstory seanstory merged commit b46b66b into main Dec 15, 2025
14 checks passed
@seanstory seanstory deleted the seanstory/add-brave-search-v2-connector branch December 15, 2025 21:56
@florent-leborgne florent-leborgne added Feature:Actions/ConnectorTypes Issues related to specific Connector Types on the Actions Framework Feature:Actions/ConnectorsManagement Issues related to Connectors Management UX and removed Feature:Actions/ConnectorsManagement Issues related to Connectors Management UX labels Jan 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:skip This PR does not require backporting Feature:Actions/ConnectorTypes Issues related to specific Connector Types on the Actions Framework release_note:feature Makes this part of the condensed release notes v9.3.0

7 participants