1.1.3 • Published 7 years ago

lambdadb-cli v1.1.3

Weekly downloads
-
License
ISC
Repository
-
Last release
7 years ago

LambdaDB

Install

$ npm install -g lambdadb-cli

Getting started

First, you need to sign up to LambdaDB:

$ lambdadb signup

Or, if you already have an account, sign in using:

$ lambdadb login

Creating a database

You can create a database using:

$ lambdadb new <database name>

Then you can desctroy it whenever you want with

$ lambdadb delete <database name>

Listing database

See all your database using:

$ lambdadb list

Accessing your database through a SQL client

To get your SQL credentials just type:

$ lambdadb info

Deploying a lambdadb.json project

Just do:

$ lambdadb deploy

Example

Demo

Using a LambdaDB in your code

var lambdaDB = require('lambdadb')({
    host: 'https://lambdadb.herokuapp.com',
    secretToken: 'my secret token',
    database: 'microservice'
})

// Easily insert into tables
lambdaDB.table('users').insert({
    username: 'user',
    password: 'pass'
}).then(function(response) {
    console.log(response.data) // => logging the trace of the SQL query 
})

// Describe tables
lambdaDB.users.describe().then(function(response) {
    console.log(response.data) // => logging the structure of the database
})

// Do raw operations on your database
lambdaDB.raw('SELECT * FROM users').then(function(response) {
    console.log(response.data) // => logging the rows
})

Visit the LambdaDB client repository to get started.

1.1.3

7 years ago

1.1.2

7 years ago

1.1.1

7 years ago

1.1.0

7 years ago

1.0.9

7 years ago

1.0.8

7 years ago

1.0.7

7 years ago

1.0.5

7 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago