Title: Plugin api: bless getWebIdFromRequestAsync as api.auth.getAgent (request → WebID) · Issue #584 · JavaScriptSolidServer/JavaScriptSolidServer · GitHub
Open Graph Title: Plugin api: bless getWebIdFromRequestAsync as api.auth.getAgent (request → WebID) · Issue #584 · JavaScriptSolidServer/JavaScriptSolidServer
X Title: Plugin api: bless getWebIdFromRequestAsync as api.auth.getAgent (request → WebID) · Issue #584 · JavaScriptSolidServer/JavaScriptSolidServer
Description: Split out of #206 (plugin-zero results comment): the third seam from the Tideholm mount — and the happiest finding, because no new code is needed, only a public blessing. Finding getWebIdFromRequestAsync(request) in src/auth/token.js alr...
Open Graph Description: Split out of #206 (plugin-zero results comment): the third seam from the Tideholm mount — and the happiest finding, because no new code is needed, only a public blessing. Finding getWebIdFromReques...
X Description: Split out of #206 (plugin-zero results comment): the third seam from the Tideholm mount — and the happiest finding, because no new code is needed, only a public blessing. Finding getWebIdFromReques...
Opengraph URL: https://github.com/JavaScriptSolidServer/JavaScriptSolidServer/issues/584
X: @github
Domain: github.com
IPv4 address: 140.82.114.4
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Plugin api: bless getWebIdFromRequestAsync as api.auth.getAgent (request → WebID)","articleBody":"Split out of #206 (plugin-zero results comment): the third seam from the [Tideholm](https://github.com/melvincarvalho/tideholm/tree/gh-pages/jss-plugin) mount — and the happiest finding, because **no new code is needed**, only a public blessing.\n\n## Finding\n\n`getWebIdFromRequestAsync(request)` in `src/auth/token.js` already does everything an app plugin needs to answer \"who is this?\": Bearer (IDP-issued), Solid-OIDC DPoP, Nostr NIP-98, and LWS10-CID, uniformly, returning `{ webId, error }`. The Tideholm adapter uses it directly and pod identities become game players with zero auth code of their own (\"your WebID is your player\").\n\nThe problem is only that reaching into `src/auth/token.js` is an internal import — the function's location, name, and shape are all unwarranted by anything public. Plugin zero works today and breaks the day auth is refactored.\n\n## Proposal\n\nBless it as the loader's identity seam:\n\n```js\napi.auth.getAgent(request) // -> Promise\u003cstring|null> (WebID or null)\n```\n\n- Thin wrapper over `getWebIdFromRequestAsync`, returning just the WebID (plugins that want the error detail can get a second method or the raw result later — start minimal).\n- **Authentication only, deliberately not authorization**: apps under an `appPaths` prefix (sibling issue) own their own permissioning; WAC stays out of their jurisdiction.\n- Until the loader lands, exporting it from the package root (`javascript-solid-server/auth`) would give manually-composed apps a stable import path.\n\n## Acceptance\n\n- [ ] Stable public accessor for request → WebID covering all four token types\n- [ ] Contract test pinning the shape (so auth refactors keep the seam)\n- [ ] Tideholm adapter migrated onto it (I'll do this the day it exists)\n- [ ] Listed in the #206 api surface next to `api.fastify`, `registerMcpTool`, `registerPane`","author":{"url":"https://github.com/melvincarvalho","@type":"Person","name":"melvincarvalho"},"datePublished":"2026-07-10T11:39:29Z","url":"https://github.com/JavaScriptSolidServer/JavaScriptSolidServer/issues/584"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:05298852-a1eb-b108-948a-55198dcd56fa |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | EC64:298A98:4AAE0F:5DD099:6B038A3A |
| html-safe-nonce | 9d8e2c349a3e21918f2c2281748b7c1dc1e5abbc67c24fa08db6951e88ab0ef0 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFQzY0OjI5OEE5ODo0QUFFMEY6NUREMDk5OjZCMDM4QTNBIiwidmlzaXRvcl9pZCI6IjUwMjMxNDA4NjM1MjI2MDU2MjYiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | cd176e51be171d8b81aba52f69af6e3a6513e9dc520f44205ec4b64b1a57047e |
| hovercard-subject-tag | issue:4854658792 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/JavaScriptSolidServer/JavaScriptSolidServer/584/issue_layout |
| twitter:image | https://opengraph.githubassets.com/c5e0ac599a58782bfface9360d0e0e9d1b807d97a53e2821aaa4df5efa9f6f58/JavaScriptSolidServer/JavaScriptSolidServer/issues/584 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/c5e0ac599a58782bfface9360d0e0e9d1b807d97a53e2821aaa4df5efa9f6f58/JavaScriptSolidServer/JavaScriptSolidServer/issues/584 |
| og:image:alt | Split out of #206 (plugin-zero results comment): the third seam from the Tideholm mount — and the happiest finding, because no new code is needed, only a public blessing. Finding getWebIdFromReques... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | melvincarvalho |
| hostname | github.com |
| expected-hostname | github.com |
| None | 87e774ee7c6b3bee0490394e4d3e57ec9dbc956f74b87ea685dc8996c1676456 |
| turbo-cache-control | no-preview |
| go-import | github.com/JavaScriptSolidServer/JavaScriptSolidServer git https://github.com/JavaScriptSolidServer/JavaScriptSolidServer.git |
| octolytics-dimension-user_id | 205442424 |
| octolytics-dimension-user_login | JavaScriptSolidServer |
| octolytics-dimension-repository_id | 958025407 |
| octolytics-dimension-repository_nwo | JavaScriptSolidServer/JavaScriptSolidServer |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 958025407 |
| octolytics-dimension-repository_network_root_nwo | JavaScriptSolidServer/JavaScriptSolidServer |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 423dbb54c5e7bfecc838eb387c1435eb3d0e760d |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width