sdk

package module
v0.0.0-...-3792732 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 22, 2023 License: Apache-2.0 Imports: 14 Imported by: 0

README ¶

Injective Protocol Golang SDK 🌟


📚 Getting Started

Clone the repository locally and install needed dependencies

$ git clone git@github.com:InjectiveLabs/sdk-go.git
$ cd sdk-go
$ go install ./...

Run examples

# import pk into keyring if you use keyring
injectived keys unsafe-import-eth-key inj-user 5d386fbdbf11f1141010f81a46b40f94887367562bd33b452bbaa6ce1cd1381e

# run chain example
go run examples/chain/0_MsgSend.go

# run exchange example
go run examples/exchange/derivative_exchange_rpc/0_GetOrderbook.go

Updating Exchange API proto and client

$ make copy-exchange-client

(you have to clone this repo into ../injective-indexer)


Publishing Tagged Release

$ git add .
$ git commit -m "bugfix"
$ git tag -a v1.1.1
$ git push origin master --tags

⛑ Support

Reach out to us at one of the following places!


License

Copyright © 2020 - 2022 Injective Labs Inc. (https://injectivelabs.org/)

Originally released by Injective Labs Inc. under:
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/

Documentation ¶

Index ¶

Constants ¶

This section is empty.

Variables ¶

This section is empty.

Functions ¶

func WrapTxToEIP712 ¶

func WrapTxToEIP712(
	cdc codectypes.AnyUnpacker,
	chainID uint64,
	msg cosmtypes.Msg,
	data []byte,
	feeDelegation *FeeDelegationOptions,
) (typeddata.TypedData, error)

WrapTxToEIP712 is an ultimate method that wraps Amino-encoded Cosmos Tx JSON data into an EIP712-compatible request. All messages must be of the same type.

Types ¶

type FeeDelegationOptions ¶

type FeeDelegationOptions struct {
	FeePayer cosmtypes.AccAddress
}

Directories ¶

Path Synopsis
chain
client
tm
ethereum
rpc
exchange
accounts_rpc/pb
Package injective_accounts_rpcpb is a reverse proxy.
Package injective_accounts_rpcpb is a reverse proxy.
auction_rpc/pb
Package injective_auction_rpcpb is a reverse proxy.
Package injective_auction_rpcpb is a reverse proxy.
derivative_exchange_rpc/pb
Package injective_derivative_exchange_rpcpb is a reverse proxy.
Package injective_derivative_exchange_rpcpb is a reverse proxy.
exchange_rpc/pb
Package injective_exchange_rpcpb is a reverse proxy.
Package injective_exchange_rpcpb is a reverse proxy.
explorer_rpc/pb
Package injective_explorer_rpcpb is a reverse proxy.
Package injective_explorer_rpcpb is a reverse proxy.
insurance_rpc/pb
Package injective_insurance_rpcpb is a reverse proxy.
Package injective_insurance_rpcpb is a reverse proxy.
meta_rpc/pb
Package injective_meta_rpcpb is a reverse proxy.
Package injective_meta_rpcpb is a reverse proxy.
oracle_rpc/pb
Package injective_oracle_rpcpb is a reverse proxy.
Package injective_oracle_rpcpb is a reverse proxy.
portfolio_rpc/pb
Package injective_portfolio_rpcpb is a reverse proxy.
Package injective_portfolio_rpcpb is a reverse proxy.
spot_exchange_rpc/pb
Package injective_spot_exchange_rpcpb is a reverse proxy.
Package injective_spot_exchange_rpcpb is a reverse proxy.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL