New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

basiq-api

Package Overview
Dependencies
Maintainers
2
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

basiq-api

A NodeJS wrapper around the Basiq.io API

latest
Source
npmnpm
Version
0.2.2
Version published
Maintainers
2
Created
Source

Basiq.io Node.js bindings

Travis CI Build Status codecov Code Coverage

Basiq.io API bindings for Node.js

Configuration

The API key can be found on the API Keys tab in the Basiq.io dashboard.

Require

var BasiqAPI = require('basiq-api').BasiqAPI;

var apiOptions = {
  baseURL: 'https://au-api.basiq.io', // optional
  auth: {
    apiKey: 'abc123'
  }
}

var basiq = new BasiqAPI(apiOptions);

Importing

import { BasiqAPI, BasiqAPIOptions, BasiqResponse } from 'basiq-api';

const apiOptions: BasiqAPIOptions = {
  baseURL: 'https://au-api.basiq.io', // optional
  auth: {
    apiKey: 'abc123'
  }
}

const basiq: BasiqAPI = new BasiqAPI(apiOptions);

API Overview

Every resource is accessed via your basiq instance:

// basiq.{ RESOURCE_NAME }.{ METHOD_NAME }

Every resource method returns a promise, which can be chained or used with async/await.

basiq.accounts
  .list('123')
  .then((res: BasiqResponse) => {
    return res.body;
  })
  ;

// where supported
async function getAccounts(connectionId) {
  var resp: BasiqResponse = await basiq.accounts.list(connectionId);
  return resp.body;
}

Available resources and methods

  • connections
    • create(options: ConnectionCreateOptions)
    • refresh(connectionId: string)
    • retrieve(connectionId: string)
    • update(connectionId: string, options: ConnectionUpdateOptions)
    • delete(connectionId: string)
  • accounts
    • retrieve(connectionId: string, accountId: string)
    • list(connectionId:string)
  • transactions
    • retrieve(connectionId: string, transactionId: string)
    • list(connectionId: string)
  • institutions
    • retrieve(institutionId: string)
    • list()

Interfaces

export interface AuthenticationOptions {
  apiKey: string;
}

export interface BasiqAPIOptions {
  baseUrl?: string;
  auth: AuthenticationOptions;
}

export interface ConnectionCreateOptions {
  loginId: string;
  password: string;
  securityCode?: string;
  externalUserId: string;
  institution: {
    id: string;
  };
}

export interface ConnectionUpdateOptions {
  loginId?: string;
  password?: string;
  securityCode?: string;
  externalUserId?: string;
}

export interface BasiqResponse {
  status: number;
  statusText: string;
  body: any;
  headers?: any;
}

Keywords

basiq

FAQs

Package last updated on 05 Oct 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts