Articles in this section

Response mapping, results mapping, and failed record flow behavior

Response mapping

You can add response mappings to capture data returned from an import within your flow. For flows that have multiple imports, response mappings allow you to insert the response data of an import back into your source record so that you can reference that data in subsequent steps of your flow. For example, if an application automatically assigns customer IDs to newly imported customers, and the assigned customer IDs are included in the response, you can add those field values to the source record for use in future steps.

Follow the steps below to configure response mapping:

  • Click + on the import step, and click the mappings (Edit mappings ) button on the right.

respMap.png
  • The field mappings you define will be added as new fields or replace existing fields if those fields already exist in the source record. Use the Import response field drop-down list in the Edit response mapping panel to select the fields from the response you want to map back to the source record.

Response_mapping_dropdown.png
  • id: the ID of the record just imported.

  • errors: any errors from the record that was processed in this step.

  • ignored: a Boolean true or false. The value is true if the record processed through this step was ignored. Otherwise the value is false.

  • statusCode: the status code that resulted from processing the record through this step.

  • _json: returns the full JSON formatted response of the import. For example,when importing customers into Shopify, Shopify might return the customer record that was created in their system as part of the response, and that customer record might include an automatically-assigned sales representative ID. You can use _json to retrieve the sales representative ID.

  • dataURI: when possible, this returns the link to the data that was created or updated by the import.

  • headers : the header values of the response.

  1. Enter the Source record field at the right to hold the data that will be merged back into the source record for use later on in the flow. New fields will be added to the source record unless you specify an existing field. If you use a field that already exists in the source record, it will be overwritten.

  2. Click Save & close.

Results mapping

Results mapping is similar to response mapping, but instead of returning the response after an import, results mapping allows you to merge the resulting records returned by a lookup step in your flow back into the source record. The returned lookup records can then be used in steps later on in the flow.

To configure results mapping,

  • Click + on the lookup step, and click the mappings (Edit mappings) button on the right.

greenhouseLookup.png
  • The field mappings you define will be added as new fields or replace existing fields if those fields already exist in the source record. Click in the Lookup response field in the Edit results mapping panel to select the fields from the response you want to map back to the source record.

resultsMapping.png
  • data: the records returned by the lookup step.

  • errors: any errors from the record that was processed in this step.

  • ignored: a Boolean true or false. The value is true if the record processed through this step was ignored. Otherwise the value is false.

  • statusCode : the status code that resulted from processing the record through this step.

  • dataURI: when possible, this returns the link to the data that was gathered by the lookup.

  1. Choose a field in the Source record field on the right to hold the data that will be merged back into the source record for use later on in the flow. New fields will be added to the source record unless you specify an existing field. If you use a field that already exists in the source record, it will be overwritten.

  2. Click Save & close.

Failed record flow behavior

If you have multiple destination flow steps in your flow, you can configure the way that each intermediate destination step handles failed records.

13888485172763-failBehavior.png

Click failed_records_option.svg to define the way that failed records will be handled by an intermediate destination flow step.

19964051699483-Proceed.png

Pause here until someone can fix the error

When a record causes an error, by default, the Pause here until someone can fix the error option is selected to stop the flow from sending the failed record to any subsequent flow steps until the error is fixed. The failed record will be held here so that you can fix and retry it. Upon a successful retry, the record will then proceed to any additional flow steps.

Proceed to the next application regardless

Click Proceed to the next application regardless to push records that contain errors to subsequent flow steps regardless of whether or not the record produces an error during this flow step. The failed record can still be fixed and retried for this flow step, but if it didn't fail on any additional flow steps, it won't be pushed to those additional steps upon successful retry. This is the preferred choice if, for example in NetSuite use cases, you are sending inventory update records to multiple webstores or marketplaces. If the record fails on this step, you might still want that record to proceed to any subsequent steps in the flow so that the other stores and marketplaces can get the update.

Take the following class to learn more about this topic:

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

Comments

0 comments

Please sign in to leave a comment.