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

Function reauth

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

Source from the content-addressed store, hash-verified

2581 Effect.gen(function* () {
2582 const owner = row.owner as Owner;
2583 const reauth = (
2584 message: string,
2585 options?: {
2586 readonly credentialMissing?: boolean;
2587 readonly blockedByAdmin?: boolean;
2588 },
2589 ): CredentialResolutionError =>
2590 new CredentialResolutionError({
2591 owner,
2592 integration: IntegrationSlug.make(row.integration),
2593 name: ConnectionName.make(row.name),
2594 message,
2595 reauthRequired: true,
2596 ...(options?.credentialMissing === true ? { credentialMissing: true } : {}),
2597 ...(options?.blockedByAdmin === true ? { blockedByAdmin: true } : {}),
2598 });
2599
2600 // A recorded invalid_grant is the AS's standing verdict on this grant:
2601 // 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