@capgo/cli
Version:
A CLI to upload to capgo servers
14 lines (13 loc) • 778 B
TypeScript
import { createSupabaseClient } from '../utils';
export interface OrgResolverDeps {
/** @deprecated Prefer fetchOwnerOrg; kept for existing unit tests. */
createClient?: typeof createSupabaseClient;
/** Injectable for tests; defaults to GET app via invokeCapgoCliApi. */
fetchOwnerOrg?: (apikey: string, appId: string, signal?: AbortSignal) => Promise<string | undefined>;
}
/**
* Resolves an app's owner organization id (`apps.owner_org`), promise-cached
* per `(apikey, appId)`. Returns undefined on any error — never throws.
* Extracted so the analytics layer and onboarding analytics share one path.
*/
export declare function resolveOwnerOrgId(apikey: string, appId: string, deps?: OrgResolverDeps, signal?: AbortSignal): Promise<string | undefined>;