---
schema_version: "1"
id: cf1a6290f9b86e97fd91f808d112df251acdde32a84025215a1beec86d3a2857
title: Adding a Vlocity Action to a Card (Managed Package)
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/xcloud/264-0-0/os_adding_a_vlocity_action_to_a_card.md
canonical_url: https://help.salesforce.com/s/articleView?id=xcloud.os_adding_a_vlocity_action_to_a_card.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: c53099815d366490e3452b4b1aa9c975a5d0507566542414803451bb33fe2272
description: For the managed package runtime, add reusable actions to a card with Vlocity Actions to launch Vlocity Omniscripts, Vlocity Cards components, web pages, or external applications.
products:
  - Omnistudio
release: "264"
---
# Adding a Vlocity Action to a Card (Managed Package)

For the managed package runtime, add reusable actions to a card with Vlocity Actions to launch Vlocity Omniscripts, Vlocity Cards components, web pages, or external applications.

![Managed Package app icon](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-xcloud-omnistudio_for_managed_packages-264-0-0-production-enus/aa2554ec-624a-4ee6-8da4-6435670e6e62/resources-global/_corporate/images/managedpackageicon.png) This information is for Omnistudio for Managed Packages. For Omnistudio on standard runtime, see [Omnistudio Help](https://help.salesforce.com/s/articleView?id=xcloud.os_omnistudio_standard.htm&language=en_US).

1. You must first create a Vlocity Action to add to your card. See [Vlocity Actions (Managed Package)](https://help.salesforce.com/s/articleView?id=xcloud.os_vlocity_actions.htm&release=264.0.0&type=5 "For the managed package runtime, Vlocity Actions are automatically generated URLS that launch Vlocity Omniscripts, Vlocity Cards components, web pages, or external applications. Actions are typically specific to a given object type, such as Account, Contact, Policy, or Asset.").
2. In your org, click App Launcher, click Vlocity Cards, and select a card layout to open the Card Designer.
3. In the **Actions** section of a card's state, click into the **Salesforce Object Type** input field, and select an sObject from the picklist, such as Contact.
    
    ![image](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-xcloud-omnistudio_for_managed_packages-264-0-0-production-enus/aa2554ec-624a-4ee6-8da4-6435670e6e62/omnistudio_for_managed_packages/images/vlocity_action_object.png)
4. Click into the **Id Field for Actions**, and select a ContextId from the available list of fields returned from the data source, such as \['ContactId'\].
    
    If **Blank Card State** is enabled:
    
    - Click the **Enable Id field for actions** checkbox to display the **Id Field for Actions** input field.
        
        ![image](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-xcloud-omnistudio_for_managed_packages-264-0-0-production-enus/aa2554ec-624a-4ee6-8da4-6435670e6e62/omnistudio_for_managed_packages/images/card_state_blank_card_state_enable_id_for_actions.png)
    - By default, the ContextId is `params.id` when **Enable Id field for actions** is disabled. When enabled, in addition to entering a ContextId from a data source, use **Id Field for Actions** to set any page parameter, session variable, or `$root` variable to fetch actions.
        
        For example, use the `$root.vlocity` context variable, such as $root.vlocity.userContactId to create an action for a logged-in user. For a list of available context variables, see [Cards Context Variables (Managed Package)](https://help.salesforce.com/s/articleView?id=xcloud.os_cards_context_variables.htm&release=264.0.0&type=5 "For the managed package runtime, several variables are available across the framework to provide contexts to cards, data sources, flyouts, templates, and other components.").
5. In the **Actions** section of a card state, next to the **Add** button, select a reusable action from the picklist.
    
    ![image](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-xcloud-omnistudio_for_managed_packages-264-0-0-production-enus/aa2554ec-624a-4ee6-8da4-6435670e6e62/omnistudio_for_managed_packages/images/vlocity_actions_picklist2.png)
    
    ![Important](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-xcloud-omnistudio_for_managed_packages-264-0-0-production-enus/aa2554ec-624a-4ee6-8da4-6435670e6e62/images/icon_important.png)
    
    Important
    
    If you do not see the action you are looking for, confirm you have selected the appropriate sObject from the **Salesforce Object Type** dropdown.
6. (Optional) Check the **Actions Options** checkbox to add **Custom Parameters** and **Conditions**.