Split the provider into focused auth, onboarding, CLI, runtime, and shared modules so the Entra ID flow is easier to review and maintain. Add Foundry-specific tests, preserve Azure CLI error details, move token refresh off the synchronous request path, and dedupe concurrent Entra token refreshes so onboarding and GPT-5 runtime behavior stay reliable.
15 lines
359 B
TypeScript
15 lines
359 B
TypeScript
export {
|
|
TOKEN_REFRESH_MARGIN_MS,
|
|
buildFoundryProviderBaseUrl,
|
|
extractFoundryEndpoint,
|
|
resolveConfiguredModelNameHint,
|
|
type CachedTokenEntry,
|
|
} from "./shared.js";
|
|
|
|
export function getFoundryTokenCacheKey(params?: {
|
|
subscriptionId?: string;
|
|
tenantId?: string;
|
|
}): string {
|
|
return `${params?.subscriptionId ?? ""}:${params?.tenantId ?? ""}`;
|
|
}
|