Class LnrpcInvoice

java.lang.Object
net.osslabz.lnd.dto.LnrpcInvoice

@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", date="2023-06-07T12:03:38.664532692Z[Etc/UTC]") public class LnrpcInvoice extends Object
LnrpcInvoice
  • Field Details

  • Constructor Details

    • LnrpcInvoice

      public LnrpcInvoice()
  • Method Details

    • memo

      public LnrpcInvoice memo(String memo)
    • getMemo

      @Nullable public String getMemo()
      An optional memo to attach along with the invoice. Used for record keeping purposes for the invoice's creator, and will also be set in the description field of the encoded payment request if the description_hash field is not being used.
      Returns:
      memo
    • setMemo

      public void setMemo(String memo)
    • rPreimage

      public LnrpcInvoice rPreimage(byte[] rPreimage)
    • getrPreimage

      @Nullable public byte[] getrPreimage()
      The hex-encoded preimage (32 byte) which will allow settling an incoming HTLC payable to this preimage. When using REST, this field must be encoded as base64.
      Returns:
      rPreimage
    • setrPreimage

      public void setrPreimage(byte[] rPreimage)
    • rHash

      public LnrpcInvoice rHash(byte[] rHash)
    • getrHash

      @Nullable public byte[] getrHash()
      The hash of the preimage. When using REST, this field must be encoded as base64. Note: Output only, don't specify for creating an invoice.
      Returns:
      rHash
    • setrHash

      public void setrHash(byte[] rHash)
    • value

      public LnrpcInvoice value(String value)
    • getValue

      @Nullable public String getValue()
      The fields value and value_msat are mutually exclusive.
      Returns:
      value
    • setValue

      public void setValue(String value)
    • valueMsat

      public LnrpcInvoice valueMsat(String valueMsat)
    • getValueMsat

      @Nullable public String getValueMsat()
      The fields value and value_msat are mutually exclusive.
      Returns:
      valueMsat
    • setValueMsat

      public void setValueMsat(String valueMsat)
    • settled

      public LnrpcInvoice settled(Boolean settled)
    • getSettled

      @Nullable public Boolean getSettled()
      Whether this invoice has been fulfilled. The field is deprecated. Use the state field instead (compare to SETTLED).
      Returns:
      settled
    • setSettled

      public void setSettled(Boolean settled)
    • creationDate

      public LnrpcInvoice creationDate(String creationDate)
    • getCreationDate

      @Nullable public String getCreationDate()
      When this invoice was created. Measured in seconds since the unix epoch. Note: Output only, don't specify for creating an invoice.
      Returns:
      creationDate
    • setCreationDate

      public void setCreationDate(String creationDate)
    • settleDate

      public LnrpcInvoice settleDate(String settleDate)
    • getSettleDate

      @Nullable public String getSettleDate()
      When this invoice was settled. Measured in seconds since the unix epoch. Note: Output only, don't specify for creating an invoice.
      Returns:
      settleDate
    • setSettleDate

      public void setSettleDate(String settleDate)
    • paymentRequest

      public LnrpcInvoice paymentRequest(String paymentRequest)
    • getPaymentRequest

      @Nullable public String getPaymentRequest()
      A bare-bones invoice for a payment within the Lightning Network. With the details of the invoice, the sender has all the data necessary to send a payment to the recipient. Note: Output only, don't specify for creating an invoice.
      Returns:
      paymentRequest
    • setPaymentRequest

      public void setPaymentRequest(String paymentRequest)
    • descriptionHash

      public LnrpcInvoice descriptionHash(byte[] descriptionHash)
    • getDescriptionHash

      @Nullable public byte[] getDescriptionHash()
      Hash (SHA-256) of a description of the payment. Used if the description of payment (memo) is too long to naturally fit within the description field of an encoded payment request. When using REST, this field must be encoded as base64.
      Returns:
      descriptionHash
    • setDescriptionHash

      public void setDescriptionHash(byte[] descriptionHash)
    • expiry

      public LnrpcInvoice expiry(String expiry)
    • getExpiry

      @Nullable public String getExpiry()
      Payment request expiry time in seconds. Default is 86400 (24 hours).
      Returns:
      expiry
    • setExpiry

      public void setExpiry(String expiry)
    • fallbackAddr

      public LnrpcInvoice fallbackAddr(String fallbackAddr)
    • getFallbackAddr

      @Nullable public String getFallbackAddr()
      Fallback on-chain address.
      Returns:
      fallbackAddr
    • setFallbackAddr

      public void setFallbackAddr(String fallbackAddr)
    • cltvExpiry

      public LnrpcInvoice cltvExpiry(String cltvExpiry)
    • getCltvExpiry

      @Nullable public String getCltvExpiry()
      Delta to use for the time-lock of the CLTV extended to the final hop.
      Returns:
      cltvExpiry
    • setCltvExpiry

      public void setCltvExpiry(String cltvExpiry)
    • routeHints

      public LnrpcInvoice routeHints(List<LnrpcRouteHint> routeHints)
    • addRouteHintsItem

      public LnrpcInvoice addRouteHintsItem(LnrpcRouteHint routeHintsItem)
    • getRouteHints

      @Nullable public List<LnrpcRouteHint> getRouteHints()
      Route hints that can each be individually used to assist in reaching the invoice's destination.
      Returns:
      routeHints
    • setRouteHints

      public void setRouteHints(List<LnrpcRouteHint> routeHints)
    • _private

      public LnrpcInvoice _private(Boolean _private)
    • getPrivate

      @Nullable public Boolean getPrivate()
      Whether this invoice should include routing hints for private channels. Note: When enabled, if value and value_msat are zero, a large number of hints with these channels can be included, which might not be desirable.
      Returns:
      _private
    • setPrivate

      public void setPrivate(Boolean _private)
    • addIndex

      public LnrpcInvoice addIndex(String addIndex)
    • getAddIndex

      @Nullable public String getAddIndex()
      The \"add\" index of this invoice. Each newly created invoice will increment this index making it monotonically increasing. Callers to the SubscribeInvoices call can use this to instantly get notified of all added invoices with an add_index greater than this one. Note: Output only, don't specify for creating an invoice.
      Returns:
      addIndex
    • setAddIndex

      public void setAddIndex(String addIndex)
    • settleIndex

      public LnrpcInvoice settleIndex(String settleIndex)
    • getSettleIndex

      @Nullable public String getSettleIndex()
      The \"settle\" index of this invoice. Each newly settled invoice will increment this index making it monotonically increasing. Callers to the SubscribeInvoices call can use this to instantly get notified of all settled invoices with an settle_index greater than this one. Note: Output only, don't specify for creating an invoice.
      Returns:
      settleIndex
    • setSettleIndex

      public void setSettleIndex(String settleIndex)
    • amtPaid

      public LnrpcInvoice amtPaid(String amtPaid)
    • getAmtPaid

      @Nullable public String getAmtPaid()
      Deprecated, use amt_paid_sat or amt_paid_msat.
      Returns:
      amtPaid
    • setAmtPaid

      public void setAmtPaid(String amtPaid)
    • amtPaidSat

      public LnrpcInvoice amtPaidSat(String amtPaidSat)
    • getAmtPaidSat

      @Nullable public String getAmtPaidSat()
      The amount that was accepted for this invoice, in satoshis. This will ONLY be set if this invoice has been settled. We provide this field as if the invoice was created with a zero value, then we need to record what amount was ultimately accepted. Additionally, it's possible that the sender paid MORE that was specified in the original invoice. So we'll record that here as well. Note: Output only, don't specify for creating an invoice.
      Returns:
      amtPaidSat
    • setAmtPaidSat

      public void setAmtPaidSat(String amtPaidSat)
    • amtPaidMsat

      public LnrpcInvoice amtPaidMsat(String amtPaidMsat)
    • getAmtPaidMsat

      @Nullable public String getAmtPaidMsat()
      The amount that was accepted for this invoice, in millisatoshis. This will ONLY be set if this invoice has been settled. We provide this field as if the invoice was created with a zero value, then we need to record what amount was ultimately accepted. Additionally, it's possible that the sender paid MORE that was specified in the original invoice. So we'll record that here as well. Note: Output only, don't specify for creating an invoice.
      Returns:
      amtPaidMsat
    • setAmtPaidMsat

      public void setAmtPaidMsat(String amtPaidMsat)
    • state

      public LnrpcInvoice state(InvoiceInvoiceState state)
    • getState

      @Nullable public InvoiceInvoiceState getState()
      Get state
      Returns:
      state
    • setState

      public void setState(InvoiceInvoiceState state)
    • htlcs

      public LnrpcInvoice htlcs(List<LnrpcInvoiceHTLC> htlcs)
    • addHtlcsItem

      public LnrpcInvoice addHtlcsItem(LnrpcInvoiceHTLC htlcsItem)
    • getHtlcs

      @Nullable public List<LnrpcInvoiceHTLC> getHtlcs()
      List of HTLCs paying to this invoice [EXPERIMENTAL]. Note: Output only, don't specify for creating an invoice.
      Returns:
      htlcs
    • setHtlcs

      public void setHtlcs(List<LnrpcInvoiceHTLC> htlcs)
    • features

      public LnrpcInvoice features(Map<String,LnrpcFeature> features)
    • putFeaturesItem

      public LnrpcInvoice putFeaturesItem(String key, LnrpcFeature featuresItem)
    • getFeatures

      @Nullable public Map<String,LnrpcFeature> getFeatures()
      List of features advertised on the invoice. Note: Output only, don't specify for creating an invoice.
      Returns:
      features
    • setFeatures

      public void setFeatures(Map<String,LnrpcFeature> features)
    • isKeysend

      public LnrpcInvoice isKeysend(Boolean isKeysend)
    • getIsKeysend

      @Nullable public Boolean getIsKeysend()
      Indicates if this invoice was a spontaneous payment that arrived via keysend [EXPERIMENTAL]. Note: Output only, don't specify for creating an invoice.
      Returns:
      isKeysend
    • setIsKeysend

      public void setIsKeysend(Boolean isKeysend)
    • paymentAddr

      public LnrpcInvoice paymentAddr(byte[] paymentAddr)
    • getPaymentAddr

      @Nullable public byte[] getPaymentAddr()
      The payment address of this invoice. This value will be used in MPP payments, and also for newer invoices that always require the MPP payload for added end-to-end security. Note: Output only, don't specify for creating an invoice.
      Returns:
      paymentAddr
    • setPaymentAddr

      public void setPaymentAddr(byte[] paymentAddr)
    • isAmp

      public LnrpcInvoice isAmp(Boolean isAmp)
    • getIsAmp

      @Nullable public Boolean getIsAmp()
      Signals whether or not this is an AMP invoice.
      Returns:
      isAmp
    • setIsAmp

      public void setIsAmp(Boolean isAmp)
    • ampInvoiceState

      public LnrpcInvoice ampInvoiceState(Map<String,LnrpcAMPInvoiceState> ampInvoiceState)
    • putAmpInvoiceStateItem

      public LnrpcInvoice putAmpInvoiceStateItem(String key, LnrpcAMPInvoiceState ampInvoiceStateItem)
    • getAmpInvoiceState

      @Nullable public Map<String,LnrpcAMPInvoiceState> getAmpInvoiceState()
      Maps a 32-byte hex-encoded set ID to the sub-invoice AMP state for the given set ID. This field is always populated for AMP invoices, and can be used along side LookupInvoice to obtain the HTLC information related to a given sub-invoice. Note: Output only, don't specify for creating an invoice.
      Returns:
      ampInvoiceState
    • setAmpInvoiceState

      public void setAmpInvoiceState(Map<String,LnrpcAMPInvoiceState> ampInvoiceState)
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

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

      public String toString()
      Overrides:
      toString in class Object