Skip to content

Latest commit

 

History

History
48 lines (31 loc) · 1.12 KB

README.md

File metadata and controls

48 lines (31 loc) · 1.12 KB

IOTA SDK Native

TODO

This binding wraps the IOTA SDK into a native, shared library.

It can be referenced by other languages such as Go, C/C++ or C#.

It exports the following functions:

init_logger
binding_get_last_error

call_client_method
call_secret_manager_method
call_utils_method
call_wallet_method

create_client
create_secret_manager
create_wallet
listen_wallet

destroy_client
destroy_secret_manager
destroy_string
destroy_wallet

get_client_from_wallet
get_secret_manager_from_wallet

Generated C/C++ headers can be found under bindings/native/headers.

Headers can be regenerated by running bindings/native/bindgen.sh. This requires cbindgen.

An example implementation in Go can be found here.

Usage

All strings need to be null terminated.

All strings coming from the library need to be free'd by calling destroy_string after receiving and copying them.

Any function that either returns a NULL pointer or false might have catched an error.

This error can be obtained via get_last_error.