JS API Reference

Class: Yagna

utils/yagna/yagna.Yagna

Table of contents

Constructors

Properties

Methods

Constructors

constructor

new Yagna(options?): Yagna

Parameters

NameType
options?YagnaOptions

Returns

Yagna

Defined in

src/utils/yagna/yagna.ts:67

Properties

apiKey

Protected Readonly apiKey: string

Defined in

src/utils/yagna/yagna.ts:59


apiBaseUrl

Protected Readonly apiBaseUrl: string

Defined in

src/utils/yagna/yagna.ts:60

Methods

getApi

getApi(): YagnaApi

Returns

YagnaApi

Defined in

src/utils/yagna/yagna.ts:79


connect

connect(): Promise<IdentityModel>

Returns

Promise<IdentityModel>

Defined in

src/utils/yagna/yagna.ts:83


end

end(): Promise<void>

Returns

Promise<void>

Defined in

src/utils/yagna/yagna.ts:110


getVersion

getVersion(): Promise<string>

Returns

Promise<string>

Defined in

src/utils/yagna/yagna.ts:117


createApi

createApi(): YagnaApi

Returns

YagnaApi

Defined in

src/utils/yagna/yagna.ts:130


getApiConfig

getApiConfig(): Configuration

Returns

Configuration

Defined in

src/utils/yagna/yagna.ts:154


getApiUrl

getApiUrl(apiName?): string

Parameters

NameType
apiName?string

Returns

string

Defined in

src/utils/yagna/yagna.ts:165


errorHandler

errorHandler(error): Promise<Error>

Parameters

NameType
errorError

Returns

Promise<Error>

Defined in

src/utils/yagna/yagna.ts:169


addErrorHandler

addErrorHandler(api): number

Parameters

NameType
apiYagnaApi

Returns

number

Defined in

src/utils/yagna/yagna.ts:182


removeErrorHandler

removeErrorHandler(api): void

Parameters

NameType
apiYagnaApi

Returns

void

Defined in

src/utils/yagna/yagna.ts:194