Skip to main content

Payment Service

Payment on account is any partial payment of an amount that is owed, either to you or by you, that is not matched to a specific invoice. If you receive a payment (either full or partial payment) from a customer or make a payment to a vendor without making reference to a specific invoice this can be treated as a payment on account. The Payment service covers both directions of this flow: Receive Payment (money coming in from a contact) and Make Payment (money going out to a contact).

ReceivePaymentDto Object

Attributes


AttributeTypeDescription
idlongUnique identifier for payment.
codestringPayment code.
jeCodestringJournal Entry code.
contactCodestringcode related to the contact making the payment.
contactNamestringName of contact making the payment.
currencyenumCurrency code the payment is made in.
Example: "USD"
exchangeRateBigDecimalExchange rate.
primaryExchangeRateBigDecimalExchange rate against the organization's primary currency.
accountCodePayTostringThe account code payment is made to.
accountNamestringName of payment account.
paymentTypeenumPayment type. Possible values for Payment type.
referenceNumberstringReference number of Bank Transfer/cheque.
referenceDatestringDate of Bank Transfer/cheque.
amountBigDecimalPayment amount.
amountDueBigDecimalAmount still due against this payment.
documentDatestringDocument date.
memostringMemo text.
deletedbooleanHas the value true if the payment is deleted or false if the payment is not deleted.
tenantIdlongTenant id to whom payment is associated with.
receivePaymentItemDtoListlistReceive payment for item. Attributes of ReceivePaymentItemDto.
knockoffInfolistList of knock-off details linking this payment to the documents it settles.
receivePaymentFeeDtoListlistReceive payment for fee. Attributes of ReceivePaymentFeeDto.
shipFromobjectShip from address. Attributes of Address.
shipToobjectShip to address. Attributes of Address.
billToobjectBill to address. Attributes of Address.
gstExchangeRateBigDecimalGST exchange rate.
reconciledbooleanHas the value true if the payment has been reconciled or false otherwise.
isUnDepositedPaymentbooleanHas the value true if the payment is an undeposited payment or false otherwise.
unitPriceGstInclusivebooleanHas the value true if unit prices are GST inclusive or false otherwise.
unDepositedEntriesReconciledlistList of undeposited entries that have been reconciled against this payment.
journalEntryBankTransferRequestDtoobjectJournal entry bank transfer request details.
customFieldlistList of key-value pairs for custom field name and its value.
attachmentIdslistList of attachment ids of the payment.
bankRuleIdlongIdentifier of the bank rule applied to this payment.
openingbooleanHas the value true if the payment is an opening balance entry or false otherwise.
errorslistList of validation/processing error messages.
sentEmailbooleanHas the value true if a receipt email has been sent for this payment or false otherwise.
interCompanybooleanHas the value true if the payment is an inter-company transaction or false otherwise.
customerTypeIndiaenumIndia-specific customer type classification.
vendorTypeIndiaenumIndia-specific vendor type classification.
gstTreatmentIndiaenumIndia-specific GST treatment classification.
gstInstringIndia GSTIN of the contact.
paymentTransTimestringTransaction time of the payment.
roundOffAmountInBaseCurrencyBigDecimalRound-off amount in the base currency.
roundOffAmountInDocumentCurrencyBigDecimalRound-off amount in the document currency.
salesInvoiceobjectLinked sales invoice details, when the payment is created against a sales invoice.

ReceivePaymentResponseDto Object

ReceivePaymentResponseDto includes all attributes of ReceivePaymentDto (except salesInvoice), plus the following response-only attributes.

AttributeTypeDescription
whtApplicablebooleanHas the value true if withholding tax is applicable to this payment or false otherwise.
createdBylongIdentifier of the user who created the payment.
updatedBylongIdentifier of the user who last updated the payment.

API


Create Receive Payment

Creates a new receive payment.

Parameters

Code

  @Autowired
private PaymentsApiClient paymentsApiClient;

public ReceivePaymentResponseDto receivePayment(ReceivePaymentDto receivePaymentDto, String accessToken){
return this.paymentsApiClient.receivePayment(receivePaymentDto, accessToken);
}

Retrieve Receive Payment

