MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / authenticateWith

Function authenticateWith

apps/cloud/src/mcp/auth-provider.test.ts:86–95  ·  view source on GitHub ↗
(
  orgAuth: Layer.Layer<McpOrganizationAuth>,
  auth: Layer.Layer<McpAuth> = stubAuth,
)

Source from the content-addressed store, hash-verified

84}> {}
85
86const authenticateWith = (
87 orgAuth: Layer.Layer<McpOrganizationAuth>,
88 auth: Layer.Layer<McpAuth> = stubAuth,
89) =>
90 Effect.gen(function* () {
91 const provider = yield* McpAuthProvider;
92 return yield* provider.authenticate(request());
93 }).pipe(
94 Effect.provide(cloudMcpAuthProviderLayer.pipe(Layer.provide(Layer.mergeAll(auth, orgAuth)))),
95 );
96
97describe("cloud MCP org-authorization classification", () => {
98 it.effect("WorkOS 5xx -> Unavailable (retryable 503, session preserved)", () =>

Callers 1

Calls 1

requestFunction · 0.70

Tested by

no test coverage detected