MCPcopy Index your code
hub / github.com/callstack/agent-device / assertDeviceAuthStart

Function assertDeviceAuthStart

src/cli/auth-session.ts:464–472  ·  view source on GitHub ↗
(response: DeviceAuthStartResponse)

Source from the content-addressed store, hash-verified

462}
463
464function assertDeviceAuthStart(response: DeviceAuthStartResponse): void {
465 if (
466 !hasToken(response.deviceCode) ||
467 !hasToken(response.userCode) ||
468 !hasToken(response.verificationUri)
469 ) {
470 throw new AppError('COMMAND_FAILED', 'Cloud auth start returned an unusable response.');
471 }
472}
473
474function detectAuthMode(
475 env: EnvMap,

Callers 1

loginWithDeviceAuthFunction · 0.85

Calls 1

hasTokenFunction · 0.85

Tested by

no test coverage detected