Retrieves the details of an existing receive payment. You only need to supply the unique payment code that was returned upon payment creation.

Parameters

Code

  @Autowired
private PaymentsApiClient paymentsApiClient;

public ReceivePaymentDto getReceivePaymentByCode(String paymentCode, String accessToken){
return this.paymentsApiClient.getReceivePaymentByCode(paymentCode, accessToken);
}

Update Receive Payment

Updates an existing receive payment.

Parameters

Code

  @Autowired
private PaymentsApiClient paymentsApiClient;

public ReceivePaymentResponseDto updateReceivePayment(Long id, ReceivePaymentDto receivePaymentDto, String accessToken){
return this.paymentsApiClient.updateReceivePayment(id, receivePaymentDto, accessToken);
}

Delete Receive Payment

Deletes an existing receive payment. You only need to supply the unique payment code that was returned upon payment creation.

Parameters

Code

  @Autowired
private PaymentsApiClient paymentsApiClient;

public void deleteReceivePayment(String paymentCode, String accessToken){
this.paymentsApiClient.deleteReceivePayment(paymentCode, accessToken);
}

List Receive Payments

Returns a paginated list of receive payments.

Parameters

  • search string
  • sort string
  • sortDir string
  • page int
  • limit int
  • accessToken string

Code

  @Autowired
private PaymentsApiClient paymentsApiClient;

public Page<ReceivePaymentResponseDto> searchReceivePayments(String search, String sort,
String sortDir, Integer page, Integer limit, String accessToken){
return this.paymentsApiClient.searchReceivePayments(search, sort, sortDir, page, limit, accessToken);
}

MakePaymentDto Object

Attributes


AttributeTypeDescription
idlongUnique identifier for payment.
parentPaymentIdlongIdentifier of the parent payment, when this payment was split from another.
codestringPayment code.
jeCodestringJournal Entry code.
contactCodestringcode related to the contact being paid.
contactNamestringName of contact being paid.
currencyenumCurrency code the payment is made in.
Example: "USD"
exchangeRateBigDecimalExchange rate.
primaryExchangeRateBigDecimalExchange rate against the organization's primary currency.
accountCodePayFromstringThe account code payment is made from.
accountNamestringName of payment account.
paymentTypeenumPayment type. Possible values for Payment type.
referenceNumberstringReference number of Bank Transfer/cheque.
referenceDatestringDate of Bank Transfer/cheque.
amountBigDecimalPayment amount.
amountDueBigDecimalAmount still due against this payment.
documentDatestringDocument date.
memostringMemo text.
recurringPaymentbooleanHas the value true if the payment is set up to recur or false otherwise.
recurringActivatedbooleanHas the value true if the recurring schedule is currently active or false otherwise.
nextPaymentDatestringDate the next recurring payment is due.
deletedbooleanHas the value true if the payment is deleted or false if the payment is not deleted.
tenantIdlongTenant id to whom payment is associated with.
makePaymentItemDtoListlistMake payment for item. Attributes of MakePaymentItemDto.
makePaymentFeeDtoListlistMake payment for fee. Attributes of MakePaymentFeeDto.
knockoffInfolistList of knock-off details linking this payment to the documents it settles.
makePaymentRecurringDtoobjectRecurring payment schedule details.
gstExchangeRateBigDecimalGST exchange rate.
reconciledbooleanHas the value true if the payment has been reconciled or false otherwise.
customFieldlistList of key-value pairs for custom field name and its value.
attachmentIdslistList of attachment ids of the payment.
bankRuleIdlongIdentifier of the bank rule applied to this payment.
tdsPaymentInfoIndiaobjectIndia-specific TDS payment information.
isTdsPaymentIndiabooleanHas the value true if TDS applies to this payment (India) or false otherwise.
unitPriceGstInclusivebooleanHas the value true if unit prices are GST inclusive or false otherwise.
tdsProcessedFlagbooleanHas the value true if TDS has been processed for this payment or false otherwise.
statusenumPrint status of the payment.
openingbooleanHas the value true if the payment is an opening balance entry or false otherwise.
errorslistList of validation/processing error messages.
interCompanybooleanHas the value true if the payment is an inter-company transaction or false otherwise.
customerTypeIndiaenumIndia-specific customer type classification.
vendorTypeIndiaenumIndia-specific vendor type classification.
gstTreatmentIndiaenumIndia-specific GST treatment classification.
gstInstringIndia GSTIN of the contact.
billToobjectBill to address. Attributes of Address.
isSalesRefundbooleanHas the value true if the payment represents a sales refund or false otherwise.
applyRcmCheckbooleanHas the value true if the reverse charge mechanism check applies or false otherwise.
roundOffAmountInBaseCurrencyBigDecimalRound-off amount in the base currency.
roundOffAmountInDocumentCurrencyBigDecimalRound-off amount in the document currency.
refundedInvoiceCodestringCode of the invoice this payment refunds, when applicable.
purchaseInvoiceobjectLinked purchase invoice details, when the payment is created against a purchase invoice.
supplierInvoiceNostringSupplier's own invoice number.
tdsIdslistList of TDS identifiers applied to this payment.

