GithubHelp home page GithubHelp logo

matrix-elixir-sdk's Introduction

Matrix Elixir SDK

GitHub Workflow Status Hex.pm License: MIT


A Matrix SDK for Elixir. It is currently in active (and early) development. The docs can be found at https://hexdocs.pm/matrix_sdk.

The library currently provides a simple wrapper around the main endpoints of the Matrix client-server API. There are still many endpoints to be implemented; if you feel like contributing, please don't hesitate to open an issue or a PR (all skill levels welcome)!

Roadmap

In future, the SDK plans to include:

  • an encryption library (currently in development): olm-elixir.
  • further abstractions around the API library to handle state.
  • a wrapper for the Server-Server API
  • & more tbd.

Installation

The package can be installed by adding matrix_sdk to your list of dependencies in mix.exs:

def deps do
  [
    {:matrix_sdk, "~> 0.2.0"}
  ]
end

Basic Usage

To make a request to a Matrix homeserver, you need to create a Request struct. This struct provides all the data to make a request to a specific endpoint of the client-server API. It is then executed with do_request/1.

alias MatrixSDK.API
alias MatrixSDK.API.Request
 
"https://matrix.org"
|> Request.spec_versions()
|> API.do_request()

This example will retreive the versions of the specification supported by the matrix.org homeserver.

The examples also demonstrate usage and can be executed with e.g.: mix run examples/guest_login.exs

matrix-elixir-sdk's People

Contributors

dependabot[bot] avatar fancycade avatar inaniyants avatar niklaslong avatar

Watchers

 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.