Class: DebitNote
payment/debit_note.DebitNote
A Debit Note is an artifact issued by the Provider to the Requestor, in the context of a specific Activity. It is a notification of Total Amount Due incurred by the Activity until the moment the Debit Note is issued. This is expected to be used as trigger for payment in upfront-payment or pay-as-you-go scenarios. NOTE: Only Debit Notes with non-null paymentDueDate are expected to trigger payments. NOTE: Debit Notes flag the current Total Amount Due, which is accumulated from the start of Activity. Debit Notes are expected to trigger payments, therefore payment amount for the newly received Debit Note is expected to be determined by difference of Total Payments for the Agreement vs Total Amount Due.
Hierarchy
BaseDocument<PaymentApi.DebitNoteDTO>↳
DebitNote
Table of contents
Constructors
Properties
- id
- previousDebitNoteId
- timestamp
- activityId
- totalAmountDue
- usageCounterVector
- model
- recipientId
- payeeAddr
- requestorWalletAddress
- paymentPlatform
- agreementId
- paymentDueDate
- status
- provider
Methods
Constructors
constructor
• new DebitNote(model, providerInfo): DebitNote
Parameters
| Name | Type |
|---|---|
model | DebitNote |
providerInfo | ProviderInfo |
Returns
Overrides
Defined in
Properties
id
• Readonly id: string
Overrides
Defined in
previousDebitNoteId
• Optional Readonly previousDebitNoteId: string
Defined in
timestamp
• Readonly timestamp: string
Defined in
activityId
• Readonly activityId: string
Defined in
totalAmountDue
• Readonly totalAmountDue: string
Defined in
usageCounterVector
• Optional Readonly usageCounterVector: object
Defined in
model
• Protected model: DebitNote
Inherited from
Defined in
recipientId
• Readonly recipientId: string
Inherited from
Defined in
src/payment/BaseDocument.ts:19
payeeAddr
• Readonly payeeAddr: string
Inherited from
Defined in
src/payment/BaseDocument.ts:20
requestorWalletAddress
• Readonly requestorWalletAddress: string
Inherited from
BaseDocument.requestorWalletAddress
Defined in
src/payment/BaseDocument.ts:21
paymentPlatform
• Readonly paymentPlatform: string
Inherited from
Defined in
src/payment/BaseDocument.ts:22
agreementId
• Readonly agreementId: string
Inherited from
Defined in
src/payment/BaseDocument.ts:23
paymentDueDate
• Optional Readonly paymentDueDate: string
Inherited from
Defined in
src/payment/BaseDocument.ts:24
status
• Protected status: "ISSUED" | "RECEIVED" | "ACCEPTED" | "REJECTED" | "FAILED" | "SETTLED" | "CANCELLED"
Inherited from
Defined in
src/payment/BaseDocument.ts:26
provider
• Readonly provider: ProviderInfo
Inherited from
Defined in
src/payment/BaseDocument.ts:31
Methods
getPreciseAmount
▸ getPreciseAmount(): Decimal
Returns
Decimal
Defined in
getStatus
▸ getStatus(): "ISSUED" | "RECEIVED" | "ACCEPTED" | "REJECTED" | "FAILED" | "SETTLED" | "CANCELLED"
Tells what's the current status of the document
Returns
"ISSUED" | "RECEIVED" | "ACCEPTED" | "REJECTED" | "FAILED" | "SETTLED" | "CANCELLED"