Skip to content

dn3010/api.js

 
 

Repository files navigation

CENNZNet SDK

The Cennznet JavaScript API library for browsers and Node.js.

Get started

Development guide

Release notes

[27/03/2020] 1.0.0 version:

  • @cennznet/[email protected] (current stage) is working with [cennznet/cennznet:latest][cennznet/cennznet:latest];

Changes made in this version:

  • Derived query for estimating fee is updated.
  • New format to use fee exchange.
    const feeExchange = {
                        assetId: feeAssetId,
                        maxPayment: '50000000000000000',
                    };
                    const transactionPayment = {
                        tip: 2,
                        feeExchange: {
                            FeeExchangeV1: feeExchange,
                        },
                    };
  • CENNZX rpc call to get price queries.
  • Removed plugnet dependencies.
  • Support MultiSignature, registry, discontinue support to v1.

[17/01/2020] Proper document to be added when 1.0.0 final is releasing, here is a quick note:

  • @cennznet/[email protected] is the last version working with cennznet/cennznet:0.*.*;
  • @cennznet/[email protected].* (current stage) is working with [cennznet/cennznet:1.0.0-rc1][cennznet/cennznet:1.0.0-rc1];
  • @cennznet/[email protected].* (next stage) is planned to work with cennznet/cennznet:1.0.0-rc2(to be released);

Changes made in alpha version:

  • Updated Extrinsic types
    • Added ChargeTransactionPayment type, which contains tip (default 0) and FeeExchange (default None);
  • Changed dependencies from @plugnet/api to @polkadot/[email protected] directly (breaking changes were introduced in @polkadot/[email protected], which could be upgraded in beta releases);

Please read the documentation for more.

Components

Name Description
@cennznet/api package that providing the api
@cennznet/wallet a wallet implementation that can be used as signer for api
@cennznet/util cennznet specific utility functions
@cennznet/types cennznet specific type definitions

Cennznet runtime module libraries

Name Description
@cennznet/crml-generic-asset A sdk providing additional features for generic asset runtime module
@cennznet/crml-cennzx-spot A sdk providing additional features for cennzx spot runtime module
@cennznet/crml-attestation A sdk providing additional features for Cennznet's Identity Service.

Examples

docs/examples

About

CENNZNet JS SDK for browsers, React Native and Node.js

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 97.7%
  • JavaScript 1.8%
  • Other 0.5%