Create a transform in Service Exchange for Providers (legacy)

  • Release version: Washingtondc
  • Updated February 1, 2024
  • 1 minute to read
  • As a provider, create a transform in the Service Exchange for Providers application so that you can integrate tasks between a ServiceNow instance with your customer's instance.

    Before you begin

    Role required: admin

    Procedure

    1. Navigate to Service Bridge > Provider > Transforms.
    2. Click New.
    3. On the form, fill in the fields.
      Table 1. Transform form
      Field Description
      Number Auto-generated number for the transform record.
      Account Customer name for whom this transform is applicable.
      Type

      Simple: Used when the field has a known and stable choice list on each instance. A related list of transform lines is created to match the inbound and outbound values.

      Advanced: Used for complex criteria that requires a script to determine the new value.

      Inbound Option that enables an inbound transformation for this transform.
      Outbound Option that enables an outbound transformation for this transform.
      Provider table Option that designates the provider's task table. For example, Case.
      Provider field Option that designates the provider's field. For example, State.
      Customer table Option that designates the customer's task table. For example, Incident.
      Customer field Option that designates the customer's field. For example, State.
    4. Click Save.
    5. Select either Simple or Advanced.
      If you selected Simple, go to step 5a next. If you selected Advanced, go to step 5b next.
      1. If you selected Simple, click New in the Transform lines related list, and fill in the fields on the form.
        Table 2. Transform lines form
        Field Description
        Provider label Option that designates the provider's choice label. For example, Open.
        Provider value Option that designates the provider's choice value. For example, 10.
        Customer label Option that designates the customer's choice label. For example, Progress.
        Customer value Option that designates the customer's choice value. For example, 2.
      2. Click Submit.
      1. If you selected Advanced, use a script to define the outbound and inbound labels and values as shown in the following example:
        output.value=input.value;
        output.label=input.label;
        
        var ci=new GlideRecord('cmdb_ci');
        
        if(direction=='inbound'){
           if(ci.get('correlation_id',input.value)){
              output.value=ci.sys_id+";
              output.label=ci.getDisplayValue();
              }
        }
        if (direction=='outbound'){
          if(ci.get(input.value)){
             if(ci.correlation_id){
                output.value=ci.correlation_id+";
                output.label=input.label;
               }
            }
        }
              
        
      2. Click Submit.
    1. On the transform form, click Activate.

    Result

    A transform record is created on your ServiceNow® instance. Any Remote Task's inbound or outbound fields that match a transform will automatically use them. To learn more, see Create remote task definitions in Service Exchange for Providers (legacy).