avocavo
v1.1.1
Published
Avocavo CLI - Nutrition analysis made simple. Get accurate USDA nutrition data with secure authentication.
Maintainers
Readme
🥑 Avocavo CLI
Nutrition analysis made simple. Get accurate USDA nutrition data with secure authentication.
🚀 Quick Start
# Install globally
npm install -g avocavo
# Login to your account
avocavo login
# Analyze a single ingredient
avocavo ingredient "1 cup rice"
# Analyze a recipe
avocavo recipe -i "2 eggs" "1 cup flour" "1 cup milk"
# Get help
avocavo --help✨ Features
- 🔐 Secure Authentication - Uses system keychain for credential storage
- 🥗 USDA Database - Access to comprehensive nutrition data
- 🧮 Batch Analysis - Analyze multiple ingredients at once
- 📊 Rich Output - Beautiful tables and JSON formats
- 🔒 SSL Security - All connections use verified HTTPS
📦 Installation
npm install -g avocavoRequirements:
- Node.js >= 16.0.0
- npm >= 7.0.0
🔐 Authentication
- Sign up at nutrition.avocavo.app
- Login via CLI:
avocavo login - Your credentials are stored securely in your system keychain
📖 Commands
avocavo login
Authenticate with your Avocavo account via secure OAuth.
avocavo ingredient <ingredient>
Analyze a single ingredient:
avocavo ingredient "1 cup brown rice"
avocavo ingredient "200g chicken breast"
avocavo ingredient "1 cup rice" -v # Include USDA verification URLavocavo recipe [options]
Analyze multiple ingredients as a recipe:
avocavo recipe -i "2 eggs" "1 cup flour" "1/2 cup milk"
avocavo recipe -i "2 cups flour" "1 cup milk" -s 8 # 8 servings
avocavo recipe -f ingredients.txt -s 4 # From file, 4 servingsavocavo batch [options]
Analyze multiple ingredients efficiently:
avocavo batch -i "1 cup rice" "2 tbsp oil" "4 oz chicken"
avocavo batch -f ingredients.txtavocavo keys
Manage API keys:
avocavo keys list # List all API keys
avocavo keys create # Create new API key
avocavo keys create -n "Production" # Create with custom name
avocavo keys switch # Switch active API key
avocavo keys delete # Delete an API keyavocavo status
Show login status and account information.
avocavo health
Check API health and status.
avocavo logout
Remove stored credentials.
🔒 Security
- SSL Verification: All API calls use verified HTTPS connections
- Secure Storage: Credentials stored in system keychain (not plaintext)
- OAuth Flow: Secure browser-based authentication
- No Hardcoded Secrets: All sensitive data handled securely
📊 Output Formats
Table Format (default)
┌─────────────────┬──────────┬─────────┬──────────┬─────────┐
│ Nutrient │ Amount │ Unit │ Per 100g │ % DV │
├─────────────────┼──────────┼─────────┼──────────┼─────────┤
│ Calories │ 365 │ kcal │ 365 │ 18.3% │
│ Protein │ 7.1 │ g │ 7.1 │ 14.2% │
└─────────────────┴──────────┴─────────┴──────────┴─────────┘JSON Format
avocavo ingredient "1 cup rice" --json🆘 Support
- Documentation: nutrition.avocavo.app/docs
- Issues: GitHub Issues
- Email: [email protected]
📄 License
MIT License - see LICENSE file for details.
🔄 Migrating from avocavo-nutrition-cli?
The old package has been deprecated due to security vulnerabilities. Migration is simple:
# Remove old package
npm uninstall -g avocavo-nutrition-cli
# Install new secure package
npm install -g avocavo
# Same commands work!
avocavo login
avocavo ingredient "1 cup rice"