yajsapi

Typescript + NodeJS API for Golem

Showing:

Popularity

Downloads/wk

4

GitHub Stars

8

Maintenance

Last Commit

1mo ago

Contributors

7

Package

Dependencies

19

License

LGPL-3.0

Type Definitions

Built-In

Tree-Shakeable

No?

Categories

Readme

yaJSapi

The JS/TS port of yapapi, Golem's Python API

Prerequisites

Building the Library

(not needed for running examples)

Installation

  • run yarn in main folder

Building

  • run yarn build in main folder
  • build is ready in dist folder!

Testing

CommandDescription
yarn test:unitRun all unit test
yarn covShow tests coverage
yarn cov:htmlGeneratedDetailed test coverage report (HTML in coverage directory)
yarn cov:lcovGenerate lcov.info file

Running Examples

Installation

  • cd examples will take you to examples folder
  • yarn will install dependencies for the examples
  • add YAGNA_APPKEY as environment variable;
export YAGNA_APPKEY=your_yagna_app_key_here

When ready

  • npm run js:hello will start hello world javascript example
  • npm run js:blender will start blender javascript example
  • npm run ts:blender will start blender typescript example
  • npm run js:low will start javascript low level api example
  • npm run ts:low will start typescript low level api example
  • npm run ts:yacat will start typescript yacat example

To run yacat using npm, special characters like $ have to be escaped using \, e.g.:

npm run ts:yacat -- --mask '?a?a?a' --hash '\$P\$5ZDzPE45CLLhEx/72qt3NehVzwN2Ry/'

yarn accepts all characters:

yarn run ts:yacat --mask '?a?a?a' --hash '$P$5ZDzPE45CLLhEx/72qt3NehVzwN2Ry/'

Need more logs

Call -d or --debug flag on your example script, e.g. npm run ts:blender -- -d

Subnet

Use the --subnet-tag option, e.g. npm run ts:blender -- --subnet-tag YOUR_SUBNET.

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100