You need to sign in to do that
Don't have an account?
![Alex Packard 5 Alex Packard 5](https://dfc-org-production.my.site.com/img/userprofile/default_profile_45_v2.png)
QuickAction.DescribeQuickActions Broken In Managed Packages
QuickAction.DescribeQuickActions() will return different results when called from a managed package context and unmanaged code.
For a given entity type, for example Contacts, you must call QuickAction.DescribeAvailableQuickActions('Contact') to get a list of available contact quick action names. Take those quick action names and pass them into QuickAction.DescribeQuickActions(names).
This describe call will only correctly return the quick actions if called from unmanaged code (for example, when called from anonymous apex). However, if this code is called as part of a managed package, the expected quick actions are not returned.
We've noticed that passing in a namespaced quick action names into the method will still work in a managed package. We suspect that Salesforce is incorrectly trying to add the package's namespace to the quick action names being passed into the call, but this makes it impossible to access non-namespaced quick actions.
Has anyone ever run into this before? Any ideas on how to get around it?
P.S. I also made an idea for Salesforce to correct this behavior, please vote for it: https://partners.salesforce.com/ideaView?id=0873A0000003b7NQAQ
For a given entity type, for example Contacts, you must call QuickAction.DescribeAvailableQuickActions('Contact') to get a list of available contact quick action names. Take those quick action names and pass them into QuickAction.DescribeQuickActions(names).
This describe call will only correctly return the quick actions if called from unmanaged code (for example, when called from anonymous apex). However, if this code is called as part of a managed package, the expected quick actions are not returned.
We've noticed that passing in a namespaced quick action names into the method will still work in a managed package. We suspect that Salesforce is incorrectly trying to add the package's namespace to the quick action names being passed into the call, but this makes it impossible to access non-namespaced quick actions.
Has anyone ever run into this before? Any ideas on how to get around it?
P.S. I also made an idea for Salesforce to correct this behavior, please vote for it: https://partners.salesforce.com/ideaView?id=0873A0000003b7NQAQ
![Alex Packard 5 Alex Packard 5](https://dfc-org-production.my.site.com/img/userprofile/default_profile_45_v2.png)
Here's an alternative link for the idea: https://success.salesforce.com/ideaView?id=0873A0000003b7NQAQ
![Igor Babych 14 Igor Babych 14](https://dfc-org-production.my.site.com/img/userprofile/default_profile_45_v2.png)
You can use REST API (https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/resources_sobject_quickactions.htm) for retrieving QuickActions description.