CLI Setup
Get started with the Fiberwise CLI to deploy and manage your apps from the command line.
Overview
The Fiberwise CLI provides powerful tools for app development and deployment. It enables you to:
- Deploy apps to your Fiberwise instance
- Configure OAuth authenticators
- Manage multiple environment configurations
- Version management and automatic increments
Installation
The Fiberwise CLI is included with your Fiberwise installation. If you're developing apps locally, make sure you have the Fiberwise development environment set up.
📦 Installation Requirements
- Python 3.8 or higher
- Access to a Fiberwise instance (local or hosted)
- Valid API key for authentication
API Key Setup
Your CLI is authenticated with a Fiberwise API key. You'll need to generate an API key from your Fiberwise instance before using the CLI.
🔑 Getting Your API Key
- Log into your Fiberwise instance
- Navigate to Settings → API Keys
- Click "Create New API Key"
- Give it a descriptive name (e.g., "Development CLI")
- Copy the generated API key
⚠️ Important: Store your API key securely. It won't be shown again after creation.
CLI Configuration
Configure the CLI with your instance details and API key using the fiber account add-config
command.
Adding a Configuration Profile
fiber account add-config \
--name "production" \
--api-key "your-api-key-here" \
--base-url "https://your-instance.fiberwise.ai" \
--set-default
Command Options:
Configuration Storage
CLI configurations are stored in:
- Configuration files:
~/.fiberwise/configs/{name}.json
- Default profile:
~/.fiberwise/default_config.txt
Multiple Environments
You can configure multiple environments (development, staging, production) and switch between them.
Setting Up Multiple Profiles
# Development environment
fiber account add-config \
--name "development" \
--api-key "dev-api-key" \
--base-url "http://localhost:5757"
# Staging environment
fiber account add-config \
--name "staging" \
--api-key "staging-api-key" \
--base-url "https://staging.yourcompany.com"
# Production environment
fiber account add-config \
--name "production" \
--api-key "prod-api-key" \
--base-url "https://api.yourcompany.com" \
--set-default
Using Specific Configurations
Target specific environments when deploying:
# Deploy to specific environment
fiberwise deploy --to-instance development
# Deploy to staging
fiberwise deploy --to-instance staging
# Deploy to default (production)
fiberwise deploy
Basic CLI Commands
Once configured, you can use these essential CLI commands:
Deploy an App
fiberwise deploy /path/to/your/app
Deploys your app to the configured Fiberwise instance.
OAuth Configuration
fiber app oauth import /path/to/oauth-config.json
Import OAuth authenticator configurations for your apps.
Version Management
# Auto-increment patch version
fiberwise deploy /path/to/app
# Increment minor version
fiberwise deploy /path/to/app --version-increment minor
# Skip version increment
fiberwise deploy /path/to/app --no-version-increment
Troubleshooting
Common Issues
❌ "No configuration found"
Solution: Make sure you've run fiber account add-config
with valid credentials.
❌ "Authentication failed"
Solution: Check that your API key is correct and hasn't expired. Generate a new one if needed.
❌ "Connection refused"
Solution: Verify your base URL is correct and the Fiberwise instance is running.
Getting Help
# General help
fiberwise --help
# Command-specific help
fiberwise deploy --help
fiber account add-config --help