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

Function authenticateWith

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

Source from the content-addressed store, hash-verified

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

Callers 1

Calls 1

requestFunction · 0.70

Tested by

no test coverage detected