@supernovaio/cli
Version:
Supernova.io Command Line Interface
13 lines (11 loc) • 839 B
JavaScript
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="cf8fe312-8299-5b16-af5b-9baff090d940")}catch(e){}}();
import { SupernovaApiClient } from "@supernova-studio/client";
import { VaultService } from "../services/vault.service.js";
import { apiUrlForEnvironment } from "../types/environment.js";
const vaultService = new VaultService();
export const getApiClient = async (env) => {
const { accessToken } = await vaultService.getTokensFromVault(env);
return new SupernovaApiClient({ accessToken, baseUrl: apiUrlForEnvironment(env, null) });
};
//# sourceMappingURL=api-client.js.map
//# debugId=cf8fe312-8299-5b16-af5b-9baff090d940