Class: Invoice
payment/invoice.Invoice
An Invoice is an artifact issued by the Provider to the Requestor, in the context of a specific Agreement. It indicates the total Amount owed by the Requestor in this Agreement. No further Debit Notes shall be issued after the Invoice is issued. The issue of Invoice signals the Termination of the Agreement (if it hasn't been terminated already). No Activity execution is allowed after the Invoice is issued.
Hierarchy
BaseDocument
<PaymentApi.InvoiceDTO
>↳
Invoice
Table of contents
Constructors
Properties
- activityIds
- amount
- timestamp
- recipientId
- model
- payeeAddr
- requestorWalletAddress
- paymentPlatform
- agreementId
- paymentDueDate
- status
- id
- provider
Methods
Constructors
constructor
• new Invoice(model
, providerInfo
): Invoice
Parameters
Name | Type |
---|---|
model | Invoice |
providerInfo | ProviderInfo |
Returns
Overrides
Defined in
Properties
activityIds
• Optional
Readonly
activityIds: string
[]
Activities IDs covered by this Invoice
Defined in
amount
• Readonly
amount: string
Amount in the invoice
Defined in
timestamp
• Readonly
timestamp: string
Invoice creation timestamp
Defined in
recipientId
• Readonly
recipientId: string
Recipient ID
Overrides
Defined in
model
• Protected
model: Invoice
Inherited from
Defined in
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
id
• Readonly
id: string
Inherited from
Defined in
src/payment/BaseDocument.ts:29
provider
• Readonly
provider: ProviderInfo
Inherited from
Defined in
src/payment/BaseDocument.ts:31
Methods
getPreciseAmount
▸ getPreciseAmount(): Decimal
Returns
Decimal
Defined in
isSameAs
▸ isSameAs(invoice
): boolean
Compares two invoices together and tells if they are the same thing
Parameters
Name | Type |
---|---|
invoice | Invoice |
Returns
boolean
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"
Inherited from
Defined in
Was this helpful?