Update a customer credit

distru-update-creditWriteQuickBooks

Changes a customer credit's amount, notes or owner. Reaches QuickBooks when your settings sync credits and the customer is linked there, unless only the owner changes or the credit came from a QuickBooks credit memo.

Inputs

Every tool also takes the common inputs.

FieldTypeRequiredDescription
idstringYesResolve via distru-search-credits.
amountstring or numberNoDollars, the new face value. Only on a USER credit, and not below what has been applied (amount minus remainingBalance).
externalNotestringNoVisible to the customer; "" clears it. Not on a QB_CREDIT_MEMO credit: QuickBooks owns its notes.
internalNotestringNoStaff only; "" clears it. Not on a QB_CREDIT_MEMO credit: QuickBooks owns its notes.
ownerIdstringNoAn active user whose credits the caller's team can see. Resolve via distru-search-users.

Output

Presence on a nested field assumes its parent exists.

FieldTypePresence
creditobjectAlways
credit.idstringAlways
credit.creditNumberstringAlways
credit.statusenum
ACTIVECANCELEDREDEEMED
Always
credit.sourceenum
INVOICE_PAYMENTQB_CREDIT_MEMOQB_PAYMENTRETURNUSER
Always
credit.amountstringAlways
credit.originalAmountstringAlways
credit.remainingBalancestringAlways
credit.customerobjectCan be null
credit.customer.idstringAlways
credit.customer.namestringNull or absent
credit.ownerobjectCan be null
credit.owner.idstringAlways
credit.owner.profileobjectAlways
credit.owner.profile.fullNamestringAlways
credit.externalNotestringCan be null
credit.internalNotestringCan be null
credit.qbCreditMemoIdstringCan be null
credit.qbPaymentIdstringCan be null
credit.qbSyncStatusenum
DELETED_IN_QBOERRORNOT_SYNCEDPARTIALLY_SYNCEDPENDINGSYNCED
Can be null
credit.insertedAtstringAlways
credit.updatedAtstringAlways
credit.canceledAtstringCan be null
credit.sourcePaymentobjectCan be null
credit.sourcePayment.idstringAlways
credit.sourcePayment.paymentNumberstringAlways
credit.sourcePayment.invoiceobjectCan be null
credit.sourcePayment.invoice.idstringAlways
credit.sourcePayment.invoice.invoiceNumberstringAlways
credit.sourceReturnobjectCan be null
credit.sourceReturn.idstringAlways
credit.sourceReturn.returnNumberstringAlways
credit.creditUsesobject[]Always
credit.creditUses[].amountstringAlways
credit.creditUses[].appliedAtstringAlways
credit.creditUses[].paymentobjectCan be null
credit.creditUses[].payment.idstringAlways
credit.creditUses[].payment.paymentNumberstringAlways
credit.creditUses[].invoiceobjectCan be null
credit.creditUses[].invoice.idstringAlways
credit.creditUses[].invoice.invoiceNumberstringAlways
What the AI reads

Sparse update: changes a customer credit's amount, notes or owner; the fields left out stay as they are. Returns the credit as distru-get-credit does, without line items or history.