Giter VIP home page Giter VIP logo

airbitz-core-js-ui's Introduction

Airbitz Javascript UI

This repo implements a UI layer on top of airbitz-core-js to provide web applications the interface required to do all the accounts management in just a small handful of Javascript API calls. All UI operates in an overlay iframe on top of the current HTML view.

Build from source repo

npm install to fetch the dependencies.
npm run build to create the web bundle.

Basic usage

Get an API key from

https://developer.airbitz.co

You'll need an account on the Airbitz Mobile App which you can download for iOS and Android at

https://airbitz.co/app

On the developer.airbitz.co page, scan the QR code using the Airbitz Mobile App after signing in and register an email address.

Install from npm

npm install airbitz-core-js-ui --save

or just include this repo somewhere in your server's path.

Include the abcui.js file in your code

<script src="/path-to-abcui/assets/js/abcui.js"></script>

where /path-to-abcui/ leads to the root directory of this repo when accessed via HTTP.

Now start diving in and make some calls

Initialize the library

_abcUi = abcui.makeABCUIContext({'apiKey': 'api-key-here',
                                 'accountType': 'account:repo:com.mydomain.myapp',
                                 'bundlePath': '/path-to-abcui/',
                                 'vendorName': 'My Awesome Project',
                                 'vendorImageUrl': 'https://mydomain.com/mylogo.png'});

Create an overlay popup where a user can register a new account or login to a previously created account via password or PIN.

_abcUi.openLoginWindow(function(error, account) {
  _account = account;
});

Login UI

Launch an account management window for changing password, PIN, and recovery questions

_abcUi.openManageWindow(_account, function(error) {

});

Manage UI

Get a rootkey that can be used as raw entropy for a cryptocurrency master key

Note that this is a temporary API as production API will store keys in an ABCWallet object

_account.repoInfo.dataKey.toString('base64')

Logoff a user

_account.logout();

Sample website repo

See a sample implementation at airbitz-core-js-sample

Detailed Docs

https://developer.airbitz.co/javascript/#airbitz-account-management-ui

airbitz-core-js-ui's People

Contributors

paullinator avatar swansontec avatar teneighty avatar

Watchers

 avatar  avatar  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.