yajsapi - Java Script high-level API
Yagna Contributor Guide

Class: Payment

yajsapi / Exports / rest/payment / Payment

Class: Payment

rest/payment.Payment

Hierarchy

  • Payment

Table of contents

Constructors

Properties

Methods

Constructors

constructor

  • new Payment(cfg: Configuration): Payment

Parameters:

Name

Type

cfg

Configuration

Returns: Payment

Defined in: yajsapi/rest/payment.ts:202

Properties

_api

Private _api: RequestorApi

Defined in: yajsapi/rest/payment.ts:202

Methods

accounts

accounts(): AsyncGenerator

Returns: AsyncGenerator

Defined in: yajsapi/rest/payment.ts:278

allocation

allocation(allocation_id: string): Promise<Allocation>

Parameters:

Name

Type

allocation_id

string

Returns: Promise<Allocation>

Defined in: yajsapi/rest/payment.ts:257

allocations

allocations(): AsyncGenerator<Allocation, any, unknown>

Returns: AsyncGenerator<Allocation, any, unknown>

Defined in: yajsapi/rest/payment.ts:235

debit_note

debit_note(debit_note_id: string): Promise<DebitNote>

Parameters:

Name

Type

debit_note_id

string

Returns: Promise<DebitNote>

Defined in: yajsapi/rest/payment.ts:292

decorate_demand

decorate_demand(ids: string[]): Promise

Parameters:

Name

Type

ids

string[]

Returns: Promise

Defined in: yajsapi/rest/payment.ts:285

incoming_debit_notes

incoming_debit_notes(cancellationToken: any): AsyncGenerator<DebitNote, any, unknown>

Parameters:

Name

Type

cancellationToken

any

Returns: AsyncGenerator<DebitNote, any, unknown>

Defined in: yajsapi/rest/payment.ts:354

incoming_invoices

incoming_invoices(cancellationToken: any): AsyncGenerator<Invoice, any, unknown>

Parameters:

Name

Type

cancellationToken

any

Returns: AsyncGenerator<Invoice, any, unknown>

Defined in: yajsapi/rest/payment.ts:315

invoice

invoice(invoice_id: string): Promise<Invoice>

Parameters:

Name

Type

invoice_id

string

Returns: Promise<Invoice>

Defined in: yajsapi/rest/payment.ts:308

invoices

invoices(): AsyncGenerator<Invoice, any, unknown>

Returns: AsyncGenerator<Invoice, any, unknown>

Defined in: yajsapi/rest/payment.ts:299

new_allocation

new_allocation(amount: number, payment_platform: string, payment_address: string, expires?: null | Date, make_deposit?: boolean): ResourceCtx<Allocation>

Parameters:

Name

Type

Default value

amount

number

-

payment_platform

string

-

payment_address

string

-

expires

null | Date

null

make_deposit

boolean

false

Returns: ResourceCtx<Allocation>

Defined in: yajsapi/rest/payment.ts:208