Newer Version Available

This content describes an older version of this product. View Latest

describeQuickActions()

Retrieves details about specified actions.

Syntax

1DescribeQuickActionResult[] = connection.describeQuickActions(string[] quickActionNames);

Usage

Use the describeQuickActions() call to retrieve details for specified actions. In API version 28.0, the describeQuickActions() call takes the action name in the form of ParentEntity.ActionName. In API version 29.0 and greater, it takes the action name in the form of ContextEntity.ActionName. Returns an array of DescribeQuickActionResult. You might first call describeAvailableQuickActions() for a list of actions available for a specified context and then use describeQuickActions() to obtain details about specific actions.

In API version 46.0 and later, the apiName for a global quick action can include the prefix Global. in a describeQuickActions() request body. The request body also accepts global quick action API names without the prefix.

Note

Sample—Java

This sample retrieves and displays publisher action details for a create action on the Account object.

1public void example() throws Exception {
2    DescribeQuickActionResult[] result = 
3        conn.describeQuickActions(new String[] 
4            { "Account.QuickCreateContact", "Account.QuickCreateTask" });
5    for(DescribeQuickActionResult r : result) { 
6        assert r != null;
7    DescribeQuickActionDefaultValue [] describeQuickActionDefaultValues = r.getDefaultValues();
8    for(DescribeQuickActionDefaultValue defaultValue : describeQuickActionDefaultValues) {
9        System.out.println("Target Object Field:  " + defaultValue.getField() );
10        System.out.println("Target Object Field's default Value:  " + defaultValue.getDefaultValue );
11}
12        System.out.println("Action name: " + r.getName());
13        System.out.println("Action label: " + r.getLabel());
14        System.out.println("ParentOrContext object: " + r.getSourceSobjectType());
15        System.out.println("Target object: " + r.getTargetSobjectType());
16        System.out.println("Target object record type: " + r.getTargetRecordTypeId());
17        System.out.println("Relationship field: " + r.getTargetParentField());
18        System.out.println("Quick action type: " + r.getType());
19        System.out.println("VF page name for custom actions: " + 
20        r.getVisualforcePageName());
21        System.out.println("Icon name: " + r.getIconName());
22        System.out.println("Icon URL: " + r.getIconUrl());
23        System.out.println("Mini icon URL: " + r.getMiniIconUrl());
24        assert r.getLayout() != null;
25        System.out.println("Height of VF page for custom actions: " + r.getHeight());
26        System.out.println("Width of VF page for custom actions: " + r.getWidth());
27    }
28}

Arguments

Name Type Description
quickActions string[] An array of quick actions to be retrieved.