Class: PaymentModuleImpl
payment/payment.module.PaymentModuleImpl
Implements
Table of contents
Constructors
Properties
Methods
- getPayerDetails
- observeDebitNotes
- observeInvoices
- createAllocation
- releaseAllocation
- getAllocation
- amendAllocation
- acceptInvoice
- rejectInvoice
- acceptDebitNote
- rejectDebitNote
- createInvoiceProcessor
- createAgreementPaymentProcess
Constructors
constructor
• new PaymentModuleImpl(deps, options?): PaymentModuleImpl
Parameters
| Name | Type |
|---|---|
deps | GolemServices |
options? | PaymentModuleOptions |
Returns
Defined in
src/payment/payment.module.ts:97
Properties
events
• events: EventEmitter<PaymentEvents, any>
Implementation of
Defined in
src/payment/payment.module.ts:83
Methods
getPayerDetails
▸ getPayerDetails(): Promise<PayerDetails>
Get the payment platform and wallet address of the payer.
Returns
Promise<PayerDetails>
Implementation of
Defined in
src/payment/payment.module.ts:126
observeDebitNotes
▸ observeDebitNotes(): Observable<DebitNote>
Returns
Observable<DebitNote>
Implementation of
PaymentModule.observeDebitNotes
Defined in
src/payment/payment.module.ts:132
observeInvoices
▸ observeInvoices(): Observable<Invoice>
Returns
Observable<Invoice>
Implementation of
Defined in
src/payment/payment.module.ts:136
createAllocation
▸ createAllocation(params): Promise<Allocation>
Parameters
| Name | Type |
|---|---|
params | CreateAllocationParams |
Returns
Promise<Allocation>
Implementation of
PaymentModule.createAllocation
Defined in
src/payment/payment.module.ts:140
releaseAllocation
▸ releaseAllocation(allocation): Promise<void>
Parameters
| Name | Type |
|---|---|
allocation | Allocation |
Returns
Promise<void>
Implementation of
PaymentModule.releaseAllocation
Defined in
src/payment/payment.module.ts:162
getAllocation
▸ getAllocation(id): Promise<Allocation>
Parameters
| Name | Type |
|---|---|
id | string |
Returns
Promise<Allocation>
Implementation of
Defined in
src/payment/payment.module.ts:190
amendAllocation
▸ amendAllocation(allocation, _newOpts): Promise<Allocation>
Parameters
| Name | Type |
|---|---|
allocation | Allocation |
_newOpts | CreateAllocationParams |
Returns
Promise<Allocation>
Implementation of
Defined in
src/payment/payment.module.ts:196
acceptInvoice
▸ acceptInvoice(invoice, allocation, amount): Promise<Invoice>
Parameters
| Name | Type |
|---|---|
invoice | Invoice |
allocation | Allocation |
amount | string |
Returns
Promise<Invoice>
Implementation of
Defined in
src/payment/payment.module.ts:207
rejectInvoice
▸ rejectInvoice(invoice, reason): Promise<Invoice>
Parameters
| Name | Type |
|---|---|
invoice | Invoice |
reason | string |
Returns
Promise<Invoice>
Implementation of
Defined in
src/payment/payment.module.ts:235
acceptDebitNote
▸ acceptDebitNote(debitNote, allocation, amount): Promise<DebitNote>
Parameters
| Name | Type |
|---|---|
debitNote | DebitNote |
allocation | Allocation |
amount | string |
Returns
Promise<DebitNote>
Implementation of
Defined in
src/payment/payment.module.ts:251
rejectDebitNote
▸ rejectDebitNote(debitNote, reason): Promise<DebitNote>
Parameters
| Name | Type |
|---|---|
debitNote | DebitNote |
reason | string |
Returns
Promise<DebitNote>
Implementation of
Defined in
src/payment/payment.module.ts:279
createInvoiceProcessor
▸ createInvoiceProcessor(): InvoiceProcessor
Creates an instance of utility class InvoiceProcessor that deals with invoice related use-cases
Returns
Implementation of
PaymentModule.createInvoiceProcessor
Defined in
src/payment/payment.module.ts:300
createAgreementPaymentProcess
▸ createAgreementPaymentProcess(agreement, allocation, options?): AgreementPaymentProcess
Parameters
| Name | Type |
|---|---|
agreement | Agreement |
allocation | Allocation |
options? | Partial<PaymentProcessOptions> |
Returns
Implementation of
PaymentModule.createAgreementPaymentProcess