
  [![NPM Version](https://img.shields.io/npm/v/futoin-xferengine.svg?style=flat)](https://www.npmjs.com/package/futoin-xferengine)
  [![NPM Downloads](https://img.shields.io/npm/dm/futoin-xferengine.svg?style=flat)](https://www.npmjs.com/package/futoin-xferengine)
  [![Build Status](https://travis-ci.org/futoin/core-js-ri-xferengine.svg?branch=master)](https://travis-ci.org/futoin/core-js-ri-xferengine)
  [![stable](https://img.shields.io/badge/stability-stable-green.svg?style=flat)](https://www.npmjs.com/package/futoin-xferengine)

  [![NPM](https://nodei.co/npm/futoin-xferengine.png?downloads=true&downloadRank=true&stars=true)](https://nodei.co/npm/futoin-xferengine/)

# About

**Work in progress. Technology preview, even though partially used in production.**

Universal cluster focused transaction engine concept implementation.

**Documentation** --> [FutoIn Guide](https://futoin.org/docs/xferengine/)

Reference implementation of:
 
    FTN19: FutoIn Interface - Transaction Engine
    Version: 1.0
    
* Spec: [FTN19: FutoIn Interface - Transaction Engine v1.x](http://specs.futoin.org/draft/preview/ftn19_if_xfer_engine-1.html)

## Features:

* Market cases (aka transaction domains):
    * Deposits & Withdrawals
    * Retail
    * Payments
    * Online Gaming
    * Fee bound to transaction (both deducted & extra)
* Multi-currency
    * ISO fiat currencies
    * Crypto currency namespace
    * Any custom currency namespace
* Advanced limits per transaction domain:
    * Per-account statistics
    * Daily, Weekly, Monthly limits for amounts & transaction count
    * Overdraft for balance
    * Dedicated "External" accounts for integration limits of third-party systems
* Clustering with protocol level interaction
* External Wallet (Seamless Wallet)
* DB-based event stream for reliable state distribution for ad-hoc systems

# Supported database types

* MySQL
* PostgreSQL
* SQLite
* Potentially, any other SQL-compliant supported by `futoin-database`

# BIG FAT WARNING

**Please DO NOT use it unless you really understand what it is. The package is published as essential open source part of derived custom closed source projects of different vendors.**

# Installation for Node.js

Command line:
```sh
$ yarn add futoin-xferengine 
```
or
```sh
$ npm install futoin-xferengine --save
```


# Concept

More detailed concept is in the FTN19 spec.


# Examples

## 1. 

```javascript
```


    
# API documentation

The concept is described in FutoIn specification: [FTN19: FutoIn Interface - Transaction Engine v1.x](http://specs.futoin.org/draft/preview/ftn19_if_xfer_engine-1.html)

{{>main}}


*documented by [jsdoc-to-markdown](https://github.com/75lb/jsdoc-to-markdown)*.


