Updating Data via Field Mappings
A Field Mapping is an object that enables the following features:
- Insert: This feature copies a value of a Salesforce field (e.g., Street Address) into a corresponding field of a OneSpan Sign document when a transaction is being prepared. That data can then be retrieved from the signed document. The data in question can be either data about a recipient, or data about a Salesforce related object.
The relevant OneSpan Sign field must exist before you can insert a Salesforce value into it. You can create the required OneSpan Sign field by using a Text Tag.
- Writeback: This feature copies a value of a OneSpan Sign field (e.g., Street Address) into a corresponding Salesforce field. Using it, data entered by recipients during the Signer Experience can be written back into Salesforce fields, based on Field Mappings defined when the transaction is completed.
The Writeback feature is disabled by default. The Writeback feature cannot operate unless the Insert option is enabled.
The rest of this section describes:
- Inserting Salesforce Recipient Data into OneSpan Sign Fields
- Inserting Salesforce Related-Object Data into OneSpan Sign Fields
- Updating Salesforce Fields with OneSpan Sign Data (Writeback)
Inserting Salesforce Recipient Data into OneSpan Sign Fields
The following procedure illustrates how to insert into OneSpan Sign documents Salesforce data from a recipient's record (e.g., data about a Salesforce user, contact, or lead).
In particular, it describes how to insert into a OneSpan Sign transaction the address of a Salesforce contact who is also a recipient.
To insert a Salesforce contact’s address into a OneSpan Sign transaction:
Creating a Convention
- Click the Conventions tab.
- Click New.
- Enter a name for the new Convention, and click Save.
Creating a Field Mapping
- On the Field Mapping related list, click New Field Mapping, and give a name to the mapping.
- In the Mapping Type drop-down list, select Recipient.
- In the OneSpan Sign Document Field Reference section, give the OneSpan Sign field name.
- In the Salesforce Object Field Reference section, click Add new.
- Choose the desired object. In this case, the object is Contact. A list of the contact’s fields appears on the right.
- Choose the field to be mapped to a OneSpan Sign field (e.g., the contact's City), and then click Add.
- Click Save to save the Field Mapping.
- Repeat Steps 4-10 to create a new Field Mapping for each address field (City, Zip Code, etc.).
Ensure that the Insert option is checked when the field is added. This will enable the system to insert data from the Salesforce object’s field into the OneSpan Sign documents. If you are using custom fields, the fields that you create must be accessible (for insert), and editable (for writeback). As such, ensure that your users have the proper access as needed.
Creating a Transaction and Inserting Salesforce Data into It
- Create a OneSpan Sign transaction (giving it a name), and then click the Advanced Options tab.
- On the OneSpan Sign Convention section, click Lookup and choose the Convention created above.
- Click the Details tab.
- Add documents to the transaction, and add the contact as a recipient.
- Click Prepare. The Designer appears in a dialog box.
- Add a Signature Block for the contact.
- To display more options, click the gear icon on the right side of the Signature Block. Then click the + sign to add fields. The list of available fields appears.
- Click text field to add a text field.
- To display more options, click the gear icon on the right side of the text field. Then click Settings to see the field settings.
- Give a name to the Convention Field Names, which are displayed on the left side of the Designer. Then click Save.
- Repeat Steps 19-22 for each of the Convention's fields.
- When finished, close the overlay and click Send.
The transaction will be sent. When the transaction is complete, its signed documents should contain the contact's address. Thanks to this procedure, that address in OneSpan Sign documents will have been inserted directly from Salesforce.
Inserting Salesforce Related-Object Data into OneSpan Sign Fields
The following procedure illustrates how to insert into OneSpan Sign documents Salesforce data from a record linked to a OneSpan Sign transaction object.
In particular, it describes how to insert an address from an Account record into a OneSpan Sign transaction .
To insert a Salesforce Account’s address into a OneSpan Sign transaction:
Creating a Convention
- Click the Conventions tab.
- Click New.
- Enter a name for the new Convention, and then click Save.
Creating a Field Mapping
- On the Field Mapping related list, click New Field Mapping, and give a name to the mapping.
- In the Mapping Type drop-down list, select Related object.
- In the OneSpan Sign document field reference section, give the OneSpan Sign field name.
- In the Salesforce Object Field Reference section, click Add New.
- Choose the desired object. In this case, the object is Account. A list of the Account’s fields appears to the right.
- Choose the field to be mapped (e.g., the Account's City), and then click Add.
- Click Save to save the Field Mapping.
- Repeat Steps 4-10 to create a new Field Mapping for each address field (City, Zip Code, etc.).
Ensure that the Insert option is checked when the field is added. This will enable the system to insert data from the Salesforce object’s field into the OneSpan Sign documents. If you are using custom fields, the fields that you create must be accessible (for insert), and editable (for writeback). As such, ensure that your users have the proper access as needed.
Creating a Transaction and Inserting Salesforce Data into It
- Create a OneSpan Sign transaction (giving it a name), and click the Advanced Options tab.
- On the Conventions field, click Lookup and choose the Convention created above.
- Click the Details tab.
- From the Related object type drop-down menu, choose Account (if it is not already selected).
- Click Lookup to choose the Account record.
- Add documents to the transaction, and add recipients to the transaction.
- Click Prepare. The Designer page appears. Add your Signature Blocks.
- To display more options, click the gear icon on the right side of the Signature Block. Then click the + sign to add fields.
- Click Settings to see the field settings. The list of available fields appears.
- Click Text Field to add a text field.
- To display more options, click the gear icon on the right side of the text field.
- Type the name of the desired Convention field name. These field names are displayed on the left side of the overlay. Then click Save.
- Repeat Steps 19-23 for each Convention field.
- Close the Designer. Then click Send to send the transaction. When the transaction is complete, its signed documents should contain the Account's address. With this procedure, the address will be inserted into OneSpan Sign documents directly from Salesforce.
Updating Salesforce Fields with OneSpan Sign Data (Writeback)
A Field Mapping's Writeback feature can update data in Salesforce fields from OneSpan Sign documents.
For example, suppose that: (1) a recipient notices during the Signer Experience that his address is wrong in a OneSpan Sign transaction document; (2) the recipient corrects his address in that document.
If that OneSpan Sign address is mapped to a field of a Salesforce related object, and the Writeback option has been checked for that mapping, when the OneSpan Sign transaction is complete, the updated address will be written into the Salesforce field.
The data to be written back into Salesforce must be entered during the Signer Experience.
To update a Salesforce field with data from a OneSpan Sign document when the associated transaction is completed:
- Select the Writeback option for the associated Field Mapping.
- When the OneSpan Sign transaction is complete, verify that the data updated during the Signer Experience appears in the associated Salesforce field.