Code Monkey home page Code Monkey logo

iota.rs's Introduction

iota.rs

Official Rust library.

๐Ÿšง Alpha Version ๐Ÿšง

This repository now targets Chrysalis part 2 It will have many breaking change along the way. Please use with caution! ๐Ÿšง

The goal of this library is to have one source code of truth, which means there is one implementation in Rust and bindings to other programming languages.

For value transfers we recommend to use wallet.rs.

This alpha version allows you to do the following:

  • Create messages and transactions
  • Sign transactions
  • Generate addresses
  • Interact with an IOTA node

Please report any issues in our issue tracker.

Table of contents
Prerequisites
Using the library
API reference
Examples
Bindings
Supporting the project
Joining the discussion
License

Requirements

To use the library, we recommend you update Rust to latest stable version $ rustup update stable. Nightly should be fine but some changes might not be compatible.

no_std is not currently supported, but we are working on it in bee, and will provide it as feature once the new implementation is ready.

Following dependencies are only required if you use the "mqtt" feature.

Dependencies

cmake and openssl are required. In order to run the build process succesfully using Cargo you might need install additional build tools on your system.

Windows

cmake can be downloaded on the official website and openssl can be installed with vcpkg or chocolatey.

  • Installing openssl with vcpkg:
$ ./vcpkg.exe install openssl:x64-windows
$ ./vcpkg.exe integrate install
# you may want to add this to the system environment variables since you'll need it to compile the crate
$ set VCPKGRS_DYNAMIC=1
  • Installing openssl with chocolatey:
$ choco install openssl
# you may need to set the OPENSSL_DIR environment variable
$ set OPENSSL_DIR="C:\Program Files\OpenSSL-Win64"

macOS

cmake and openssl can be installed with Homebrew:

$ brew install cmake [email protected]

Linux

Install cmake and openssl with your distro's package manager or download from their websites. On Debian and Ubuntu you will also need build-essential.

Using the library

Using the library is easy, just add it as dependancy in Cargo.toml:

[dependencies]
iota-core = { git = "https://github.com/iotaledger/iota.rs", branch = "dev" }

And then you can use the library in your code with iota.

API reference

You can read the API reference here, or generate it yourself.

If you'd like to explore the implementation in more depth, the following command generates docs for the whole crate, including private modules:

cargo doc --document-private-items --no-deps --open

Examples

You can see the examples in the examples directory and try them with:

cargo run --example balance

For the examples where a seed is required you have to rename .env.example to .env.

Bindings

Bindings to other programming languages.

Supporting the project

Joining the discussion

If you want to get involved in the community, need help with setting up, have any issues or just want to discuss IOTA with other people, feel free to join our Discord.

License

The Apache 2.0 license can be found here.

iota.rs's People

Contributors

thoralf-m avatar lucasfernog avatar bingyanglin avatar njaremko avatar cvarley100 avatar samuel-rufi avatar huhn511 avatar rajivshah3 avatar fijter avatar melatron avatar bernardoaraujor avatar laumair avatar jkuruvilla avatar goodengineer avatar alex6323 avatar gotakk avatar kuhlmannmarkus avatar tsvisabo avatar mayjs avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.