PM Pagehooks
Introduction to PM Pagehooks
Pagehooks are part of the UI Extensibility features in Aprimo, enabling you to add configurable buttons or navigation items that open external sites in new browser tabs or windows. On task pages, pagehooks can be configured to appear at specific workflow steps.
Key Features
- Contextual Navigation: External sites can dynamically understand the record ID and page ID from where the user clicked.
Example Use Case
If a pagehook button is placed on the activity view page with an external URL:
https://my.aprimoexternalapp.com/?ActivityID={{ID}}
When a user clicks the button on record ID 2201, they will be taken to:
https://my.aprimoexternalapp.com?ActivityID=2201
This enables external sites to extend Aprimo's functionality, load record-specific reports, and more.
Adding a Pagehook with Contextual Tokens
-
Configure the Integration:
- Register your external application's URL with pagehook tokens under System Tools > Integration > Registrations.
-
Set Up the Navigation Item or Button:
- Use the following URL format for the navigation item or button:
https://[externalsite].com?aprimo_registration_id=[registration_id] - Replace
[registration_id]with the integer ID of your integration registration.
- Use the following URL format for the navigation item or button:
Example:
https://developers.aprimo.com?aprimo_registration_id=83
- How it Works:
- When the button or navigation item is clicked:
- The user's browser briefly redirects to the
https://[externalsite].compage. - The integration registration's callback URL is retrieved.
- Any dynamic pagehook tokens in the URL are populated.
- The user is redirected to the resulting URL.
- The user's browser briefly redirects to the
Notes
- Pagehook tokens include:
- Contextual Tokens: Provide record and page IDs for the external site.
- External URLs using pagehooks must be HTTPS.
- For pagehooks without contextual tokens, proceed directly to configuring a navigation item or button.
Configuring Pagehooks
How to Configure an Integration Registration
You can skip this step if your URL does not use pagehook tokens.
- Purpose: An integration registration is required to interface with the Aprimo REST API or when using pagehook tokens in an external URL.
- Steps:
- Navigate to System Tools > Integration > Registrations and click New.
- Provide the following information:
- Client Name
- Description
- Client Secret
- Redirect URL: External URL with pagehook tokens.
- Notes:
- To retrieve a REST API access token, you’ll need the Client ID and Client Secret.
- If no API call is needed, Client ID and Secret are not required.
Adding a Button Pagehook
Button pagehooks can be displayed on specific pages in the Aprimo UI, with placement and limits varying by page.
Supported Pages and Limits:
- Activity Details View (Page ID 2200): Up to 5 buttons.
- Commitment Details View (Page IDs 2123 and 2000): Up to 5 buttons.
- Project Details View (Page ID 12093): Up to 5 buttons.
- Invoices (Page IDs 2153 and 2134): Up to 5 buttons.
- Task Inbox:
- 2 pagehooks = Buttons.
- More than 2 = Dropdown titled "ACTIONS" (up to 5 links).
- System Tools: Up to 10 links under the "Other Links" section.
Steps to Create:
- Navigate to System Administration > System Tools > Navigation Settings > Pagehooks.
- Click New and provide the following information:
- Button display text (20-character limit).
- Button hover text.
- Select the page for display (view mode only; edit mode not supported).
- Button/link sequence (respect page limits).
- URL (with or without pagehook tokens).
- Example with tokens:
https://[externalsite].com?aprimo_registration_id=83 - Example without tokens:
https://my.aprimoexternalapp.com/?Action=MassImportAssets
- Example with tokens:
- Status (Active or Inactive).
- For task page pagehooks:
- Use the "Configure by Task" option to display pagehooks on specific workflow steps.
- Configure the pagehooks in the Workflow Designer under the step details tab.
Adding a Navigation Item Pagehook
Navigation item pagehooks reside in the application navigation bar.
Steps to Configure:
- Create an integration registration.
- Configure a navigation item to point to:
https://[externalsite].com?aprimo_registration_id=83
(Replace83with your integration registration ID). - When clicked, the user is briefly redirected to
https://[externalsite].com, the URL is populated with tokens, and the user is redirected to the final URL.
Adding a URL Report Pagehook
URL Report pagehooks function like navigation item pagehooks but are limited to reports launched from the Aprimo main application (not supported in the Portal).
Steps to Configure:
- Point the URL report to:
https://[externalsite].com?aprimo_registration_id=83
(Replace83with your integration registration ID). - The report iframe will redirect to
https://[externalsite].com, populate tokens, and load the external application. - Note: External applications must support being framed in an iframe.
Important: Ensure the /Aprimo/ path uses a capital "A" in the URL.
Leveraging Contextual Pagehook Tokens
Button pagehooks can use contextual pagehook tokens to help your external application understand the user's context within Aprimo. This is achieved by using query string parameters from the current page as tokens in your callback URL.
Example: Activity View Page Tokens
-
Query String Parameters:
ID: Represents the Aprimo Activity ID.PageID: Represents the Aprimo page.
-
Callback URL Example:
- Configured URL:
https://my.aprimoexternalapp.com/?Page={{PageID}}&ID={{ID}} - Resulting Redirect:
A user on the Activity View page for activity ID1001clicking the button would be sent to:
https://my.aprimoexternalapp.com/?Page=2200&ID=1001
- Configured URL:
-
Tokens in URL Segments:
- Configured URL:
https://my.aprimoexternalapp.com/Activities/{{ID}} - Resulting Redirect:
https://my.aprimoexternalapp.com/Activities/1001
- Configured URL:
Contextual Pagehook Token Options
| Page | Available Tokens |
|---|---|
| All Objects | ID, login_id |
| Activity Details | PageID |
| Activity Attachment | PageID, ObjectTypeID, ObjectID, ContextObjectID |
| Activity Proposal | Tab, PageID |
| Commitments | None unique |
| Project Details | ActivityID |
| Program Proposal | None unique |
| Program Details | None unique |
| System Tools | None unique |
| Task Inbox | ID (exists but not shown in query parameters), Status (task status ID), taskName (task name) |
| Invoices | None unique |
How to View Page Query String Parameters
To identify the query string parameters available on a page, refer to the tokens listed for the corresponding page above.