Conversation
Pegasystems Inc.
PL
Last activity: 29 Oct 2025 0:14 EDT
Deep Linking to Assignments
In Pega’s Traditional UI architecture, Theme Cosmos, it was common to share direct links (deep links) to specific assignments. This feature allowed users to quickly access work items or approval forms directly from an email or external system.
With Pega Constellation, this capability was initially not available, but as Constellation continues to evolve toward supporting more complete end-to-end experiences, direct links to assignments are possible through a combination of standard configuration and custom correspondence logic.
Business Purpose
In many business processes, not all participants are daily users of the Pega application. Think of:
- Customers or partners who occasionally need to provide information via a Web Self Service form.
 - Managers who receive an approval task via email and need to review and submit their decision without navigating through the application dashboard.
 - Internal users who are authenticated through SSO but not active in Pega daily — they just need to complete a single assignment.
 
For these use cases, deep links significantly simplify the interaction:
- They can click a link in a correspondence (such as an email or notification).
 - The link opens directly in the Constellation Web Portal to the specific assignment that needs their attention.
 - No manual navigation, searching, or context-switching is required.
 
This approach improves user experience, reduces process friction, and shortens cycle times — particularly for self-service or approval workflows.
Technical Implementation
In Constellation, each assignment can be opened using a URL pattern similar to:
https://<base-url>/prweb/app/<app-name>/<case-type>/<case-id>/assignments/<assignment-id>
Example:
URL Components:
- <base-url>: Your Pega environment's base URL
 - <app-name>: The application URL segment (e.g., "crm" for your application)
 - <case-type>: The case type URL representation (e.g., "surveys")
 - <case-id>: The unique case identifier (e.g., "S-40008")
 - <assignment-id>: The full assignment handle (e.g., "ASSIGN-WORKLIST%20OHBJGX-AB-WORK%20S-40008!FILL_FLOW")
 
example:
https://lab.pega.com/prweb/app/crm/surveys/S-40008/assignments/ASSIGN-W…
This URL can be safely constructed and shared via correspondence or notification messages.
Constructing the Link
In Theme Cosmos, developers often rely on the pxOpenAssignmentLink control to generate these URLs automatically. In Constellation, this control isn’t available, but equivalent functionality can be achieved with a simple correspondence fragment as shown above.
The difference lies mainly in the URL pattern and portal context — Constellation’s modular app structure and declarative routing require including the app, case type, and portal parameters in the URL.
The following example shows how to generate this Constellation assignment link inside a correspondence rule using a simple Server-Side Java code:
{%
    // Retrieve base URL (PublicLinkURL)
    String publicLinkURL = pega_procom_pegaprocomutilities.getPublicLinkURL();
    tools.putSaveValue("PublicLinkURL", publicLinkURL);
    // Get assignment page
    ClipboardPage ap = tools.findPage("newAssignPage");
    String assignmentKey = ap.getString("pxRefObjectInsName"); // Usually Case ID (e.g. S-40008)
    String assignInsKey = ap.getString("pzInsKey"); // Full assignment handle
    String caseType = "surveys"; // Adjust to your Constellation case type URL
    String appName = "crm"; // Adjust to your application URL segment
    // Construct Constellation URL
    String location = "/app/" + appName
        + "/" + caseType
        + "/" + assignmentKey
        + "/assignments/" + assignInsKey;
    tools.putSaveValue("RedirectLocation", location);
%}
<a target="_blank" href="{$save(PublicLinkURL)}{$save(RedirectLocation)}">{.pyID}</a>
This logic dynamically constructs the URL to the target assignment and embeds it as a clickable link in the outgoing correspondence (e.g., an email).
Example Output
When rendered in correspondence, the recipient will see something like:
📩 Please complete your survey: Open Survey S-40008
Clicking the link will open the assignment directly in the Constellation Web Portal, ready for the user to interact with.
Security and Access
Deep links must respect authentication and authorization rules.
- If the user is already logged in (via SSO or standard authentication), the system will open the assignment directly.
 - If not, the Authorization Service configured for the Web Portal handles login and redirection.
 
Best Practices
- URL Encoding: Ensure special characters in assignment handles are properly URL-encoded
 - Environment Configuration: Use dynamic base URL retrieval rather than hardcoding URLs to support deployment across multiple environments
 - Security Validation: Always validate user access rights at the assignment level, not just at authentication
 
Key Takeaways
- Deep linking to assignments is now achievable in Pega Constellation using a well-formed URL.
 - It’s ideal for Web Self Service scenarios and infrequent authenticated users.
 - Security is preserved through Authorization Services and portal-based access.
 - Developers can replicate pxOpenAssignmentLink functionality with a few lines of code in correspondence.
 
Constellation 101 Series
Enjoyed this article? See more similar articles in Constellation 101 series.