MakePaymentResponseDto Object

MakePaymentResponseDto includes all attributes of MakePaymentDto (except purchaseInvoice, supplierInvoiceNo and tdsIds), plus the following response-only attributes.

AttributeTypeDescription
whtApplicablebooleanHas the value true if withholding tax is applicable to this payment or false otherwise.
createdBylongIdentifier of the user who created the payment.
updatedBylongIdentifier of the user who last updated the payment.

API


Create Make Payment

Creates a new make payment.

Parameters

Code

  @Autowired
private PaymentsApiClient paymentsApiClient;

public MakePaymentResponseDto makePayment(MakePaymentDto makePaymentDto, String accessToken){
return this.paymentsApiClient.makePayment(makePaymentDto, accessToken);
}

Retrieve Make Payment

Retrieves the details of an existing make payment. You only need to supply the unique payment code that was returned upon payment creation.

Parameters

Code

  @Autowired
private PaymentsApiClient paymentsApiClient;

public MakePaymentDto getMakePaymentByCode(String paymentCode, String accessToken){
return this.paymentsApiClient.getMakePaymentByCode(paymentCode, accessToken);
}

Update Make Payment

Updates an existing make payment.

Parameters

Code

  @Autowired
private PaymentsApiClient paymentsApiClient;

public MakePaymentResponseDto updateMakePayment(Long id, MakePaymentDto makePaymentDto, String accessToken){
return this.paymentsApiClient.updateMakePayment(id, makePaymentDto, accessToken);
}

Delete Make Payment

Deletes an existing make payment. You only need to supply the unique payment code that was returned upon payment creation.

Parameters

Code

  @Autowired
private PaymentsApiClient paymentsApiClient;

public void deleteMakePayment(String paymentCode, String accessToken){
this.paymentsApiClient.deleteMakePayment(paymentCode, accessToken);
}

List Make Payments

Returns a paginated list of make payments.

Parameters

  • search string
  • sort string
  • sortDir string
  • page int
  • limit int
  • accessToken string

Code

  @Autowired
private PaymentsApiClient paymentsApiClient;

public Page<MakePaymentResponseDto> searchMakePayments(String search, String sort,
String sortDir, Integer page, Integer limit, String accessToken){
return this.paymentsApiClient.searchMakePayments(search, sort, sortDir, page, limit, accessToken);
}

Objects


ReceivePaymentItemDto

ReceivePaymentItemResponseDto (used inside ReceivePaymentResponseDto) has the same attributes as ReceivePaymentItemDto.

AttributeTypeDescription
idlongUnique identifier for payment.
documentTypestringProduct code of the item. Possible values for document type.
documentCodestringUnique code for order.
documentSequenceCodestringSequence code of the document being paid against.
customerOrderNumberstringCustomer order number associated with the document.
descriptionstringDescription of payment received.
exchangeRateBigDecimalExchange rate.
taxCodestringCode of selected tax.
taxAmountBigDecimalTax Amount.
paymentAmountBigDecimalAmount to be paid.
tenantIdlongTenant id to whom payment is associated with.
accountNamestringName of payment account.
taxListlistTax List. Attributes of TaxMappingDto.
tdsInfoIndiaobjectIndia-specific TDS information for this item.
isTdsApplicableContactbooleanHas the value true if TDS applies at the contact level or false otherwise.
isTdsApplicableAccountbooleanHas the value true if TDS applies at the account level or false otherwise.
customFieldlistList of key-value pairs for custom field name and its value.
errorslistList of validation/processing error messages.
supplierInvoiceNostringSupplier's own invoice number.
paymentIdlongIdentifier for payment.

