Skip to content

Commit 829ccc4

Browse files
committed
fix(webapp): allow JWT + CORS on sessions list endpoint
Without allowJWT/corsStrategy, frontend clients holding public access tokens hit 401 on GET /api/v1/sessions and browser preflights fail. Matches the single-session GET/PATCH/close routes and the runs list endpoint.
1 parent 27fb4a4 commit 829ccc4

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

apps/webapp/app/routes/api.v1.sessions.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@ function asArray<T>(value: T | T[] | undefined): T[] | undefined {
2626
export const loader = createLoaderApiRoute(
2727
{
2828
searchParams: ListSessionsQueryParams,
29+
allowJWT: true,
30+
corsStrategy: "all",
2931
findResource: async () => 1,
3032
},
3133
async ({ searchParams, authentication }) => {

0 commit comments

Comments
 (0)