Skip to content

feat(sources): expose upstream url and render SourceFavicon#167

Merged
RhysSullivan merged 4 commits intoRhysSullivan:mainfrom
mrzmyr:feat/source-url-favicon
Apr 11, 2026
Merged

feat(sources): expose upstream url and render SourceFavicon#167
RhysSullivan merged 4 commits intoRhysSullivan:mainfrom
mrzmyr:feat/source-url-favicon

Conversation

@mrzmyr
Copy link
Copy Markdown
Contributor

@mrzmyr mrzmyr commented Apr 10, 2026

Summary

Adds an optional url field to the Source schema and wires each built-in source plugin to populate it. Introduces a new <SourceFavicon> component that derives a favicon from the source URL's base origin, and uses it in both app shells to give the sidebar a recognizable "title-card" feel.

Changes

Schema plumbingurl?: string on Source

  • packages/core/sdk/src/sources.ts
  • packages/core/api/src/sources/api.ts
  • packages/core/api/src/handlers/sources.ts

Plugin population

  • packages/plugins/mcp/src/sdk/plugin.ts — remote transport endpoint
  • packages/plugins/graphql/src/sdk/plugin.ts — configured endpoint
  • packages/plugins/openapi/src/sdk/plugin.ts — spec baseUrl
  • packages/plugins/google-discovery/src/sdk/plugin.tsrootUrl

UI

  • packages/react/src/components/source-favicon.tsx (new)
  • apps/cloud/src/web/shell.tsx — sidebar favicon + "Sources" label
  • apps/local/src/web/shell.tsx — sidebar favicon + "Sources" label

Notes

SourceFavicon shows a skeleton while loading and falls back gracefully if the host doesn't serve a favicon, so sources without a URL (e.g. stdio MCP transports) still render cleanly.

Adds an optional `url` field on the `Source` SDK schema, the HTTP
API response shape, and the handler projection. Each built-in
plugin populates it with the relevant upstream endpoint:

- `mcp`: remote transport's endpoint (undefined for stdio)
- `graphql`: the configured endpoint
- `openapi`: the spec baseUrl
- `google-discovery`: the rootUrl

Introduces `<SourceFavicon>`, a tiny component that extracts the
base origin from the URL and resolves a favicon, with a skeleton
placeholder while loading and a graceful fallback when the host
doesn't serve one.

Adopts it in both the cloud and local app shells — each sidebar
entry now shows the upstream's favicon next to the source name,
giving the list a much more recognizable "title-card" feel. Also
renames the section header from "Configured" to "Sources".
@mrzmyr
Copy link
Copy Markdown
Contributor Author

mrzmyr commented Apr 11, 2026

@RhysSullivan ready to merge

@RhysSullivan RhysSullivan merged commit 939ea7b into RhysSullivan:main Apr 11, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants