I have same code base uploaded on Dynamics 365 environment and PowerApps environment. In PowerApps environment Marketing List, Lead, Opportunity entities are not available.
So I need to identity by JavaScript client api that I am in 365 or PowerApps environment and according to it will enable or disable functionality to be executed.
Please suggest any client api method I can use to achieve this requirement.
Hello,
You can try to get metadata let's say of opportunity and if call fails - you're in pure CDS environment (I believe you meant that as PowerApps). If call returns the data - you're in the Dynamics environment.
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,240 Super User 2024 Season 2
Martin Dráb 230,149 Most Valuable Professional
nmaenpaa 101,156