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

Function reauth

packages/core/sdk/src/executor.ts:2569–2584  ·  view source on GitHub ↗
(
          message: string,
          options?: {
            readonly credentialMissing?: boolean;
            readonly blockedByAdmin?: boolean;
          },
        )

Source from the content-addressed store, hash-verified

2567 Effect.gen(function* () {
2568 const owner = row.owner as Owner;
2569 const reauth = (
2570 message: string,
2571 options?: {
2572 readonly credentialMissing?: boolean;
2573 readonly blockedByAdmin?: boolean;
2574 },
2575 ): CredentialResolutionError =>
2576 new CredentialResolutionError({
2577 owner,
2578 integration: IntegrationSlug.make(row.integration),
2579 name: ConnectionName.make(row.name),
2580 message,
2581 reauthRequired: true,
2582 ...(options?.credentialMissing === true ? { credentialMissing: true } : {}),
2583 ...(options?.blockedByAdmin === true ? { blockedByAdmin: true } : {}),
2584 });
2585
2586 // A recorded invalid_grant is the AS's standing verdict on this grant:
2587 // re-sending it cannot succeed, so don't. Fail as reauth-required

Callers 1

performTokenRefreshFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected