Mappings

  • Updated

Overview

There are optional field mappings available in the PayPack configuration. In some scenarios, a transaction may require a specific field to populate such as field ID class. By entering metadata in JSON format, you are able to satisfy the requirement.

There are currently 2 custom field mapping fields available.

  1. Customer Deposit Field Mapping
  2. Customer Payment Field Mapping

Custom_Field_Mapping.png

Sample JSON data for Field Mapping

Customer Deposit / Payment Field Mapping

{
  "lookups": {},
  "mapping": {
    "fields": [      
      {
        "generate": "undepfunds",
        "hardCodedValue": "T",
        "fieldtype": "",
        "discardIfEmpty": false
      },
      {
        "generate": "paymentmethod",
        "hardCodedValue": 10,
        "fieldtype": "",
        "discardIfEmpty": false
      },
      {
        "generate": "memo",
        "extract": "charges.data.0.balance_transaction",
        "discardIfEmpty": true,
        "fieldType": "text"
      }
    ]
  }
}

Transaction Currency-Specific Account Mapping

The JSON example below uses Stripe's API response currency value to select a NetSuite bank account based on USD or CAD.

{
  "lookups": {
    "accountlookup": {
      "map": {
        "usd": "1001 Stripe USD Bank Account",
        "cad": "2001 Stripe CAD Bank Account"
      }
    }
  },
  "mapping": {
    "fields": [      
      {
        "generate": "account",
        "extract": "currency",
        "discardIfEmpty": true,
        "fieldType": "text",
        "lookupName": "accountlookup"
      }    
    ]
  }
}

Date Format Function with Join String

Enhance your PayPack configuration with the ability to add date and time values using our mapping fields feature. This functionality allows you to effortlessly incorporate various date and time formats into your NetSuite fields by simply adding key-value pairs to the provided JSON data sample.

For detailed instructions, read the documentation PayPack - Mappings - Date Format Function with Join String.