The Art of URL Hacking in Salesforce : Part III — Quick Actions (Global & Object Specific)

Shivam Vishwakarma
4 min readDec 17, 2023

--

In my previous article I had explained how one can use Salesforce URL Hacks to control Salesforce search (Now merged with Einstein Search feature).

If you haven’t read that yet, I would really encourage you to take the time to read once.

In this Article, I’ll explain how you can launch Global & Object Specific Quick Actions through URL Hacks.

For those of you, who are new to Global Actions & Object Specific Quick Actions, you can refer the following Salesforce Articles to know more about them.

A] Launching Global Actions

Use the following URL Pattern to call the Global Quick Actions via URL hack.

/lightning/action/quick/Global.<GlobalActionName>?recordId=<RecordPageId>&backgroundContext=<AnyBackgroundUrl>

Parameters that can be used in the URL :

  • recordId: Record Id of the Object from which you are calling this Global Action. This attribute is mandatory.
  • backgroundContext: This is used to set the background when the Quick action dialog box opens and also when the user clicks on cancel, they will land back on the page URL passed as value to this attribute. Refer my Part I — New Record Creation article to understand what all values you can pass here.
  • objectApiName: The API name of the Object which you are creating via the Global Action (Target Object Column in below image)
Example of Global Actions present in Setup

For Example:
Creating a New Contact using the Global Quick Action (API Name=NewContact) from Account (having Record Id as 0012x000004nHLoAAM), thus having background as Account’s Record page and redirect’s you back to Account’s Record page on clicking Cancel button.

/lightning/action/quick/Global.NewContact?objectApiName=Contact&context=RECORD_DETAIL&recordId=0012x000004nHLoAAM&backgroundContext=%2Flightning%2Fr%2FAccount%2F0012x000004nHLoAAM%2Fview
‘NewContact’ - Global Quick Action called from Account Object via URL Hack

B] Launching Object Specific Quick Actions

Use the following URL Pattern to call the Object Specific Quick Actions via URL hack.

/lightning/action/quick/<ObjectApiName>.<QuickActionApiName>?recordId=<RecordPageId>&backgroundContext=<AnyBackgroundUrl>

Parameters that can be used in the URL :

  • recordId: Record Id of the Object from which you are calling this Object Specific Quick Action. This attribute is mandatory.
  • backgroundContext: This is used to set the background when the Quick action dialog box opens and also when the user clicks on cancel, they will land back on the page URL passed as value to this attribute. Refer my Part I — New Record Creation article to understand what all values you can pass here.
  • objectApiName: The API name of the Object which you are creating via the Object Specific Quick Action (Column in below image)

For Example:
Creating a New Note using the Object Specific Quick Actions (API Name=New_Note) from Account (having Record Id as 0012x000004nHLoAAM), thus having background as Account’s Record page and redirect’s you back to Account’s Record page on clicking Cancel button.

Custom Object Specific Quick action to Create a Note on Account
/lightning/action/quick/Account.New_Note?objectApiName=Note&context=RECORD_DETAIL&recordId=0012x000004nHLoAAM&backgroundContext=%2Flightning%2Fr%2FAccount%2F0012x000004nHLoAAM%2Fview
‘New_Note’ - Custom Object specific Quick Action called from Account Object via URL Hack

I hope you enjoyed this article 📖 & found it insightful! 🔍!
Do hit the clap button👏 if you liked the article & leave a comment✍ if you have any queries/suggestions.

Enjoying the content? Don’t miss out on my future posts! Hit ‘Follow’ button to be the first to know about my new publications 🔔. Can’t wait to share more! 🚀🎉

Thanks for reading!

--

--

Shivam Vishwakarma

I'm a Salesforce Developer & CRM Analytics Enthusiast! Visit my LinkedIn to know more about me : linkedin.com/in/shivamashokvishwakarma