The JavaScript (TypeScript) SDK of Iroha 2 for Node.js, Deno, Bun, and Browsers.
Packages and documentation are available on JSR: https://jsr.io/@iroha
# deno
deno add jsr:@iroha/core
# npm (one of the below, depending on your package manager)
npx jsr add @iroha/core
yarn dlx jsr add @iroha/core
pnpm dlx jsr add @iroha/core
bunx jsr add @iroha/coreimport{Client}from'@iroha/client'import*astypesfrom'@iroha/core/data-model'constkp=types.KeyPair.random()constclient=newClient({toriiBaseURL: newURL('http://localhost:8080'),chain: '000-000',authority: newtypes.AccountId(kp.publicKey(),newtypes.DomainId('wonderland')),authorityPrivateKey: kp.privateKey(),})asyncfunctiontest(){awaitclient.transaction(types.Executable.Instructions([types.InstructionBox.Register.Domain({id: newtypes.Name('wonderland'),logo: null,metadata: [],}),])).submit({verify: true})}See the
"Compatibility" section in @iroha/core package documentation.
See CONTRIBUTING.md