Newer Version Available

This content describes an older version of this product. View Latest

Apply Payment Action

Applies a payment record to an invoice header by creating a PaymentLineInvoice record with a type of Applied.
To access Commerce Payments resources, you need the following permissions.
  • Salesforce Order Management License or Salesforce B2B Commerce License
  • PaymentsAPIUser user permission. This permission is available with the Salesforce Order Management or B2B Commerce License. Your Salesforce admin assigns it to your user profile.

This object is available in API version 54.0 and later.

Supported REST HTTP Methods

URI
/services/data/v54.0/actions/standard/applyPayment
Formats
JSON
HTTP Methods
POST
Authentication
Authorization: Bearer token

Inputs

Input Details
amount
Type
number
Description
Required. The amount to be applied to the invoice header.
appliedToId
Type
ID
Description
Required. The ID of the invoice that receives the payment.
associatedAccountId
Type
ID
Description
Optional. The ID of the account that contains the invoice.
comments
Type
String
Description
Optional comments for more information about the payment application.
effectiveDate
Type
datetime
Description
Optional. The date that the payment takes effect on the invoice.
paymentId
Type
string
Description
Required. The payment that's applied to the invoice. The application is represented by the PaymentLineInvoice created for a successful action.

Outputs

Output Details
appliedDate
Type
datetime
Description
The date that the payment was applied to the invoice header.
paymentLineInvoiceId
Type
ID
Description
Represents the application of the payment's amount to the invoice. Created after a successful action.