Package net.osslabz.lnd.dto
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 Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddHtlcsItem(LnrpcInvoiceHTLC htlcsItem) addRouteHintsItem(LnrpcRouteHint routeHintsItem) ampInvoiceState(Map<String, LnrpcAMPInvoiceState> ampInvoiceState) amtPaidMsat(String amtPaidMsat) amtPaidSat(String amtPaidSat) cltvExpiry(String cltvExpiry) creationDate(String creationDate) descriptionHash(byte[] descriptionHash) booleanfallbackAddr(String fallbackAddr) features(Map<String, LnrpcFeature> features) The \"add\" index of this invoice.Maps a 32-byte hex-encoded set ID to the sub-invoice AMP state for the given set ID.Deprecated, use amt_paid_sat or amt_paid_msat.The amount that was accepted for this invoice, in millisatoshis.The amount that was accepted for this invoice, in satoshis.Delta to use for the time-lock of the CLTV extended to the final hop.When this invoice was created.byte[]Hash (SHA-256) of a description of the payment.Payment request expiry time in seconds.Fallback on-chain address.List of features advertised on the invoice.getHtlcs()List of HTLCs paying to this invoice [EXPERIMENTAL].getIsAmp()Signals whether or not this is an AMP invoice.Indicates if this invoice was a spontaneous payment that arrived via keysend [EXPERIMENTAL].getMemo()An optional memo to attach along with the invoice.byte[]The payment address of this invoice.A bare-bones invoice for a payment within the Lightning Network.Whether this invoice should include routing hints for private channels.byte[]getrHash()The hash of the preimage.Route hints that can each be individually used to assist in reaching the invoice's destination.byte[]The hex-encoded preimage (32 byte) which will allow settling an incoming HTLC payable to this preimage.Whether this invoice has been fulfilled.When this invoice was settled.The \"settle\" index of this invoice.getState()Get stategetValue()The fields value and value_msat are mutually exclusive.The fields value and value_msat are mutually exclusive.inthashCode()htlcs(List<LnrpcInvoiceHTLC> htlcs) paymentAddr(byte[] paymentAddr) paymentRequest(String paymentRequest) putAmpInvoiceStateItem(String key, LnrpcAMPInvoiceState ampInvoiceStateItem) putFeaturesItem(String key, LnrpcFeature featuresItem) rHash(byte[] rHash) routeHints(List<LnrpcRouteHint> routeHints) rPreimage(byte[] rPreimage) voidsetAddIndex(String addIndex) voidsetAmpInvoiceState(Map<String, LnrpcAMPInvoiceState> ampInvoiceState) voidsetAmtPaid(String amtPaid) voidsetAmtPaidMsat(String amtPaidMsat) voidsetAmtPaidSat(String amtPaidSat) voidsetCltvExpiry(String cltvExpiry) voidsetCreationDate(String creationDate) voidsetDescriptionHash(byte[] descriptionHash) voidvoidsetFallbackAddr(String fallbackAddr) voidsetFeatures(Map<String, LnrpcFeature> features) voidsetHtlcs(List<LnrpcInvoiceHTLC> htlcs) voidvoidsetIsKeysend(Boolean isKeysend) voidvoidsetPaymentAddr(byte[] paymentAddr) voidsetPaymentRequest(String paymentRequest) voidsetPrivate(Boolean _private) voidsetrHash(byte[] rHash) voidsetRouteHints(List<LnrpcRouteHint> routeHints) voidsetrPreimage(byte[] rPreimage) voidsetSettled(Boolean settled) voidsetSettleDate(String settleDate) voidsetSettleIndex(String settleIndex) voidsetState(InvoiceInvoiceState state) settleDate(String settleDate) settleIndex(String settleIndex) voidvoidsetValueMsat(String valueMsat) state(InvoiceInvoiceState state) toString()
-
Field Details
-
SERIALIZED_NAME_MEMO
- See Also:
-
SERIALIZED_NAME_R_PREIMAGE
- See Also:
-
SERIALIZED_NAME_R_HASH
- See Also:
-
SERIALIZED_NAME_VALUE
- See Also:
-
SERIALIZED_NAME_VALUE_MSAT
- See Also:
-
SERIALIZED_NAME_SETTLED
- See Also:
-
SERIALIZED_NAME_CREATION_DATE
- See Also:
-
SERIALIZED_NAME_SETTLE_DATE
- See Also:
-
SERIALIZED_NAME_PAYMENT_REQUEST
- See Also:
-
SERIALIZED_NAME_DESCRIPTION_HASH
- See Also:
-
SERIALIZED_NAME_EXPIRY
- See Also:
-
SERIALIZED_NAME_FALLBACK_ADDR
- See Also:
-
SERIALIZED_NAME_CLTV_EXPIRY
- See Also:
-
SERIALIZED_NAME_ROUTE_HINTS
- See Also:
-
SERIALIZED_NAME_PRIVATE
- See Also:
-
SERIALIZED_NAME_ADD_INDEX
- See Also:
-
SERIALIZED_NAME_SETTLE_INDEX
- See Also:
-
SERIALIZED_NAME_AMT_PAID
- See Also:
-
SERIALIZED_NAME_AMT_PAID_SAT
- See Also:
-
SERIALIZED_NAME_AMT_PAID_MSAT
- See Also:
-
SERIALIZED_NAME_STATE
- See Also:
-
SERIALIZED_NAME_HTLCS
- See Also:
-
SERIALIZED_NAME_FEATURES
- See Also:
-
SERIALIZED_NAME_IS_KEYSEND
- See Also:
-
SERIALIZED_NAME_PAYMENT_ADDR
- See Also:
-
SERIALIZED_NAME_IS_AMP
- See Also:
-
SERIALIZED_NAME_AMP_INVOICE_STATE
- See Also:
-
-
Constructor Details
-
LnrpcInvoice
public LnrpcInvoice()
-
-
Method Details
-
memo
-
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
-
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
-
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
-
getValue
The fields value and value_msat are mutually exclusive.- Returns:
- value
-
setValue
-
valueMsat
-
getValueMsat
The fields value and value_msat are mutually exclusive.- Returns:
- valueMsat
-
setValueMsat
-
settled
-
getSettled
Whether this invoice has been fulfilled. The field is deprecated. Use the state field instead (compare to SETTLED).- Returns:
- settled
-
setSettled
-
creationDate
-
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
-
settleDate
-
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
-
paymentRequest
-
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
-
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
-
getExpiry
Payment request expiry time in seconds. Default is 86400 (24 hours).- Returns:
- expiry
-
setExpiry
-
fallbackAddr
-
getFallbackAddr
Fallback on-chain address.- Returns:
- fallbackAddr
-
setFallbackAddr
-
cltvExpiry
-
getCltvExpiry
Delta to use for the time-lock of the CLTV extended to the final hop.- Returns:
- cltvExpiry
-
setCltvExpiry
-
routeHints
-
addRouteHintsItem
-
getRouteHints
Route hints that can each be individually used to assist in reaching the invoice's destination.- Returns:
- routeHints
-
setRouteHints
-
_private
-
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
-
addIndex
-
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
-
settleIndex
-
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
-
amtPaid
-
getAmtPaid
Deprecated, use amt_paid_sat or amt_paid_msat.- Returns:
- amtPaid
-
setAmtPaid
-
amtPaidSat
-
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
-
amtPaidMsat
-
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
-
state
-
getState
Get state- Returns:
- state
-
setState
-
htlcs
-
addHtlcsItem
-
getHtlcs
List of HTLCs paying to this invoice [EXPERIMENTAL]. Note: Output only, don't specify for creating an invoice.- Returns:
- htlcs
-
setHtlcs
-
features
-
putFeaturesItem
-
getFeatures
List of features advertised on the invoice. Note: Output only, don't specify for creating an invoice.- Returns:
- features
-
setFeatures
-
isKeysend
-
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
-
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
-
getIsAmp
Signals whether or not this is an AMP invoice.- Returns:
- isAmp
-
setIsAmp
-
ampInvoiceState
-
putAmpInvoiceStateItem
-
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
-
equals
-
hashCode
public int hashCode() -
toString
-