yajsapi - JavaScript high-level API
Yagna Contributor Guide

Class: ActivityService

yajsapi / Exports / rest/activity / ActivityService

Class: ActivityService

rest/activity.ActivityService

A convenience helper to facilitate the creation of an Activity.

Hierarchy

  • ActivityService

Table of contents

Constructors

Properties

Methods

Constructors

constructor

Parameters:

Name

Type

cfg

Configuration

Returns: ActivityService

Defined in: yajsapi/rest/activity.ts:29

Properties

_api

Private _api: RequestorControlApi

Defined in: yajsapi/rest/activity.ts:28

_state

Private _state: RequestorStateApi

Defined in: yajsapi/rest/activity.ts:29

Methods

_attest

_attest(activity_id: string, agreement: Agreement, credentials: Credentials): Promise<void>

Parameters:

Name

Type

activity_id

string

agreement

Agreement

credentials

Credentials

Returns: Promise<void>

Defined in: yajsapi/rest/activity.ts:109

_create_activity

_create_activity(agreement_id: string): Promise<Activity>

Parameters:

Name

Type

agreement_id

string

Returns: Promise<Activity>

Defined in: yajsapi/rest/activity.ts:59

_create_secure_activity

_create_secure_activity(agreement: Agreement): Promise<SecureActivity>

Parameters:

Name

Type

agreement

Agreement

Returns: Promise<SecureActivity>

Defined in: yajsapi/rest/activity.ts:66

new_activity

new_activity(agreement: Agreement, secure?: boolean): Promise<Activity>

Create an activity within bounds of the specified agreement.

Parameters:

Name

Type

Default value

Description

agreement

Agreement

-

-

secure

boolean

false

-

Returns: Promise<Activity>

Activity

Defined in: yajsapi/rest/activity.ts:43