Conversation
- Web: OAuth AppDefinition using youtube.readonly as the default scope (channels, playlists, subscriptions, uploads) - Gateway: route youtube.googleapis.com and the legacy www.googleapis.com/youtube/ path via Bearer auth with shared GOOGLE_REFRESH config Signed-off-by: Radek Ježek <radek.jezek@ibm.com>
3 tasks
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 YouTube Data API v3 as a read-only OAuth connector — lets agents list channels, playlists, playlist items, and subscriptions.
Changes
apps/web/src/lib/apps/youtube.ts):AppDefinitionreusingbuildGoogleAuthUrl/exchangeGoogleCode/googleConfigFields/googleEnvDefaults. Default scope isyoutube.readonly(plusopenid/email/profilefor user metadata). Write scopes (youtube,youtube.upload,youtube.force-ssl, partner scopes) are intentionally omitted — they can be added later if needed.apps/gateway/src/apps.rs): two host rules —youtube.googleapis.com(catch-all) and the legacywww.googleapis.com/youtube/*path — both Bearer, sharingGOOGLE_REFRESH. Mirrors the Gmail pattern.providers_for_google_workspace_hosts,google_workspace_apps_use_bearer, and a/youtube/v3/playlistsdisambiguation check onwww.googleapis.com.apps/web/public/icons/youtube.svg.Note on watch history
Watch history is not available via any YouTube API — Google deprecated that access years ago. Playlists, subscriptions, and channel data are available.
Test plan
pnpm --filter @onecli/web lint— cleanpnpm --filter @onecli/web check-types— cleancargo test apps::— 30 tests passhttps://youtube.googleapis.com/youtube/v3/playlists?part=snippet&mine=truevia the gateway