Skip to content
This repository has been archived by the owner on Apr 6, 2023. It is now read-only.

Latest commit

 

History

History
116 lines (70 loc) · 2.12 KB

README.md

File metadata and controls

116 lines (70 loc) · 2.12 KB

⚠️ Depricated repo, please use https://github.com/mindsdb/mindsdb-js-sdk ⚠️

MindsDB

npm version axios install size

JS MindsDB SDK

MindsDB generates metadata about your specific machine learning task, that you can visualize through our graphical user interface MindsDB GUI.

Installing

Using npm:

$ npm install mindsdb-js-sdk

Using yarn:

$ yarn add mindsdb-js-sdk

Install and build

Commands should executed from javascript/ folder.

  1. install dependencies:
yarn
npm install
  1. build:
yarn build
npm run build

Usage

example of usage:

import MindsDB from 'mindsdb-js-sdk';

//connection

const connectData = {
    email : 'user@muser.com', // mindsdb user
    password : '' // mindsdb Password
}

const test = async () => {
    const connect  = await MindsDB.connect(connectData);
    const getFiles = await MindsDB.getFiles();
    const setQuery = await MindsDB.setQuery("SELECT * FROM example_db.demo_data.home_rentals LIMIT 10;");
    
    
    
    console.log('=Get Account Status=>');
    console.log(connect);
    console.log('=Get Files=>');
    console.log(getFiles);
    console.log('=Set Files=>');
    console.log(setQuery);
};

test();

Documentation

root methods

MindsDB.connect(url)

Initialize connection to MindsDB server

params

  • email - mindsdb Email
  • password - mindsdb Password

returns Mindsdb User Info

MindsDB.disconnect()

Clear connection data

returns undefined

MindsDB.setQuery()

Send query

returns query response

License

MIT