Can I add a website hyperlink into a provisioning form?

Hello everyone,

I am currently working on a project using Sailpoint (Version 8.3p3) and I have been asked to include an HTML web link in a provisioning form. I would like to know if this is possible and, if so, how it can be achieved.

Has anyone done this before or can provide guidance on the steps involved? Any examples or documentation references would be greatly appreciated.

Thank you in advance for your help!

Best regards,
Ashley Sneddon

You can do that like this

<Section name="Information" type="text">
    <Field name="Information" type="string">
      <Attributes>
        <Map>
          <entry key="contentIsEscaped" value="true"/>
          <entry key="readOnly" value="true"/>
        </Map>
      </Attributes>
      <Script>
        <Source>
                                String msg = ""Some Text" 

                                String linkEN = "&lt;a href=\"your url\" target=\"_blank\">EN&lt;/a>";

                                String linkDE = "&lt;a href=\"your url\" target=\"_blank\">DE&lt;/a>.";

                                return msg + linkEN + " or " + linkDE;</Source>
      </Script>
    </Field>
  </Section>

Hi Kamil,

Thank you for your response.

I used your suggested script and made some amendments. However, as shown in the attached screenshot, I am getting a string of text and the link is not selectable.

<Field name="Information" type="string">
      <Attributes>
        <Map>
          <entry key="contentIsEscaped" value="true"/>
          <entry key="readOnly" value="true"/>
        </Map>
      </Attributes>
      <Script>
        <Source>
        String msg = "Please click on the link and read the relevant section before accepting:";  

        String linkEN = "&lt;a href=\"https://www.google.com\" target=\"_blank\">EN&lt;/a>";

        return msg + linkEN;
      </Source>
      </Script>
    </Field>

Am I making a mistake?

You can try like below

 <Section name="externalLink" type="text">
    <Field name="Information">
      <Attributes>
        <Map>
          <entry key="contentIsEscaped" value="true"/>
        </Map>
      </Attributes>
      <Script>
        <Source>
		StringBuilder sb = new StringBuilder();
		sb.append("Please click on the link and read the relevant section before accepting:");
		sb.append("&lt;a href=\"https://www.google.com\" target=\"_blank\">EN&lt;/a>");
		
        return sb.toString();
      </Source>
      </Script>
    </Field>
  </Section>

Try something like this .

 <Section name="My HTML Section" type="text">
    <Field filterString="htmlRender" type="text">
          <Attributes>
        <Map>
          <entry key="contentIsEscaped" value="true"/>
        </Map>
      </Attributes>
      <Script>
        <Source>
          return  "Google  &lt;a href=\"https://google.com/" target=\"_blank\">Click here&lt;/a>";
        </Source>
      </Script>
    </Field>
  </Section>

Hi Deepak,

Thank you for your response.

After adding the amended code, I am still getting a string of text, and the link is not selectable. However, the difference is that the text box is now editable, whereas the previous one was not.

1 Like

Hi Vishal,

This code results in a error:
sailpoint.tools.GeneralException: sailpoint.tools.GeneralException: BeanShell script error: bsh.ParseException: Parse error at line 1, column 49. Encountered: target BSF info: script at line: 0 column: columnNo

1 Like

check this one

  <Section name="My HTML Section" type="text">
    <Field filterString="htmlRender" type="text">
      <Attributes>
        <Map>
          <entry key="contentIsEscaped" value="true"/>
        </Map>
      </Attributes>
      <Script>
        <Source>
          return  "Okta SSO Group Naming format  &lt;a href=\"https://google.com\" target=\"_blank\">Click here&lt;/a>";
        </Source>
      </Script>
    </Field>
  </Section>

Can you copy whole code, I mean from Section tag itself. I have tested in my local and working fine.

Hi, here is the provisioning form script I’m trying to update:

  <ProvisioningForms>
    <Form name="Test Form">
      <ApplicationRef>
        <Reference class="sailpoint.object.Application" id="8ae18a975ff9abb801600c3be6a60b03" name="approverOnly"/>
      </ApplicationRef>
      <Attributes>
        <Map>
          <entry key="pageTitle" value="Test Form"/>
        </Map>
      </Attributes>
      <Description>Test Form</Description>
      <Section name="externalLink" type="text">
        <Field displayName="Link" displayOnly="true" displayType="textarea" name="information" reviewRequired="true">
          <Attributes>
            <Map>
              <entry key="contentIsEscaped" value="true"/>
            </Map>
          </Attributes>
          <Script>
            <Source>
              StringBuilder sb = new StringBuilder();
              sb.append("Please click on the link and read the relevant section before accepting:");
              sb.append("&lt;a href=\"https://www.google.com\" target=\"_blank\">EN&lt;/a>");

              return sb.toString();
            </Source>
          </Script>
        </Field>
      </Section>
      <Section name="agreement">
        <Field displayType="radio" helpKey="Acknowledgement is required for the request to proceed." name="Link Review Acknowledgement" required="true" reviewRequired="true" type="string">
          <AllowedValues>
            <String>I agree to the details provided.</String>
          </AllowedValues>
        </Field>
      </Section>
    </Form>
  </ProvisioningForms>

Hello @vedeepak,
Is the script I provided similar to the one you tested?

Hello @acgsneddon,

Sorry, I totally forgot this. It appears there is an issue with the “provisioning form”. Seems like it is only accepting input fields, and the labels/text are not getting rendered correctly. Earlier I was testing this in normal forms, and it was working as expected.

Hello @vedeepak,
Thank you for bringing this to my attention. I am trying to add the suggested text to a form object. Could you please advise which object can be updated to correctly display the hyperlink? Is this functionality limited to a provisioning form added to a bundle object?

Actually you can’t add the link in the Provisioning form , but the same can be added in the normal form .

Hello @vishal_kejriwal1,
I have used the suggested script and updated a form, but am getting the same result.

Good morning @vishal_kejriwal1,
It doesn’t appear to have worked, as it only display an empty text box:
image

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.