@haechi-labs/henesis-cli
🚀 Command Line Interface tool to Utilize henesis
Last updated 6 days ago by zero1ne .
LGPL3 · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @haechi-labs/henesis-cli 
SYNC missed versions from official npm registry.

henesis-cli

???? Command Line Interface tool to Utilize henesis

License Version Platform ci

Install

To use henesis-cli, Node v10 or higher must be installed.

$ npm install -g @haechi-labs/henesis-cli

$ henesis help

VERSION
  @haechi-labs/henesis-cli/1.0.0-beta.27 darwin-x64 node-v10.16.0

USAGE
  $ henesis [COMMAND]

COMMANDS
  changepw     change password
  help         display help for henesis
  init         create the folder structure required for your project
  integration  manage integrations
  login        perform a login
  logout       perform a logout

Usage

help

Use help as:

  $ henesis help [COMMAND]

For example, you can call help about integration:delete command like:

$ henesis help integration:delete
delete a integration

USAGE
  $ henesis integration:delete [INTEGRATIONID]

EXAMPLE
  $ henesis integration:delete my-integration-id

login

$ henesis login
Allow Henesis to collect anonymous CLI usage and error reporting information
yes(y) or no(n): y
email: yoonsung@haechi.io
password: ***********

???? Login Success from yoonsung@haechi.io ????

init

The directory in which the init command is run must be empty.

$ henesis init -n sample-project
sample-project directory has been created.

After this, the following folder structure is created.

sample_project
├── contracts
│   └── example.sol
└── henesis.yaml

integration

You can use command where the henesis.yaml file exists.

$ henesis integration
manage integrations

USAGE
  $ cli integration:COMMAND

COMMANDS
  integration:delete    delete a integration
  integration:deploy    deploy a integration
  integration:describe  describe a integration
  integration:status    get integrations

There are tasks to be done before the deploy command.

  • Place the contract file distributed in Blockchain inside the contract directory.
  • Modify the henesis.yaml file to match the event you want to subscribe to and place the file with logic in the handler directory.
  • You can run the deploy command and check the status of the distribution through the status command.

integration:delete

Command Line
$ henesis integration:delete <integrationId>

integration:deploy

Command Line
$ henesis integration:deploy
Options
  • -f or --force: Erase existing deployed content and deploy current configuration.
  • -p or --path: Specify where henesis.yaml is located.

integration:describe

Command Line
henesis integration:describe <integrationId>

integration:status

Command Line
henesis integration:describe <integrationId>

change password

You must be logged in to use this feature.

$ henesis changepw
Password: ******
New Password: ******
Again New Password: ******
???? Password changed!

logout

$ henesis logout
???? Logout Success ????

About henesis.yaml

webSocket

version: v1
name: projectname

blockchain:
  platform: ethereum
  network: mainnet
  threshold: 12

filters:
  contracts:
    - address: '0x'
      path: ./contracts/example.sol
      name: example
      compilerVersion: 0.5.8

provider:
  type: webSocket

webhook

version: v1
name: projectname

blockchain:
  platform: ethereum
  network: mainnet
  threshold: 12

filters:
  contracts:
    - address: '0x'
      path: ./contracts/example.sol
      name: example
      compilerVersion: 0.5.8

provider:
  type: webhook
  url: https://localhost:8080
  method: POST
  retry:
    retryDelay: 1000
    maxRetries: 3
  headers:
    Authorization: 'Bearer YOUR-OWN-TOKEN'

parameter details

The following are detailed explanations for parameters used to henesis.yaml.

version & name

The version and name are used as delimiters to identify the project. The name must consist only of lowercase letters, numbers, '-' and '.', the maximum length is 253 characters.

blockchain

The blockchain part is an area that describes the platform and network name of the blockchain in which the smart contract to e subscribed is deployed.

platform

The blockchain platform you want to use.

We support now

  • ethereum
  • klaytn
network

The blockchain network you want to use.

We support now below chains.

platform network chain
ethereum mainnet mainnet
ethereum ropsten ropsten testnet
ethereum rinkeby rinkeby testnet
klaytn mainnet cypress mainnet
klaytn baobob baobob testnet
threshold

Minimum confirmation thresohld which you want to received.

Caution : when receiving data, we wait for a threshold of block confirmation.

filters

The filters part is about information for the smart contracts you want to subscribe through Henesis.

You can subscribe to more than one contract.

contracts
address

Address of smart contract

path

Directory path of solidity file

name

Name of smart contract

compilerVersion

The version of the compiler used when the original file of the deployed smart contract was compiled.

provider

The provider is where you choose how to receive events from Henesis. We support WebSocket and Webhook

The WebSocket doesn't need any settings like url, method, retry, headers.

type

WebSocket or Webhook

url

URL which you want to hook

method

HTTP method like a GET, POST, PUT, DELETE

retry
retryDelay
maxRetries
headers
Authorization

If you want to set authorization (like a JWT), you can set authorization

We also support tutorial.

Current Tags

  • 1.0.0-beta.28                                ...           latest (6 days ago)

27 Versions

  • 1.0.0-beta.28                                ...           6 days ago
  • 1.0.0-beta.27                                ...           14 days ago
  • 1.0.0-beta.26                                ...           14 days ago
  • 1.0.0-beta.24                                ...           19 days ago
  • 1.0.0-beta.23                                ...           20 days ago
  • 1.0.0-beta.22                                ...           23 days ago
  • 1.0.0-beta.20                                ...           3 months ago
  • 1.0.0-beta.19                                ...           3 months ago
  • 1.0.0-beta.18                                ...           3 months ago
  • 1.0.0-beta.17                                ...           3 months ago
  • 1.0.0-beta.16                                ...           3 months ago
  • 1.0.0-beta.15                                ...           3 months ago
  • 1.0.0-beta.14                                ...           4 months ago
  • 1.0.0-beta.13                                ...           4 months ago
  • 1.0.0-beta.12                                ...           4 months ago
  • 1.0.0-beta.11                                ...           4 months ago
  • 1.0.0-beta.10                                ...           4 months ago
  • 1.0.0-beta.9                                ...           4 months ago
  • 1.0.0-beta.8                                ...           4 months ago
  • 1.0.0-beta.7                                ...           4 months ago
  • 1.0.0-beta.6                                ...           4 months ago
  • 1.0.0-beta.5                                ...           4 months ago
  • 1.0.0-beta.4                                ...           4 months ago
  • 1.0.0-beta.3                                ...           4 months ago
  • 1.0.0-beta.2                                ...           4 months ago
  • 1.0.0-beta.1                                ...           4 months ago
  • 1.0.0-beta                                ...           4 months ago
Downloads
Today 0
This Week 0
This Month 143
Last Day 0
Last Week 27
Last Month 18
Dependencies (28)
Dev Dependencies (23)
Dependents (1)

Copyright 2014 - 2016 © taobao.org |