Skip to main content

Payment

In the context of Purse's API V2, a payment represents a complete financial transaction that can include multiple authorizations and monetary operations (capture, refund, void). The API V2, also known as the orchestration API, implements orchestration functionalities not present in API V1.

Key features:

  • An "Authorization" object that groups transactions and calculates a global status
  • A "Payment" object that handles all monetary operations (capture, void, refund) with automatic distribution across different payment methods and verification of amount integrity
  • Status calculation before merchant redirection, available in the redirection

Payment Statuses

Authorization statuses:

  • AUTHORIZED - Payment has been successfully authorized
  • PENDING - Authorization is in progress
  • ERROR - An error occurred during the payment process
  • ABORTED - The payment was aborted
  • REFUSED - The payment was refused by the payment provider

Post-authorization statuses:

  • CAPTURED (TOTALLY/PARTIALLY) - Indicates whether the payment has been fully or partially captured
  • VOIDED (TOTALLY/PARTIALLY) - Indicates whether the payment has been fully or partially voided
  • REFUNDED (TOTALLY/PARTIALLY) - Indicates whether the payment has been fully or partially refunded

Amount Information

  • available_to_void - Amount that can be voided
  • available_to_capture - Amount that can be captured
  • available_to_refund - Amount that can be refunded

The payment object facilitates multi-payment management (compensation between different payment methods).