# @caelumlabs/comms

> Lorena Communication Protocol

Latest version **0.2.20** (published 2021-01-21) · MIT license · 0 weekly downloads

## Install

```sh
npm install @caelumlabs/comms
pnpm add @caelumlabs/comms
yarn add @caelumlabs/comms
bun add @caelumlabs/comms
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.2.20 |
| Published | 2021-01-21 |
| First published | 2020-06-04 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 7 |
| Unpacked size | 25.1 KB |
| Known vulnerabilities | 0 (+23 in 1 direct dependencies) |
| Install scripts | no |
| Author | Alex Puig |
| Maintainers | alexpuig, chuck-caelum |

## Links

- npm: https://www.npmjs.com/package/@caelumlabs/comms
- npm.io page: https://npm.io/package/@caelumlabs/comms

## Dependencies (7)

- [axios](https://npm.io/package/axios.md) ^0.21.0
- [debug](https://npm.io/package/debug.md) ^4.2.0
- [events](https://npm.io/package/events.md) ^3.2.0
- [threads](https://npm.io/package/threads.md) ^1.6.3
- [axios-retry](https://npm.io/package/axios-retry.md) ^3.1.9
- [observable-fns](https://npm.io/package/observable-fns.md) ^0.5.1
- [@caelumlabs/crypto](https://npm.io/package/@caelumlabs/crypto.md) ^0.2.20

## Recent versions

- 0.2.20 (latest) — 2021-01-21
- 0.2.19 — 2021-01-19
- 0.2.18 — 2020-12-23
- 0.2.17 — 2020-12-17
- 0.2.16 — 2020-12-17
- 0.2.15 — 2020-12-15
- 0.2.14 — 2020-12-10
- 0.2.13 — 2020-12-09
- 0.2.12 — 2020-12-03
- 0.2.11 — 2020-12-02
- 0.2.10 — 2020-12-01
- 0.2.9 — 2020-11-24
- 0.2.8 — 2020-11-18
- 0.2.7 — 2020-11-16
- 0.2.6 — 2020-11-12
- … 24 more at https://npm.io/package/@caelumlabs/comms/versions

## README

# matrix-lib

`matrix-lib` is a caelum api for matrix connection used in `Lorena SSI`.

[![NPM Status](https://img.shields.io/npm/v/@caelumlabs/comms.svg?style=flat)](https://www.npmjs.com/package/@caelumlabs/comms)
[![Build Status](https://travis-ci.org/caelumlabs/lorena.svg?branch=master)](https://travis-ci.org/caelumlabs/comms)
[![Coverage Status](https://coveralls.io/repos/github/Caelumlabs/lorena/badge.svg?branch=master)](https://coveralls.io/github/Caelumlabs/lorena?branch=master)

## Installation

```bash
npm @lorena-ssi/matrix-lib
```

## Getting Started

```javascript
const Comms = require('@caelumlabs/comms')
// Creating class Matrix with parameter `homeserver`
const matrix = new Comms('https://matrix.org')
// Check if user exists
if ( (await matrix.available(username)) ) {
    // Registering to matrix `homeserver` with `username` and `password`
    const primaryUser = await matrix.register('username', 'password')
    // Connecting to account with username `username` and password `password`
    matrix.connect(username, password)
        .then((res)=>{console.log("Connected:", res)})
        .catch((e)=>{console.log("Error:", e)})
    // Read events: If argument=='' then all history events are received
    matrix.events('')
        .then((a,b)=>{console.log("Correct:", a)})
        .catch((e)=>{console.log("Error in events:", e)})
}
```

---
_Source: https://npm.io/package/@caelumlabs/comms · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
