Skip to content

Conversation

@vhudlikar
Copy link
Contributor

Utility - Generate Record Link

Business Problem:
Manually building record links in email notifications is error-prone, especially when handling different portals (Service Portal, Employee Center, Service Operations Workspace). This action provides a universal, validated link.

This is a custom action. It will use a Script Step to build and return a fully qualified URL and an HTML link based on the record's details and the desired interface type.

  • Input Parameters:

    • Record Sys ID
    • Target Table
    • Link Text
    • URL Type
  • Output Parmeters:

    • Raw URL
    • HTML Link
  • Flow Usage

    • This action is called just before any Send Email or Send Notification action. The Flow then uses the Link HTML output directly in the email body, eliminating the need for email scripts and making the email content look professional.

-Testing

  • This action has been tested and validated.
Test Case Objective Input: Link Text (Record Number) Input: Record Sys ID Input: Target Table Input: URL Type Expected Output: HTML Link Expected Output: Raw URL
TC-12.1 Validate Agent Workspace URL generation. INC001 XXX incident workspace <a href="https://devxxx.service-now.com/now/sow/record/incident/xxxx" target="_blank">INC001</a> https://devxxx.service-now.com/now/sow/record/incident/xxx
TC-12.2 Validate Platform UI URL generation. INC001 XXX incident platform <a href="https://xxx.service-now.com/nav_to.do?uri=incident.do?sys_id=xxx" target="_blank">INC001</a> https://devxxx.service-now.com/nav_to.do?uri=incident.do?sys_id=xxx
TC-12.3 Validate Portal (Standard) URL generation. INC001 XXX incident portal <a href="https://devxxx.service-now.com/sp?sys_id=xxx&view=sp&id=ticket&table=incident" target="_blank">INC001</a> https://devxx.service-now.com/sp?sys_id=xxx&view=sp&id=ticket&table=incident

…n a fully qualified URL and an HTML link based on the record's details and the desired interface type.
@github-actions
Copy link

github-actions bot commented Oct 5, 2025

Valid PR for ActionPack

Thank you for your contribution. This PR complies with the CONTRIBUTING.md.
A maintainer will review this shortly. In the meantime, Happy Hacking!

@ivan-betev ivan-betev self-assigned this Oct 5, 2025
@ivan-betev
Copy link
Contributor

Looks good to me. Thank you for your contribution.

@ivan-betev ivan-betev merged commit 7a8767e into ServiceNowDevProgram:main Oct 5, 2025
@Lacah Lacah mentioned this pull request Oct 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants