diff --git a/src/common/services/AuthenticationProvider.ts b/src/common/services/AuthenticationProvider.ts index 6a3b594d..cd4d913c 100644 --- a/src/common/services/AuthenticationProvider.ts +++ b/src/common/services/AuthenticationProvider.ts @@ -301,6 +301,8 @@ export async function powerPlatformAPIAuthentication( ): Promise { let accessToken = ""; try { + + ppapiEndpoint = ppapiEndpoint.split("/powerpages")[0]; const PPAPI_WEBSITES_SERVICE_SCOPE_DEFAULT = `${ppapiEndpoint}${SCOPE_OPTION_DEFAULT}`; let session = await vscode.authentication.getSession( PROVIDER_ID,