ODBC Driver for QuickBooks Online

Build 20.0.7587

Payments

Create, update, delete, and query QuickBooks Payments.

Table Specific Information

Payments may be inserted, queried, or updated via the Payments or PaymentLineItems tables. Payments may be deleted by using the Payments table.

Insert

To add a Payment, specify a Customer and at least one item Line Item. The LineAggregate column may be used to specify an XML aggregate of Line Item data. The columns that may be used in these aggregates are defined in the PaymentLineItems table as # columns. Each _ denotes hierarchy. Use <Line> at the base level. The contents of LineAggregate will be sent to the API as is. All values for each field in the aggregate should adhere to the API's specifications (e.g. for dates in format yyyy-MM-dd, for date times in format yyyy-MM-dd'T'HH:mm:sszzz). For example, the following will insert a new Payment with two Line Items:

INSERT INTO Payments (CustomerRef, TotalAmt, LineAggregate) 
VALUES ('4', '0.03', '
<Line><Amount>0.01</Amount><LinkedTxn><TxnId>116</TxnId><TxnType>Invoice</TxnType></LinkedTxn></Line>
<Line><Amount>0.02</Amount><LinkedTxn><TxnId>117</TxnId><TxnType>Invoice</TxnType></LinkedTxn></Line>
')

To automatically add payments for invoices up to a specific total amount, set AutoInvoice to true. You must also supply a Customer and a positive TotalAmt. Your unpaid invoices will be paid from the soonest due to the oldest one.

INSERT INTO Payments (CustomerRef, TotalAmt, AutoInvoice) VALUES ('4', 27.5, true)

Columns

Name Type ReadOnly References Filterable Sortable Description
Id [KEY] String True true true

The Id of the payment.

SyncToken String True false false

Version number of the object. It is used to lock an object for use by one app at a time. As soon as an application modifies an object, its SyncToken is incremented. Attempts to modify an object specifying an older SyncToken fails. Only the latest version of the object is maintained by QuickBooks Online.

MetaData_CreateTime Datetime True true true

The time the record was created.

MetaData_LastUpdatedTime Datetime True true true

The time the record was last updated.

TxnDate Date False true false

The date entered by the user when this transaction occurred.

PrivateNote String False false false

A private note about the transaction. This note will not appear on the transaction records by default.

TxnStatus String False false false

The status of the transaction. For payment entities, this status is always set to PAID.

LineAggregate String False false false

A line item of a transaction.

TxnTaxDetail_TxnTaxCodeRef String False

TaxCodes.Id

false false

The transaction tax code.

TxnTaxDetail_TotalTax String False false false

Total tax calculated for the transaction, excluding any tax lines manually inserted into the transaction line list.

TxnTaxDetail_TaxLineAggregate String False false false

An XML aggregate of tax line items.

CustomerRef String False

Customers.Id

true false

The Id of the customer.

CustomerRef_Name String True

Customers.DisplayName

false false

The name of the customer.

RemitToRef String True false false

The Id of the entity for the party or location that the payment is to be remitted to or sent to.

RemitToRef_Name String True false false

The name of the party or location that the payment is to be remitted to or sent to.

ARAccountRef String False

Accounts.Id

false false

The Id of the Accounts Receivable account (ARAccount) associated with the transaction. It is strongly recommended to always supply this field, even though it is ignored by QuickBooks Online, because QuickBooks Online has only one accounts recievable account.

ARAccountRef_Name String True

Accounts.Name

false false

The name of the Accounts Receivable account (ARAccount) associated with the transaction. It is strongly recommended to always supply this field, even though it is ignored by QuickBooks Online, because QuickBooks Online has only one accounts recievable account.

DepositToAccountRef String False

Accounts.Id

false false

An optional asset account specification. The Id of the asset account that designates the account the payment money needs to be deposited to.

DepositToAccountRef_Name String True

Accounts.Name

false false

An optional asset account specification. The name of the account the payment money needs to be deposited to.

PaymentMethodRef String False

PaymentMethods.Id

false false

The Id of the payment method.

PaymentMethodRef_Name String True

PaymentMethods.Name

false false

The name of the payment method.

The allowed values are Cash, Check, CreditCard, Other.

PaymentRefNum String False true true

The reference number for the payment received.

CreditCardPayment_CreditChargeInfo String False false false

This field holds credit card information to request a credit card payment from a merchant account service, but not any response or authorization information from the merchant account service provider.

CreditCardPayment_Number String False false false

The credit card account number, as printed on the card. This field must not have white space or formatting characters.

CreditCardPayment_Type String False false false

The type of credit card.

CreditCardPayment_NameOnAcct String False false false

The account holder name as printed on the card.

CreditCardPayment_CcExpiryMonth Integer False false false

The expiration month on the card.

CreditCardPayment_CcExpiryYear Integer False false false

The 4-digit expiration year on the card.

CreditCardPayment_BillAddrStreet String False false false

The street of the billing address.

CreditCardPayment_PostalCode String False false false

The postal code.

CreditCardPayment_CommercialCardCode String False false false

The code associated with commercial cards such as purchase, corporate, or business cards. Lower transaction fee rates apply for these cards when this field is defined.

CreditCardPayment_CCTxnMode String False false false

The credit card transaction mode used in credit card payment transactions.

The allowed values are CardNotPresent, CardPresent.

CreditCardPayment_CCTxnType String False false false

The type of credit card transaction.

The allowed values are Authorization, Capture, Charge, Refund, VoiceAuthorization.

CreditCardPayment_PrevCCTransId String False false false

The Id of the previous payment transaction.

TotalAmt Decimal False true true

The total amount of the entity associated. This includes the total of all the payments from the payment details.

UnappliedAmt Decimal False false false

The amount that has not been applied to pay amounts owed for sales transactions.

ProcessPayment Boolean False false false

This field indicates that the payment should be processed by merchant account service. This field is valid for companies with credit card processing enabled in QuickBooks Online.

CurrencyRef String False false false

The Id of the currency used in the transaction.

CurrencyRef_Name String True false false

The name of the currency used in the transaction.

ExchangeRate Decimal False false false

The currency exchange rate. This field is valid only if the company file is set up to use the multicurrency feature. In QuickBooks, exchange rates are always recorded as the number of home currency units it takes to equal one foreign currency unit. This field is available for the UK, AU, IN, and CA editions.

Pseudo-Columns

Pseudo Column fields are used in the WHERE clause of SELECT statements and offer a more granular control over the tuples that are returned from the data source.

Name Type Description
AutoInvoice Boolean

Set to true to apply payments to invoices automatically (starting from oldest to newest).

Copyright (c) 2020 CData Software, Inc. - All rights reserved.
Build 20.0.7587