Applying Credit to an Invoice
1 min
You will need the QuickBooks Credit Note and Invoice IDs to link the two together.
To achieve this, you need to create a zero-dollar payment, which is the link between the Credit Memo and the Invoice. The Credit Memo is linked to the zero-dollar payment, which is then linked to the Invoice.
{
action=createPayment,
responseJSON={
"statusCode": 200,
"payments": [
{
"UnappliedAmt": 0,
"TxnDate": "2023-12-11",
"TotalAmt": 0,
"SyncToken": "0",
"sparse": false,
"MetaData": {
"LastUpdatedTime": "2023-12-11T23:18:57-08:00",
"CreateTime": "2023-12-11T23:18:57-08:00"
},
"Line": [
{
"LinkedTxn": [
{
"TxnType": "Invoice",
"TxnId": "243"
}
],
"Amount": 100
},
{
"LinkedTxn": [
{
"TxnType": "CreditMemo",
"TxnId": "244"
}
],
"Amount": 100
}
],
"Id": "246",
"CustomerRef": {
"value": "71",
"name": "My Company"
},
"CurrencyRef": {
"value": "USD",
"name": "United States Dollar"
}
}
]
},
timestamp=1702365538143,
validRequest=true,
version=1.0
}Do you want to know list of supported parameters for a Payment? See here.