Newer Version Available

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

PromptVersion

Represents an in-app guidance prompt or walkthrough. Available in API version 46.0 and later.

Use prompts and walkthroughs to display announcements, training, or news to users within the app. Choose to add an action button or link that links to a URL of your choice. Track views, action button clicks, and walkthrough completes.

Supported Calls

create(), delete(), describeSObjects(), query(), retrieve(), update(), upsert()

Special Access Rules

Admins have access to add or edit prompts and walkthroughs. For non-admin users, assign the Manage Prompts and Modify Metadata Through Metadata API Functions user permission. Everyone can see the In-App Guidance setup page. To show walkthroughs to users, use the View Walkthroughs user permission, which is part of the Walkthroughs permission set license. The myTrailhead subscription includes this feature. For pricing details, contact your Salesforce account executive.

Packaging Prompts and Walkthroughs

See Creating Managed Packages in Salesforce Help for more information.

See Considerations for Prompts in Lightning Experience in Salesforce Help for more information about installing and managing prompt packages and about editing and cloning prompts installed from packages.

If the package includes a custom profile or permission that isn’t part of a Salesforce org, the in-app guidance is installed, but it doesn't include those custom items. For example, an org installs a prompt with several custom profiles not included in their org. The prompts are installed without those custom profiles.

If the package includes a standard app that isn’t part of a Salesforce org, the in-app guidance is installed, but it's not usable.

If the package includes walkthroughs for standard apps that are part of an org, the walkthroughs are installed, but they aren't visible to users without the org subscribing to myTrailhead or starting a 30-day trial. However, orgs that don’t subscribe to myTrailhead or start a trial can show users walkthroughs from packages that have a walkthrough on at least one custom app page.

Walkthroughs can be only included in unmanaged packages, or in security-reviewed, first-generation managed packages.

When orgs install in-app guidance from packages, the in-app guidance will retain publish state as indicated by the IsPublished field. For example, if the package prompt is active, it will also be active when installed by the org.

Fields

Field Details
ActionButtonLabel
Type
string
Properties
Create, Filter, Group, Nillable, Sort, Update
Description
Label for the action button. Maximum of 25 characters. For walkthroughs, this field can only be specified on the last step.
ActionButtonLink
Type
url
Properties
Create, Filter, Nillable, Sort, Update
Description
URL for the action button. Maximum of 1,000 characters. You can’t use the GROUP BY option in a SOQL query for this field. For walkthroughs, this field can only be specified on the last step.
Body
Type
textarea
Properties
Create, Update
Description
Body content. For floating prompts, there’s a maximum of 240 characters. For docked prompts, there’s a maximum of 4000 characters. However, docked prompts use a rich text editor, so the maximum refers to the HTML markup, not the readable text.
DelayDays
Type
int
Properties
Create, Filter, Group, Nillable, Sort, Update
Description
Number of days between occurrences. For walkthroughs, this field can only be specified on the first step.
Description
Type
string
Properties
Create, Filter, Group, Nillable, Sort, Update
Description
Description of the in-app guidance.. Maximum of 255 characters.
DismissButtonLabel
Type
string
Properties
Create, Filter, Group, Nillable, Sort, Update
Description
Label for the dismiss button of a floating prompt. Maximum of 15 characters.
DisplayPosition
Type
picklist
Properties
Create, Filter, Group, Nillable, Restricted picklist, Sort, Update
Description
Indicates the position of the floating prompt on the page. Valid values are:
  • TopLeft
  • TopCenter
  • TopRight
  • BottomLeft
  • BottomCenter
  • BottomRight
DisplayType
Type
picklist
Properties
Create, Filter, Group, Restricted picklist, Sort, Update
Description
Indicates the type of prompt. Valid values are:
  • DockedComposer, which is the docked prompt
  • FloatingPanel, which is the floating prompt
