Skip to content

Releases: Akachain/akc-node-sdk

v2.2.3 Release Notes

02 Dec 03:35
0357fe6
Compare
Choose a tag to compare

This release captures several changes to the node SDK

  • Fix flow Query Service -> return result from the first target's response
  • Fix return format for Query Service

v2.2.2 Release Notes

03 Oct 05:05
dc416a0
Compare
Choose a tag to compare

This release captures several changes to the node SDK

  • Cache client object by username
  • Optimize logging with chaincode
  • Fix several bugs when invoking chaincode with different endorsement policies

v2.1.1 Release Notes

13 Mar 09:18
1f218fa
Compare
Choose a tag to compare

This update add the getDefaultEndorsermentPolicy to utlis.common.js
The default endorsement policy is now forced to be "Signed by all organization"
For example, a default policy for a network with 2 organizations:

{
  identities: [
    { role: { name: "member", mspId: "org1" }},
    { role: { name: "member", mspId: "org2" }}
  ],
  policy: {
    "2-of": [{ "signed-by": 0 }, { "signed-by": 1 }]
  }
}

v2.1.0 Release Notes - February 10, 2020

10 Feb 10:23
Compare
Choose a tag to compare

What's new in akc-node-sdk v2.1.0?

registerUser

View detail

const akcSDK = require('@akachain/akc-node-sdk')

let user = {
    orgName: req.body.orgname,
    userName: req.body.username,
    role: req.body.role,
    maxEnrollments: req.body.maxEnrollments,
    attrs: req.body.attrs
}
await akcSDK.registerUser(user)

enrollUser

View detail

const akcSDK = require('@akachain/akc-node-sdk')

let user = {
    orgName: req.body.orgname,
    userName: req.body.username,
    enrollmentSecret: req.body.password,
} 
await akcSDK.enrollUser(user)

tlsEnroll

View detail

const akcSDK = require('@akachain/akc-node-sdk')

let client = await akcSDK.getClientForOrg(orgName, true);
await akcSDK.tlsEnroll(client)

installChaincode

View detail

const akcSDK = require('@akachain/akc-node-sdk')

await akcSDK.installChaincode(orgname, {
    chaincodePath: chaincodePath,
    chaincodeId: chaincodeId,
    metadataPath: metadataPath,
    chaincodeVersion: chaincodeVersion,
    chaincodeType: chaincodeType
})

initChainCode

View detail

const akcSDK = require('@akachain/akc-node-sdk')

await akcSDK.initChaincode(orgname, channelName, {
    chaincodeId: chaincodeId,
    chaincodeVersion: chaincodeVersion,
    chaincodeType: chaincodeType,
    args: args
})

upgradeChainCode

View detail

const akcSDK = require('@akachain/akc-node-sdk')

await akcSDK.upgradeChaincode(orgname, channelName, {
    chaincodeId: chaincodeId,
    chaincodeVersion: chaincodeVersion,
    chaincodeType: chaincodeType,
    args: args
})

v2.0.3 Release Notes - February 5, 2020

06 Feb 01:35
Compare
Choose a tag to compare

Important Changes

Update query function

View detail

// Pass
var queryChaincode = async function (org_name, channelName, request)

// After changing
var queryChaincode = async function (peerNames, channelName, chaincodeName, fcn, args, orgName, userName)

Re-order parameters when call akcSDK functions.

// Invoke example
const invokeResult = await akcSdk.invoke(peerNames, channelName, chaincodeName, fcn, args, orgName, userName);

akc-node-sdk release

11 Nov 09:00
Compare
Choose a tag to compare

This release incorporate changes from all of our previous development published on Verdacio server at

http://node.sdk.akachain.io:4873/-/web/detail/akc-node-sdk

Please check our installation package on Github NPM registry.