coleam00/Archon · error
GITHUB_APP_CLIENT_ID is required for the GitHub device flow.
Error message
GITHUB_APP_CLIENT_ID is required for the GitHub device flow. Find it on the GitHub App settings page (the client id, starts with "Iv1." or "Iv23").
What it means
Error "GITHUB_APP_CLIENT_ID is required for the GitHub device flow. Find it on the GitHub App settings page (the client id, starts with "Iv1." or "Iv23")." thrown in coleam00/Archon.
Source
Thrown at packages/core/src/github-auth/config.ts:37
}
/**
* Per-user GitHub attribution is active only when the GitHub App is configured
* AND a token-encryption key is present.
*/
export function isPerUserGitHubEnabled(env: NodeJS.ProcessEnv = process.env): boolean {
return Boolean(env.GITHUB_APP_ID && env.TOKEN_ENCRYPTION_KEY);
}
/**
* Resolve the GitHub App client id used for the device flow. Throws if missing
* so the connect surfaces fail fast with an actionable message rather than
* issuing a malformed device-code request.
*/
export function loadDeviceFlowConfig(env: NodeJS.ProcessEnv = process.env): DeviceFlowConfig {
const clientId = env.GITHUB_APP_CLIENT_ID?.trim();
if (!clientId) {
throw new Error(
'GITHUB_APP_CLIENT_ID is required for the GitHub device flow. ' +
'Find it on the GitHub App settings page (the client id, starts with "Iv1." or "Iv23").'
);
}
return { clientId };
}
/**
* Fail fast at server boot: when per-user GitHub is enabled, the encryption key
* must be present and well-formed. `getEncryptionKey()` throws otherwise, so a
* misconfigured deployment never silently stores unencryptable tokens.
*/
export function assertEncryptionKeyAtBoot(env: NodeJS.ProcessEnv = process.env): void {
if (isPerUserGitHubEnabled(env)) {
getEncryptionKey(env);
}
}
View on GitHub (pinned to 0773b97458)
When it happens
Trigger: Thrown at packages/core/src/github-auth/config.ts:37 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of coleam00/Archon@0773b97458 (2026-09-01).
Data as JSON: /api/errors/bd544e836a0db0c1.
Report an issue: GitHub.