EndDate
Type
date
Properties
Create, Filter, Group, Nillable, Sort, Update
Description
Indicates the date to stop showing the in-app guidance. For walkthroughs, this field can only be specified on the first step.
Header
Type
string
Properties
Create, Filter, Group, Nillable, Sort, Update
Description
Label for the header of the docked prompt. This is the label contained in the window’s browser bar. Maximum of 36 characters.
IndexWithIsPublished
Type
string
Properties
Filter, idLookup, Nillable, Sort
Description
Used by Salesforce for efficient querying.
IndexWithoutIsPublished
Type
string
Properties
Filter, idLookup, Nillable, Sort
Description
Used by Salesforce for efficient querying.
IsPublished
Type
boolean
Properties
Create, Defaulted on create, Filter, Group, Sort, Update
Description
Indicates if the in-app guidance is active yes or not no.
MasterLabel
Type
string
Properties
Create, Filter, Group, Sort, Update
Description
The master label. Maximum of 80 characters.
ParentId
Type
reference
Properties
Create, Filter, Group, Sort
Description
ID of the in-app guidance.
PublishedByUserId
Type
reference
Properties
Create, Filter, Group, Nillable, Sort, Update
Description
The ID of the user who activated the in-app guidance. If the in-app guidance is part of a package, this is the user who installed the package.
PublishedDate
Type
date
Properties
Create, Filter, Group, Nillable, Sort, Update
Description
Indicates the date the in-app guidance was activated. If the in-app guidance is part of a package, this is the date when the package was installed. For walkthroughs, this field can only be specified on the first step.
ShouldDisplayActionButton
Type
boolean
Properties
Create, Defaulted on create, Filter, Group, Sort, Update
Description
Indicates if an action button or link is included in the in-app guidance yes or not no.
ShouldIgnoreGlobalDelay
Type
boolean
Properties
Create, Defaulted on create, Filter, Group, Sort, Update
Description
Indicates if the prompt ignores the global time delay between in-app guidance and instead shows on page load yes or not no. The default is no.
StartDate
Type
date
Properties
Create, Filter, Group, Nillable, Sort, Update
Description
Indicates the date to start showing. For walkthroughs, this field can only be specified on the first step.
StepNumber
Type
int
Properties
Create, Filter, Group, Nillable, Sort, Update
Description
Indicates the number of the last step the user viewed or interacted with in a walkthrough. Maximum value is 10.
TargetAppDeveloperName
Type
string
Properties
Create, Filter, Group, Sort, Update
Description
The app’s developer name where the in-app guidance appears.
TargetAppNamespacePrefix
Type
string
Properties
Create, Filter, Group, Nillable, Sort, Update
Description
The app’s namespace prefix where the in-app guidance appears. Maximum of 15 characters.
TargetPageKey1
Type
string
Properties
Create, Filter, Group, Sort, Update
Description
Used by Salesforce to identity the page location along with targetPageKey2 and targetPageType.
TargetPageKey2
Type
string
Properties
Create, Filter, Group, Nillable, Sort, Update
Description
Used by Salesforce to identity the page location along with targetPageKey1 and targetPageType.
TargetPageType
Type
string
Properties
Create, Filter, Group, Sort, Update
Description
The type of page where the in-app guidance appears.
TimesToDisplay
Type
int
Properties
Create, Filter, Group, Nillable, Sort, Update
Description
Maximum number of times to display the in-app guidance (that is, the number of occurrences). Salesforce detects if the user interacts with (or ignores) the in-app guidance to determine if we should show the in-app guidance again or cancel scheduled recurrences. This may run counter to the number of occurrences scheduled. Maximum value of 30. For walkthroughs, this field can only be specified on the first step.
Title
Type
string
Properties
Create, Filter, Group, Sort, Update
Description
The label for the title of the in-app guidance.. Maximum of 36 characters.
UserAccess
Type
picklist
Properties
Create, Filter, Group, Nillable, Restricted picklist, Sort, Update
Description
Indicates which permissions can see the in-app guidance. Valid values are:
  • Everyone, which indicates that there’s no restrictions on who can see
  • SpecificPermissions, which indicates that only users with all the specific user permissions specified can see the in-app guidance
UserProfileAccess
Type
picklist
Properties
Create, Filter, Group, Nillable, Restricted picklist, Sort, Update
Description
Indicates which profiles can see the in-app guidance. Valid values are:
  • Everyone, which indicates that there’s no permission restrictions on who can see
  • SpecificProfiles, which indicates that users with any of the specific user profiles specified can see the in-app guidance
VersionNumber
Type
int
Properties
Create, Filter, Group, Sort, Update
Description
The number remains 1 since multiple versions aren’t saved in the org.
VideoLink
Type
url
Properties
Create, Filter, Nillable, Sort, Update
Description

URL for the video in a docked prompt. Maximum of 1,000 characters.

To find the embed code for a video, follow the instructions from the video host website. Usually the steps can be found by searching for the name of the website and “embed video.” For example, here’s what the embed code looks like for YouTube:

<iframe width="560" height="315" src="https://www.youtube.com/embed/Ko-gcObzTVo" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>

Then, you would enter the URL found in the src attribute. For the example used, enter https://www.youtube.com/embed/Ko-gcObzTVo.