Getting Started
Complete guide to installing and configuring the Nevermined CLI.Prerequisites
Before installing the CLI, ensure you have:- Node.js >= 18.0.0
- npm or yarn package manager
- A Nevermined account with API key
Getting Your API Key
To interact with the Nevermined API, you need an API key. Follow the Get Your API Key guide to create one.Installation
Option 1: Global Installation (Recommended)
Install the CLI globally to use thenvm command from anywhere:
Option 2: Using npx (No Installation)
Run the CLI without installing:Option 3: From Source
For development or contributing:Authentication
Browser Login (Recommended)
The quickest way to authenticate:--environment <env>— Target environment (default: sandbox)--profile <name>— Config profile to save to (default: default)--no-browser— Print the login URL instead of opening the browser
Logout
Remove your API key from the CLI config:Configuration
Interactive Setup
The easiest way to configure the CLI is using the interactive setup:- NVM API Key: Your API key from nevermined.app
- Environment: Choose from:
sandbox- Testing (recommended for learning and development)live- Production environment
Configuration File
The CLI stores configuration in~/.config/nvm/config.json:
Multiple Profiles
Create multiple profiles for different environments or accounts:Environment Variables
Override configuration with environment variables:- CI/CD pipelines
- Temporary configuration changes
- Scripting
View Configuration
Display your current configuration:Verify Setup
Test your configuration by listing available plans:Environment Guide
Choose the right environment for your use case:| Environment | Use Case | Blockchain | Payments |
|---|---|---|---|
sandbox | Development, learning, testing | Test network | Test credits |
live | Production | Mainnet | Real payments |
sandbox for development and testing.
Common Issues
”Command not found: nvm”
After global installation, ifnvm command is not found:
- Verify installation:
npm list -g @nevermined-io/cli - Check your PATH includes npm global bin directory
- Restart your terminal
- Try using the full path:
npx @nevermined-io/cli
”API Key not found”
If you get an API key error:Permission Errors
If you get permission errors during global installation:Next Steps
Now that you’ve installed and configured the CLI, explore:- Plans - Create and manage payment plans
- Agents - Register AI agents
- Purchases - Order plans and make payments
- Querying - Query agents with access tokens
Getting Help
Get help for any command:- Documentation: https://nevermined.ai/docs
- Issues: https://github.com/nevermined-io/payments/issues
- Discord: https://discord.gg/nevermined