Big News: Socket raises $60M Series C at a $1B valuation to secure software supply chains for AI-driven development.Announcement
Sign In

fusabase-cli

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fusabase-cli

Command-Line Interface to perform Fusabase Console Operations

latest
npmnpm
Version
26.1.1
Version published
Maintainers
1
Created
Source

Oracle® Backend for Firebase (Fusabase) CLI

Command-line interface for managing Fusabase projects over ORDS — authenticate, select a project, and manage backend resources from your terminal.

  • Package: fusabase-cli
  • Binary: fusabase
  • Requires: Node.js 18+

Installation

  • From source (development):

    • Clone this repo
    • npm install
    • npm link
    • fusabase --help
  • From npm (when published): npm i -g fusabase-cli

Getting Started (Quick Start)

  • Configure your ORDS host and schema

Create a fusabase.config.js in the project root (the folder you'll run commands from):

module.exports = {
  host: 'https://<ords-host>/ords/<schema>/'
}

Notes:

  • Include /ords/<schema>/ and keep the trailing slash.
  • If your ORDS is configured with multiple databases, point to the appropriate schema and db pool.
  • This value is used as the base URL for all API calls.
  • Authenticate and set your session
  • Interactive (recommended):

    fusabase init
    

    What it does:

    • Prompts for ORDS clientId and clientSecret (with SQL Developer Role)
    • Exchanges them for an access token and stores it locally (see “Session file” below)
    • Fetches your accessible projects and lets you choose one to use
  • Non‑interactive:

    fusabase login <clientId>:<clientSecret>
    fusabase list-projects
    fusabase use <projectId>
    
  • Run commands against the selected project. See below and fusabase <cmd> --help for details.

Configuration: fusabase.config.js

  • Location: project root
  • Purpose: Set the ORDS base endpoint for the CLI.
  • Example:
module.exports = {
  host: 'https://myhost.example.com/ords/user2/'
}

Troubleshooting:

  • If you see fusabase error: host not set!, ensure fusabase.config.js exists and the host is correct with a trailing slash.

Session file (hidden)

After init or login, the CLI stores transient session state in a hidden file in your project directory.

  • Canonical filename: .fusabase.conf

  • Format (key=value per line):

    access_token=...
    exp=2025-11-06T08:17:24.976Z
    projectId=...
    projectName=...
    

Behavior:

  • Tokens are considered expired slightly early for safety; expired tokens trigger re‑authentication.
  • Delete the file to force a fresh login.

Security:

  • Do not commit this file; add .fusabase.conf to your .gitignore.

Common Commands

All commands support --help for detailed usage and examples.

  • fusabase --help | fusabase --version
  • fusabase init
    • Interactive login + project selection. Stores access token and chosen project in the session file.
  • fusabase login <clientId>:<clientSecret>
    • Direct token exchange. Pair with list-projects and use to select a project.
  • fusabase list-projects
    • Lists projects accessible to the authenticated user.
  • fusabase use <projectId>
    • Sets the current project in the session file.
  • fusabase create-project
    • Prompts for a project name and creates it in the connected schema.

Additional areas (see docs/commands.md or --help for each command):

  • set-auth, auth, set-objs, database, storage, indexes, function, application, cel, member, delete-project, generate

Documentation

Refer to the Documentation here.

Troubleshooting

  • Host not set

    • Error: fusabase error: host not set!
    • Fix: Ensure fusabase.config.js exists and host includes /ords/<schema>/ with trailing slash.
  • Invalid/expired token

    • Errors may include “Invalid or expired token” or prompts to re‑authenticate.
    • Fix: fusabase init or fusabase login <clientId>:<clientSecret> (or delete .fusabase.conf and re‑auth).

Contributing

This project welcomes contributions from the community. Before submitting a pull request, please review our contribution guide.

Security

Please consult the security guide for our responsible security vulnerability disclosure process.

Development

  • Install deps: npm install
  • Run tests: npm test (jest)
  • Format: npm run format

License

Copyright (c) 2015, 2026, Oracle and/or its affiliates.

This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl and Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.

If you elect to accept the software under the Apache License, Version 2.0, the following applies:

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

https://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

FAQs

Package last updated on 15 May 2026

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