NetSuite - Payout reconciliation
Payments collected on a given day are grouped together and settled in one lump sum, minus fees. The GoCardless for NetSuite integration retrieves the details of the lump sum payout and the associated transactions (payout items), and reconciles this data within NetSuite.
Payout Reconciliation record
A custom Payout Reconciliation record is created in NetSuite to store the data for each GoCardless payout. These records can be found under GoCardless > Payouts > Payout Reconciliation.
A script runs every 30 minutes to process this data, and generate a linked deposit record (to reconcile the payout items) and journal entry (to reconcile the fees). The following details are populated on the Payout Reconciliation page:
| Field | Description | Editable? |
|---|---|---|
| Reconciliation ID | The GoCardless payout ID | N |
| Bank Deposit | A link to the related Deposit which is used to reconcile the GoCardless payout items. This will be populated once the "Status" of the Payout Reconciliation record transitions to "processed". | N |
| Journal entry | A link to the related Journal Entry which is used to reconcile the GoCardless fees that were deducted from the payout. This will be populated once the "Status" of the Payout Reconciliation record transitions to "processed". | N |
| GoCardless fees | The total fee amount that was deducted from the payout in the local collection currency | N |
| Payout currency | The local collection currency for the payout | N |
| FX currency | The currency in which amounts were paid out (after foreign exchange). Only applicable when collecting payments in one currency and being paid out in another using the GoCardless FX feature. | N |
| Payout amount | The net payout amount (gross amount minus fees) in the local collection currency | N |
| Reference | The reference of the GoCardless payout that's displayed on the payout bank statement | N |
| Payout data object | The JSON of the GoCardless payout (i.e. the lump sum payout details). This includes the GoCardless FX rate that’s applicable when collecting payments in one currency and being paid out in another via the GoCardless FX feature. | N |
| Payout items object | The JSON of the GoCardless payout items (the details of the transactions that contributed to the lump sum payout amount) | N |
| Status | When a payout is marked as "paid" in GoCardless, a corresponding Payout Reconciliation record will be created in NetSuite. The status will be one of the following: Pending: the script to create the Deposit record and Journal Entry for the payout has not yet processed Processed: the script to create the Deposit record and Journal Entry for the payout has been processed. These should now be linked on the Payout Reconciliation record. Failed: the script to create the Deposit record and Journal Entry for the payout failed to process. The related error message will be displayed in the "Error message" field. The script to process the payout reconciliation data runs on 30 min intervals. The script will process payout reconciliation records that have a pending status or a processed status without a linked deposit. |
Y |
| Error message | When this "Status" field is set to "failed", the error message will be displayed in this field. | N |
Fees Journal Entry creation
The payout reconciliation script uses the summed amount of all fees per payout, and books a journal entry representing the fees with the following information:
| Field | Description | Editable? |
|---|---|---|
| Document Status | Set to Approved for Posting | N |
| Currency | The currency the fees were settled in. When using the GoCardless FX feature, this will be the FX currency from the Payout Reconciliation object. |
Y |
| Exchange Rate | The FX rate to convert the Currency (see above) to the base currency of the subsidiary. Daily exchange rates are defaulted and can be adjusted under Lists > Accounting > Currency Exchange Rates. | Y |
| Memo | States the ID of the related GoCardless payout | Y |
| Subsidiary | Subsidiary for which the bank account is set | Y |
| Lines > Debit/Credit Amounts | The amounts on the Lines tab reflect the total fees amount deducted from the payout. When the GoCardless FX feature is used, these amounts will be converted to the payout's FX currency (displayed in the Currency field). |
Y |
| GL impact > Debit + Credit Amounts | The amounts on the GL Items tab will equal the amounts on the Lines tab. If the Currency on the Journal Entry differs from the subsidiary's base currency, the "Exchange rate" from the "Primary Information" section would be applied. |
N |
| Lines + GL Impact > Account (Debit) | Sourced from GoCardless configuration record (Fees Account) | Y (Lines tab) |
| Lines + GL Impact > Account (Credit) | Sourced from GoCardless configuration record (the NetSuite bank account that’s mapped to the GoCardless payout bank account on the ‘Bank Accounts’ tab) | Y (Lines tab) |
| Department, Class, Location | Sourced from GoCardless configuration record | Y (Lines tab) |
Troubleshooting missing fees Journal Entries:
If the Payout Reconciliation record has a failed Status, you can refer to the Error Message field for information on the related error.
If fees were deducted from your payout, but the Journal Entry isn’t generated, it could be due to one of the following:
- A valid fees account is not configured on the GoCardless Configuration record - The fees journal debits the fees account specified on the GoCardless Configuration record. If this field is left blank, the journal entry creation will fail. This is a required configuration field. If there is a fees account configured, but it has been deactivated or deleted in NetSuite since setup, the journal entry creation will fail with an invalid account error.
- Closed or locked accounting period - The journal entry date is tied to the payout arrival date. A locked period on that date will prevent the journal from posting.
- Journal entries require approval before posting - The integration creates fees journal entries with a Document Status of "Approved for Posting". If your NetSuite account has a workflow or setting that overrides the default approval status on journal entries (for example, requiring a secondary approval step), the journal may be created but not posted automatically.
- Intercompany journal entry restrictions - In multi-subsidiary accounts, if the subsidiary associated with the bank account differs from the subsidiary of the fees account, NetSuite may require the journal to be structured as an intercompany journal entry. The integration creates a standard (non-intercompany) journal entry, so this could cause posting failures in accounts with strict intercompany accounting rules.
Once the core issue is pinpointed and resolved, you can reprocess the payout reconciliation record following the below steps.
- Edit the Payout Reconciliation record > set the status to Pending > Save. It will be reprocessed the next time the payout reconciliation script runs (every 30 minutes).
If you’ve ruled out the above scenarios, please export the payout reconciliation script logs and provide them to GoCardless for further troubleshooting. The steps for exporting the logs are copied below:
- Navigate to Customization → Scripting → Script Execution Logs
- Filter to the “ns_gc_process_reconciliation_mr.js” script
- Filter to the date range of the impacted payout
- Set the log level to Debug
- Use the Export button to download as CSV and share for review
Deposit creation
A deposit record is created to reconcile the payout items from GoCardless (i.e. the individual transactions that contributed to the lump sum payout amount). The deposit will book all related payment and refund records from the Undeposited Funds account to the appropriate bank account.
The following information is populated on the deposit:
| Field | Description | Editable? |
|---|---|---|
| Account | Set to the NetSuite bank account that's mapped to the related GoCardless payout bank account on the GoCardless configuration record | Y |
| Amount | The gross amount of the GoCardless payout. The GoCardless FX rate will be applied when using the GoCardless FX feature. |
Y |
| Currency | The currency the payout was settled in. When using the GoCardless FX feature, this will be the FX currency from the Payout Reconciliation object. |
N |
| Exchange Rate | The FX rate to convert the Currency (see above) to the base currency of the subsidiary | Y |
| Date | The arrival_date of the related GoCardless payout | Y |
| Memo | The ID of the related GoCardless payout | Y |
| Subsidiary | Subsidiary for which the bank account is set | N |
| Deposits tab | The linked payment and refund records that correspond to the GoCardless payout items | Y |
| Deposits > Amount | The amounts on the Deposits tab reflect the amounts of the related transactions (payments or refunds). When the GoCardless FX feature is used, these amounts will be converted to the payout's FX currency (displayed in the Currency field). |
Y |
| GL Impact > Amount | The amounts on the GL Items tab will equal the amounts on the Deposits tab. If the Currency on the Deposit differs from the subsidiary's base currency, the "Exchange rate" would be applied. |
N |
| GL Impact > Account (Debit) | Undeposited funds | N |
| GL Impact > Account (Credit) | Sourced from GoCardless configuration record (the NetSuite bank account that’s mapped to the GoCardless payout bank account on the ‘Bank Accounts’ tab) | N |
In case of any exchange rate discrepancies between the deposit record and the related payments and refunds, NetSuite will automatically book an adjusting journal on the bank deposit level. This will impact the Undeposited Funds account, using the Unrealized Matching Gain/Loss account as a contra. Therefore, no adjustment journals need to be created by the integration.
Troubleshooting missing Deposits:
If the Payout Reconciliation record has a failed Status, you can refer to the Error Message field for information on the related error.
If the Deposit isn’t generated for your Payout Reconciliation record, it could be due to one of the following:
-
Payments not found by script
- The related Customer Payment records do not exist - this could be due to the payout only containing payments that were created outside of the integration, or there was an upstream issue with creating the Customer Payments in NetSuite (see the NetSuite - Payment creation & events page for more details on what could cause this). Once the Customer Payments exist in NetSuite, the payout will be automatically reprocessed the next time the script runs (every 30 minutes).
- The related Customer Payment records do exist, but they were created after the Payout Reconciliation record was processed - this could be due to a delay in the payment paid_out webhook events causing the payments to be created after the payout was originally processed. When this is the case, the reconciliation script runs every 30 minutes and will automatically reprocess the payout, which should result in the deposit being generated on the next run.
- The related Customer Payment records are already deposited - The integration filters for payments in "Not Deposited" status before creating the deposit. If a payment has already been manually deposited before the payout reconciliation runs, the deposit creation step will skip it, which could result in an incomplete or missing deposit for that payout.
- >10,000 undeposited records - If you have more than 10,000 undeposited records returned in the deposit sublist, NetSuite will only give the payout reconciliation script access to the first 10,000. If the GoCardless payments fall outside of this initial set, they will not be visible for selection by the script. Payments will have to be manually deposited in this scenario.
-
Payout bank account mapping issue
- The GoCardless payout bank account ID is not mapped to a NetSuite bank account - The payout reconciliation deposit is posted to the NetSuite bank account that is mapped to the corresponding GoCardless payout bank account in the GoCardless Configuration record. If this mapping is not set up correctly, reconciliation will fail for those payouts (see the NetSuite - Connection & setup page for more details). Once the bank account mapping is resolved, you can reprocess the payout reconciliation record by setting its status back to pending following the steps below to resolve this.
- The bank account mapped in the GoCardless Configuration record doesn't match the subsidiary of the payments being deposited - The Deposit record is created using the bank account that is mapped to the GoCardless payout bank account in the Configuration record. In a multi-subsidiary environment, if the bank account belongs to a different subsidiary than the payment records being deposited, the payments won’t be available for selection on the Deposit. Once the bank account mapping is resolved, you can reprocess the payout reconciliation record by setting its status back to pending following the steps below to resolve this.
- Closed accounting periods - The deposit date is set to the GoCardless payout arrival_date. If that date falls within a locked period, the deposit creation will fail. If the account period is re-opened, you can reprocess the payout reconciliation record following the steps below to resolve this.
- (FX payouts) No currency exchange rates configured in NetSuite - For FX payouts (where the payments were collected in one currency and paid out in another via the GoCardless FX feature), the payout reconciliation deposit creation relies on exchange rates being set in NetSuite (Lists → Accounting → Currency Exchange Rates). If exchange rates are missing for the relevant currency pair, the reconciliation records may fail to process correctly or post with incorrect values. Once the exchange rates are configured, you can reprocess the payout reconciliation record following the steps below to resolve this.
Reprocessing failed payout reconciliation records:
Once the core issue is pinpointed and resolved for failed payout reconciliation records, you can reprocess the payout reconciliation record following the below steps.
- Edit the Payout Reconciliation record > change the status to Pending > Save.
It will be reprocessed the next time the payout reconciliation script runs.
Steps to manually replicate in NetSuite:
To help identify which scenario caused the Deposit not to be generated, you can manually create a Deposit in NetSuite. This lets you see whether the associated Customer Payment records are available for selection, and if not, helps narrow down why.
- In NetSuite, navigate to Payments → Deposits → New (or equivalent in your NetSuite menu).
- Set the Account field to the NetSuite bank account that is mapped to your GoCardless payout bank account on your GoCardless Configuration record.
- Set the Date field to the arrival date of the GoCardless payout.
- Navigate to the Deposits → Payments subtab and check whether the associated Customer Payment records are available for selection.
Interpreting the results:
-
The Customer Payment records are not available for selection — this could indicate one of the following:
- The Customer Payment records do not exist in NetSuite (i.e. they were never created by the integration - (see the NetSuite - Payment creation & events page for more details on what could cause this).
- The Customer Payment records exist but have already been deposited manually.
- Multi-subsidiary: There is a mismatch between the Account selected on the Deposit and the subsidiary of the Customer Payment records. Confirm that the bank account you've selected belongs to the same subsidiary as the Customer Payments.
-
The Customer Payment records are available for selection — this suggests they existed at the time you're checking, but were likely created after the Payout Reconciliation record was originally processed. You can resolve this by reprocessing the Payout Reconciliation record following the steps below.
- Note: If you have more than 10,000 records on the Payments subtab, NetSuite will only give the payout reconciliation script access to the first 10,000. If the GoCardless payments fall outside of this initial set, they will not be visible for selection by the script.
Exporting script logs:
If you’ve ruled out the above scenarios, please export the payout reconciliation script logs and provide them to GoCardless for further troubleshooting. The steps for exporting the logs are copied below:
- Navigate to Customization → Scripting → Script Execution Logs
- Filter to the “ns_gc_process_reconciliation_mr.js” script
- Filter to the date range of the impacted payout
- Set the log level to Debug
- Use the Export button to download as CSV and share with GoCardless for review
Note: If the logs contain records with lineId=1 (lineId from Title column set to -1 in the Detail column), this means that the script couldn’t find the related Customer Payment records due to one of the causes outlined above.
Data flow - payout reconciliation