The ability to navigate back to the corresponding Vault file from a Fusion Lifecycle item can save time. Vault offers a possibility to generate a link that points to a file in Vault. A link can then be added to a URL field on a Fusion Lifecycle item.

Getting the hyperlink to a file

To build the link in PowerShell some Vault information and the path to the file is required

Import-Module powerVault
$file = Get-VaultFile -Properties @{Name="Jet Engine Model.iam"}

$vaultName = $vaultConnection.Vault
$vaultServer = $vaultConnection.Server
$fullPath = $file._FullPath

After the information is gathered the link can be built using the variables from above and then encoded using the HttpUtility.UrlEncode Method

$link = "http://$($vaultServer)/AutodeskDM/Services/EntityDataCommandRequest.aspx?Vault=$($vaultName)&ObjectId=$($fullPath)&ObjectType=File&Command=Select"

$encodedLink = [System.Web.HttpUtility]::UrlEncode($link)

Adding the hyperlink to Fusion Lifecycle

Using the powerFLC cmdlets you can add the encoded link to an URL field in Fusion Lifecycle:

Import-Module powerFLC
Connect-FLC -Tenant 'your_tenant_name' -ClientId 'your_client_id' -ClientSecret 'your_client_secret' -UserId ''

Add-FLCItem -Workspace "Your_Workspace" -Properties @{
    "Number" = $file.'Part Number'
    "Description" = $file.Description
    "link" = $encodedLink

When clicking on the hyperlink in Fusion Lifecycle a file is downloaded that opens a Vault Client and automatically navigates to the corresponding file.

Make sure that in the workspace settings the "FieldĀ length" value for the URL field is long enough for the link otherwise it will be cut to the maximum length and the link will break!

This builds the same link as "Copy Hyperlink" in the Vault client.

See Also

HttpUtility.UrlEncode (Microsoft docs)

Copy Hyperlink (Autodesk Knowledge Network)

powerFLC cmdlets (coolOrange wiki)

powerVault cmdlets (coolOrange wiki)