Class CreatePaymentLink


  • public class CreatePaymentLink
    extends java.lang.Object
    CreatePaymentLink

    Request to create a new payment link.

    A payment link must include either `payment` or `payout` details, but not both. For payout payment links, `maxUses` will automatically be set to 1, as these are intended for a one-time disbursement to a specific recipient.

    **Note:** The `payout` option is currently under development and is not yet available for general use.

    • Method Detail

      • partnerAccountID

        public java.lang.String partnerAccountID()
        The partner's Moov account ID.
      • merchantPaymentMethodID

        public java.lang.String merchantPaymentMethodID()
        The merchant's preferred payment method ID. Must be a wallet payment method.
      • amount

        public Amount amount()
      • maxUses

        public java.util.Optional<java.lang.Long> maxUses()
        An optional limit on the number of times this payment link can be used.

        **For payouts, `maxUses` is always 1.**

      • expiresOn

        public java.util.Optional<java.time.OffsetDateTime> expiresOn()
        An optional expiration date for this payment link.
      • payment

        public java.util.Optional<PaymentLinkPaymentDetails> payment()
        Options for payment links used to collect payment.
      • withPartnerAccountID

        public CreatePaymentLink withPartnerAccountID​(java.lang.String partnerAccountID)
        The partner's Moov account ID.
      • withMerchantPaymentMethodID

        public CreatePaymentLink withMerchantPaymentMethodID​(java.lang.String merchantPaymentMethodID)
        The merchant's preferred payment method ID. Must be a wallet payment method.
      • withMaxUses

        public CreatePaymentLink withMaxUses​(long maxUses)
        An optional limit on the number of times this payment link can be used.

        **For payouts, `maxUses` is always 1.**

      • withMaxUses

        public CreatePaymentLink withMaxUses​(java.util.Optional<java.lang.Long> maxUses)
        An optional limit on the number of times this payment link can be used.

        **For payouts, `maxUses` is always 1.**

      • withExpiresOn

        public CreatePaymentLink withExpiresOn​(java.time.OffsetDateTime expiresOn)
        An optional expiration date for this payment link.
      • withExpiresOn

        public CreatePaymentLink withExpiresOn​(java.util.Optional<java.time.OffsetDateTime> expiresOn)
        An optional expiration date for this payment link.
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object