Interface PaymentIntentCheckoutDetails.Builder

  • Method Details

    • lineItems

      The line items included in this payment intent. When present, the service requires the sum of amount × quantity across them, plus amountBreakdown.shipping and amountBreakdown.tax, minus amountBreakdown.discount, to equal totalAmount, or, for a SETUP intent whose totalAmount is an UPTO ceiling, not to exceed it.

      Parameters:
      lineItems - The line items included in this payment intent. When present, the service requires the sum of amount × quantity across them, plus amountBreakdown.shipping and amountBreakdown.tax, minus amountBreakdown.discount, to equal totalAmount, or, for a SETUP intent whose totalAmount is an UPTO ceiling, not to exceed it.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • lineItems

      The line items included in this payment intent. When present, the service requires the sum of amount × quantity across them, plus amountBreakdown.shipping and amountBreakdown.tax, minus amountBreakdown.discount, to equal totalAmount, or, for a SETUP intent whose totalAmount is an UPTO ceiling, not to exceed it.

      Parameters:
      lineItems - The line items included in this payment intent. When present, the service requires the sum of amount × quantity across them, plus amountBreakdown.shipping and amountBreakdown.tax, minus amountBreakdown.discount, to equal totalAmount, or, for a SETUP intent whose totalAmount is an UPTO ceiling, not to exceed it.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • lineItems

      The line items included in this payment intent. When present, the service requires the sum of amount × quantity across them, plus amountBreakdown.shipping and amountBreakdown.tax, minus amountBreakdown.discount, to equal totalAmount, or, for a SETUP intent whose totalAmount is an UPTO ceiling, not to exceed it.

      This is a convenience method that creates an instance of the PaymentLineItem.Builder avoiding the need to create one manually via PaymentLineItem.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to lineItems(List<PaymentLineItem>).

      Parameters:
      lineItems - a consumer that will call methods on PaymentLineItem.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • totalAmount

      The total amount for this payment intent.

      Parameters:
      totalAmount - The total amount for this payment intent.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • totalAmount

      The total amount for this payment intent.

      This is a convenience method that creates an instance of the PaymentIntentAmount.Builder avoiding the need to create one manually via PaymentIntentAmount.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to totalAmount(PaymentIntentAmount).

      Parameters:
      totalAmount - a consumer that will call methods on PaymentIntentAmount.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • amountBreakdown

      The shipping, tax and discount that make up totalAmount alongside the line items. Optional; absent means none of them apply.

      Parameters:
      amountBreakdown - The shipping, tax and discount that make up totalAmount alongside the line items. Optional; absent means none of them apply.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • amountBreakdown

      The shipping, tax and discount that make up totalAmount alongside the line items. Optional; absent means none of them apply.

      This is a convenience method that creates an instance of the PaymentIntentAmountBreakdown.Builder avoiding the need to create one manually via PaymentIntentAmountBreakdown.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to amountBreakdown(PaymentIntentAmountBreakdown).

      Parameters:
      amountBreakdown - a consumer that will call methods on PaymentIntentAmountBreakdown.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • amountMode

      How to interpret totalAmount. EXACT (default) charges totalAmount exactly. UPTO treats totalAmount as a ceiling for the save-and-reuse flow: off-session charges accumulate up to it, and the service rejects any charge that would take the total above it. Optional; absent means EXACT, so existing callers are unaffected.

      Parameters:
      amountMode - How to interpret totalAmount. EXACT (default) charges totalAmount exactly. UPTO treats totalAmount as a ceiling for the save-and-reuse flow: off-session charges accumulate up to it, and the service rejects any charge that would take the total above it. Optional; absent means EXACT, so existing callers are unaffected.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • amountMode

      How to interpret totalAmount. EXACT (default) charges totalAmount exactly. UPTO treats totalAmount as a ceiling for the save-and-reuse flow: off-session charges accumulate up to it, and the service rejects any charge that would take the total above it. Optional; absent means EXACT, so existing callers are unaffected.

      Parameters:
      amountMode - How to interpret totalAmount. EXACT (default) charges totalAmount exactly. UPTO treats totalAmount as a ceiling for the save-and-reuse flow: off-session charges accumulate up to it, and the service rejects any charge that would take the total above it. Optional; absent means EXACT, so existing callers are unaffected.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • returnUrl

      The URL to redirect to after payment selection.

      Parameters:
      returnUrl - The URL to redirect to after payment selection.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • referenceId

      PaymentIntentCheckoutDetails.Builder referenceId(String referenceId)

      The merchant's reference identifier. The service sends it to the payment provider. Optional.

      Parameters:
      referenceId - The merchant's reference identifier. The service sends it to the payment provider. Optional.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • merchant

      The merchant (payee) that receives this payment. The service copies it into the Payment Mandate payee when the buyer confirms, so the payee is trusted server state — the agent does not supply it at authorization.

      Parameters:
      merchant - The merchant (payee) that receives this payment. The service copies it into the Payment Mandate payee when the buyer confirms, so the payee is trusted server state — the agent does not supply it at authorization.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • merchant

      The merchant (payee) that receives this payment. The service copies it into the Payment Mandate payee when the buyer confirms, so the payee is trusted server state — the agent does not supply it at authorization.

      This is a convenience method that creates an instance of the Merchant.Builder avoiding the need to create one manually via Merchant.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to merchant(Merchant).

      Parameters:
      merchant - a consumer that will call methods on Merchant.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also: