zabo-react-component

1.1.0 • Public • Published

What is Zabo? A unified cryptocurrency API.

NPM JavaScript Style Guide Join the chat at https://gitter.im/zabo-api/community Discord Discourse

Zabo is an API for connecting with cryptocurrency exchanges, wallets and protocols like Bitcoin. Instead of manually integrating with Coinbase API, Binance API, Bitcoin APIs or the hundreds of other cryptocurrency APIs - you can simply use Zabo for them all.

We believe teams and developers should focus on building great products, not worry about the fragmented landscape of exchange APIs and blockchain protocols.

For our updated list of integrations, check out our Zabo integrations.

Zabo React Component

The Zabo React Component provides convenient access to the Zabo API from applications. Please keep in mind that you must register and receive a team id to use in your application.

Install

npm install --save zabo-react-component

Usage

import React, { Component } from 'react'

import Zabo from 'zabo-react-component'

class Example extends Component {
  render () {
    return (
      <Zabo
        clientId='YOUR_CLIENT_ID'
        env='sandbox'
        onInit={team => console.log('Team', team)}
        onError={err => console.log('Error', err)}
        onConnect={(account, zaboInstance) => {
          console.log('Account', account)

          zaboInstance.transactions.getList()
            .then(resp => console.log('Transactions List', resp))
        }}
      />
    )
  }
}

Properties

Name Type Description Required
clientId {string} Key acquired when registering a team in Zabo Dashboard. Required
env {string} Zabo API environment the SDK is connecting with. Could be either sandbox or live. Only sandbox is available unless a live connection is approved. Default: sandbox. Optional
onInit {function (appData[, zaboInstance])} This function is called when the Zabo API is successfully initialized. The first argument is the team data object and the second argument is the Zabo SDK instance. Optional
onConnect {function (accountData[, zaboInstance])} This function is called when the user has successfully authenticated and enabled their account for use by your application. The first argument is the account data object and the second argument is the Zabo SDK instance. Optional
onError {func} This function is called when an error is triggered. Optional

Note: You can also access the Zabo instance via window by simply call window.Zabo.instance.

Documentation

See the Zabo API docs.

Help and Further Information

Please read our docs and reach out to us in any or all of the following forums for questions:

Readme

Keywords

none

Package Sidebar

Install

npm i zabo-react-component

Weekly Downloads

0

Version

1.1.0

License

Apache-2.0

Unpacked Size

427 kB

Total Files

6

Last publish

Collaborators

  • hackdom