Skip to content

dangdennis/flow-elixir-sdk

Repository files navigation

Flex 💪 the Flow Elixir SDK

🚧 Not production ready. At all. 🚧

Elixir client SDK for the Flow blockchain. The goal is to have feature-parity with the officially supported JS and Go SDKs. This may mean having an API for common or all gRPC methods defined at https://docs.onflow.org/access-api#block-headers.

Features

✅ Ping

✅ Execute scripts at latest block

✅ Decode JSON-Cadence Data Interchange Format into a suitable Elixir format

🚧 Block Headers

🚧 Blocks

🚧 Scripts

🚧 Events

🚧 Transactions

🚧 Accounts

Installation

If available in Hex, the package can be installed by adding flow_ex to your list of dependencies in mix.exs:

def deps do
  [
    {:flow_ex, "~> 0.1.0"}
  ]
end

Documentation can be generated with ExDoc and published on HexDocs. Once published, the docs can be found at https://hexdocs.pm/flow_ex.

Learning Resources

Development

  1. Run git submodule init initialize the git submodule.
  2. Run git submodule update --remote to pull the latest commit (though we expect the contracts to infrequently if ever change).
  3. If there are changes to the Flow contracts, re-generate Elixir code from the protobufs. See Protobuf Generation.
  4. Install the Flow CLI.
  5. Run flow emulator start

Protobuf Generation

See Generate Elixir code in Elixir-Protobuf for more details.

  1. brew install protobuf
  2. protoc -I flow/protobuf/ --elixir_out=plugins=grpc:./lib/ flow/protobuf/flow/**/*.proto

About

The Elixir Client SDK for the Flow blockchain

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages