MCPcopy Create free account
hub / github.com/Kilo-Org/cloud / getGithubTokenOrThrow

Function getGithubTokenOrThrow

apps/web/src/lib/github/open-pull-request-counts.ts:353–360  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

351}
352
353function getGithubTokenOrThrow(): string {
354 if (!GITHUB_ADMIN_STATS_TOKEN) {
355 throw new Error(
356 'Missing env var GITHUB_ADMIN_STATS_TOKEN; required for admin GitHub PR counts.'
357 );
358 }
359 return GITHUB_ADMIN_STATS_TOKEN;
360}
361
362async function githubRequest(url: string, init?: RequestInit): Promise<Response> {
363 const token = getGithubTokenOrThrow();

Callers 1

githubRequestFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected