New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

bitabase-server

Package Overview
Dependencies
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bitabase-server

Provides a REST data server database via http(s)

1.19.0
latest
npm
Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

bitabase - Server

Build Status David DM GitHub code size in bytes GitHub package.json version GitHub js-semistandard-style

This is a very early attempt at the bitabase rest server.

Getting Started

From the CLI

Running the following:

npm install --global bitabase-server
bitabase-server --help

Will output the below:

📦 Bitabase-Server - v1.15.1
The scalable, sharded database engine.
https://docs.bitabase.com

The following commands and arguments are available when starting Bitabase

Commands:
  start                            Start the bitabase server stack
    --bind-host                    Hostname to bind server to (default: 0.0.0.0)
    --bind-port                    Port to bind server to (default: 8000)
    --rqlite-addr                  Path to contact rqlite
    --database-path                Where to store rqlite transaction log (default: /tmp/sqlite-bitabase)
    --database-keep-alive          How long to keep sqlite database connections alive

No command specified

You can start a bitabase server by running:

bitabase-server start

From NodeJS

const bitabaseServer = require('bitabase-server/server');

const server = bitabaseServer({
  bindHost: '0.0.0.0'
});

server.start();

Endpoints

MethodPathDescription
Collections
Collections are groups of records that belong to a database
1.1POST/v1/databases/:databaseName/collectionsCreate a new collection
1.2GET/v1/databases/:databaseName/collectionsList all collections
1.3GET/v1/databases/:databaseName/collections/:collectionNameRead a specific collections
1.4PUT/v1/databases/:databaseName/collections/:collectionNameUpdate a collection schema
Records
Records are stored in a collection and must adhere to the schema
2.1POST/v1/databases/:databaseName/records/:collectionNameCreate a new record
2.2GET/v1/databases/:databaseName/records/:collectionName?query={}Search through records
2.3DELETE/v1/databases/:databaseName/records/:collectionName?query={}Delete queried records
2.4GET/v1/databases/:databaseName/records/:collectionName/:recordIdGet a specific record
2.5PUT/v1/databases/:databaseName/records/:collectionName/:recordIdUpdate a specific record
2.6PATCH/v1/databases/:databaseName/records/:collectionName/:recordIdPartially update a specific record
2.7DELETE/v1/databases/:databaseName/records/:collectionName/:recordIdDelete a specific record
Logs
When a record method fails a log will be stored containing information on the failure
3.1GET/v1/databases/:databaseName/logs/:collectionNameSearch through logs

License

This project is licensed under the terms of the AGPL-3.0 license.

FAQs

Package last updated on 03 Aug 2020

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