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

Function isDefinitiveWorkOSDenial

apps/cloud/src/auth/errors.ts:41–42  ·  view source on GitHub ↗
(error: unknown)

Source from the content-addressed store, hash-verified

39/** A `WorkOSError` that is a definitive denial (see above), typed on `unknown`
40 * so auth code holding an untyped failure channel can branch safely. */
41export const isDefinitiveWorkOSDenial = (error: unknown): boolean =>
42 isWorkOSError(error) && isDefinitiveWorkOSDenialStatus(error.status);
43
44// Every typed exception the WorkOS node SDK throws for an HTTP answer carries a
45// numeric `.status` (UnauthorizedException 401, NotFoundException 404,

Callers 2

errors.test.tsFile · 0.90
finishAuthorizedFunction · 0.90

Calls 1

Tested by

no test coverage detected