Spreadsheet Muncher: Configuring a Template

Follow the instructions to install the Nexus connector first:  Nexus connector instructions

Once you have downloaded the IOLITE Spreadsheet Muncher Connector from the Connector Hub, use this guide to configure the Nexus functions for setting up Spreadsheet Muncher.

Configuring the Spreadsheet Muncher Connector to create a Template.

Each spreadsheet that you need to create a template for will require a new Connector setup.  This is because each spreadsheet will have it's own mapping.  

Select the Spreadsheet Muncher Connector from the Nexus Admin page.  Choose the View Connector Functions option.

Once you have selected the Connector Functions, you will see previously created Templates (if applicable).  In order to create a new Template function, choose the Create Function option:

When you choose this option - you will see the API Function Name with a dropdown to allow for selection.  Any previous Template that you've created will be available in this dropdown.  There is also an option called "Configure".  When creating a new Template - select the "Configure" option.  If you are modifying a previous Template - then select that Template name.

Once you select the Configure option - you'll have the option to upload your Template spreadsheet

Uploading your Spreadsheet Template.

When you are uploading your spreadsheet to create a template, there are a few requirements you'll need to meet. 

  • The Spreadsheet you are uploading must have column headings in the first row of the spreadsheet.  We are assuming that these column headings are the names of the data elements that you will be mapping later.  You should review your column headings for accuracy and meaning before uploading the spreadsheet template.
  • Remove the data from the remaining lines of the spreadsheet.  While this isn't technically a requirement, it will make the process happen much faster.  In the upload phase - we're only looking at the first row of data, however, if we are reading a spreadsheet with multiple thousands of rows of additional data - this adds unnecessary time to this step.
  • The Spreadsheet only contains 1 tab.  
  • The Spreadsheet is not protected.  Password protected sheets are not readable
  • The Spreadsheet does not have macros or other special functions that would interfere with the processing of the sheet.
  • The Spreadsheet is either type xlsx or csv

Once you have met these requirements - use the file upload component to upload your Template headers.

Select which Tab your data is located on (the default is Tab 0 - which is the first tab).  Only change this if your spreadsheet data has multiple tabs - and your required data is NOT on the first tab.

Be sure to hit "Save" after uploading your file

Map your Data Events.

Once you have uploaded your Spreadsheet, the system will create one data event for every spreadsheet column name.  The Data Events will be listed under the template name which was uploaded.  

Select the View Data Events option from the menu next to the Template that you just created.

Select the Record Details menu option

Update the mapping for each column using the options to add Objects and then map the fields accordingly (this example uses the Contact object):

For DML Type, Edit DML Type to be either Insert, Upsert, or Reference Only. 

 

Create an Email Service.

Once you have completed the mapping, you can define an Email Service.  This Email Service will include an Email Address that can be used to email a spreadsheet as an attachment.  This email address can be used as is, or you can also create a forwarding alias in your email server which can enable a more "friendly" email address which then forwards to this Salesforce Email Service Address.

To create this email address, navigate to Setup and select Email Services.  

 

Click on the New Email Service Button

Use the magnifying glass on the Apex Class line to look for "muncherEmailHandler".  Select this item.  Type the same name in the Email Service Name.  Select "All" for Accept Attachments.  Click the checkbox to mark the service as "Active".

Note that there are additional selections for behavior in the "Failure Response Settings" panel below this.  Review these selections and adjust as necessary.  We recommend leaving these as default, however, your situation may vary.

Click Save.

Click on New Email Address

Input your desired email address name.  Note that Salesforce will supply the 80-byte suffix to the email address.  Input the Context user that will be the best default user.  Typically this will be the Administrator's email address, or an address created to handle Admin permission functions.  Note: you can fill in the "Accept Email From" to limit who can send emails to this particular service.

Copy the email address and navigate back to the Nexus application.

This time - choose the option to Edit Connector Functions on the menu option for your template.

Paste the email address into the Email Service To Address line on the page

 

Update the remaining elements on this page by scrolling down.  Keep the Assigned Credential as Default, Update the Profile Assignments as you wish to configure the visibility, and mark the function as Active.  We recommend leaving the Batch Size at 200 - as this will be the most efficient.  However, if you are having difficulty processing large blocks of data, you can reduce the Batch Size (even down to 1 record) if needed.

 

As a final step - activate the connector on the main Nexus Admin panel:

Once you have marked the function as active, you can execute a test by attaching a spreadsheet to an email and put the Email Service email address in the To: field.  You should be able to see the records on the spreadsheet loaded according to the mapping you provided.

If you don't see results - check the debugging options outlined in the Nexus Debugging article to troubleshoot your work.

 

 

Was this article helpful?
0 out of 0 found this helpful