Categorygithub.com/proximax-storage/nem2-sdk-go
modulepackage
0.0.0-20190128134401-f3b97d8c1f63
Repository: https://github.com/proximax-storage/nem2-sdk-go.git
Documentation: pkg.go.dev

# README

nem2-sdk-go

nem2-sdk-go is a Golang client library for Catapult API

Usage

import "github.com/proximax-storage/nem2-sdk-go/sdk"

Create a Catapult network configuration

Using the Testnet network

conf, err := sdk.NewConfig("http://localhost:3000",sdk.Testnet)

Or using the Mainnet network

conf, err := sdk.NewConfig("http://localhost:3000",sdk.Mainnet)

Construct a new Catapult client

client := sdk.NewClient(nil, conf)

Using the client to call a method from a Service API

// Get the chain height
chainHeight, err := client.Blockchain.GetChainHeight(context.Background())

Context

A Context type is the first argument in any service method for specifying deadlines, cancelation signals, and other request-scoped values

// Get the chain height
chainHeight, err := client.Blockchain.GetChainHeight(context.Background())

Wiki / Examples

Examples are in the examples folder

For more examples, go to our wiki

Core Contributors

Contribution

We'd love to get more people involved in the project. Please feel free to raise any issues or PR and we'll review your contribution.

Copyright (c) 2018 ProximaX Limited

# Packages

No description provided by the author
Package sdk provides a client library for the Catapult REST API.
No description provided by the author
No description provided by the author
No description provided by the author