MakePaymentItemDto

MakePaymentItemResponseDto (used inside MakePaymentResponseDto) has the same attributes as MakePaymentItemDto. Both share the common item attributes listed under ReceivePaymentItemDto (id, documentType, documentCode, documentSequenceCode, customerOrderNumber, description, exchangeRate, taxCode, taxAmount, paymentAmount, tenantId, accountName, taxList, paymentId), plus the following.

AttributeTypeDescription
tdsAccountstringTDS account code applied to this item.
tdsRateBigDecimalTDS rate applied to this item.
tdsAmountBigDecimalTDS amount deducted for this item.
itcAdjustmentenumInput Tax Credit adjustment type.
itcIneligibleTypeenumInput Tax Credit ineligibility type.
glAccountCodestringGeneral ledger account code for this item.
totalAmountBigDecimalTotal amount for this item.

TaxMappingDto

AttributeTypeDescription
idlongUnique identifier for tax.
taxSeqCodestringSequence code of tax item.
taxCodestringCode of tax.
taxNamestringName of tax.
taxIdBigDecimalIdentifier of the tax.
taxTypestringType of tax.
taxApplyTostringWhat the tax is applied to.
taxAmountBigDecimalTax Amount.
taxRateBigDecimalRate of Tax.
additionalTaxInbooleanHas the value true if this is an additional inclusive tax or false otherwise.
taxableAmountBigDecimalAmount to tax.

ReceivePaymentFeeDto

AttributeTypeDescription
idlongUnique identifier for payment fee.
accountCodestringCode linked to the account used.
amountBigDecimalFee amount.
tenantIdlongTenant id to whom payment is associated with.
paymentIdlongIdentifier for payment.

MakePaymentFeeDto

MakePaymentFeeDto has the same attributes as ReceivePaymentFeeDto.

AttributeTypeDescription
idlongUnique identifier for payment fee.
accountCodestringCode linked to the account used.
amountBigDecimalFee amount.
tenantIdlongTenant id to whom payment is associated with.
paymentIdlongIdentifier for payment.

Address

AttributeTypeDescription
contactNamestringName of the contact associated with the address.
address1stringAddress Line 1.
address2stringAddress Line 2.
countrystringCountry where the address is located.
countryCodestringCountry code of the address.
statestringState where the address is located.
citystringCity where the address is located.
postalCodestringAddress postal code.
preferredbooleanHas the value true if address is set as default or false if address is not set as default.
placeOfSupplystringPlace of supply for tax purposes.
destinationOfSupplystringDestination of supply for tax purposes.
stateCodestringState code of the address.
mobileCountryCodestringCountry code for the mobile number.
mobileNumberstringMobile number.
emailIdstringEmail address.
customFieldslistList of key-value pairs for custom field name and its value.

Enums


PAYMENT_TYPE

  • CHEQUE
  • CASH
  • BANK_TRANSFER
  • CARD
  • OTHERS
  • ACH

DOCUMENT_TYPE

  • QUOTATION
  • PURCHASE_ORDER
  • SALES_ORDER
  • PURCHASE_INVOICE
  • SALES_INVOICE
  • MAKE_PAYMENT
  • RECEIVE_PAYMENT
  • JOURNAL_ENTRY
  • CREDIT_NOTE
  • DEBIT_NOTE
  • EXPENSE
  • EXPENSE_PREPAYMENT
  • DEPOSIT
  • DEPOSIT_ADVPAYMENT

DOCUMENT_TYPE is a shared enum used across the wider Deskera platform; the values above are the ones relevant to payment documents. Other document types (e.g. FULFILLMENT, WORK_ORDER, JOB_CARD) also exist on this enum but aren't specific to Payment.