npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@optare/optareid-cli

v0.2.2

Published

CLI Tool for Optare ID

Readme

@optare/optareid-cli

Official Command Line Interface for Optare ID - The authentication platform for modern applications.

Quick Start

Installation

# Global installation
npm install -g @optare/optareid-cli

# Or use with npx (no installation required)
npx @optare/optareid-cli --help

Setup

  1. Get your API key from the Optare Dashboard

  2. Set environment variable:

export OPTARE_API_KEY="your-api-key-here"
  1. Verify setup:
optare whoami

Commands

Project Initialization

optare init

Interactive setup for a new Optare project. Creates OAuth client and optionally a product for licensing.

optare init

Prompts:

  • Project name
  • Customer type (B2C or Enterprise)

Generates:

  • OAuth Client ID and Secret
  • Product (for Enterprise mode)
  • .env file with credentials

OAuth Client Management

optare apps list

List all OAuth applications.

optare apps list

optare apps create

Create a new OAuth application.

optare apps create --name "My App" --type web

Options:

  • --name <name> - Application name (required)
  • --type <type> - App type: web, mobile, or service (default: web)

optare apps get <clientId>

Get details of a specific application.

optare apps get client_123

optare apps update <clientId>

Update an application.

optare apps update client_123 --name "New Name" --add-redirect "http://localhost:3000"

optare apps delete <clientId>

Delete an application.

optare apps delete client_123

Organization Management

optare orgs list

List all organizations you are a member of.

optare orgs list

optare orgs create

Create a new organization.

optare orgs create

optare orgs get <orgId>

Get organization details.

optare orgs get org_123

API Key Management

optare keys create

Generate a new API key for server-side or CI/CD usage.

optare keys create --name "CI/CD Pipeline"

Options:

  • --name <name> - Descriptive name for the key (required)

Product Management

optare product create

Create a new product for licensing and subscriptions.

optare product create \
  --name "Pro Plan" \
  --slug "pro" \
  --description "Professional tier" \
  --features sso audit-logs advanced-analytics

Options:

  • --name <name> - Product name (required)
  • --slug <slug> - Unique URL-safe identifier (required)
  • --description <desc> - Product description (optional)
  • --features <features...> - Space-separated feature list (optional)

optare product list

List all products in your organization.

optare product list

optare product get <slug>

Get details of a specific product.

optare product get pro

Subscription Management

optare subscription create

Create a new subscription for an organization.

optare subscription create \
  --organization "org_123" \
  --product "pro" \
  --seats 10 \
  --price 49.99 \
  --cycle monthly \
  --status active

Options:

  • --organization <id> - Organization ID (required)
  • --product <id> - Product ID or slug (required)
  • --seats <number> - Total seat count (required)
  • --price <amount> - Price per seat (required)
  • --cycle <cycle> - monthly or yearly (default: monthly)
  • --status <status> - active, trial, cancelled, or expired (default: active)
  • --endDate <date> - Subscription end date in ISO 8601 format (optional)

optare subscription list

List all subscriptions.

optare subscription list

Billing Management

optare billing connect

Connect a billing provider (Stripe, PayPal, or Razorpay) to your organization.

optare billing connect \
  --provider stripe \
  --secret-key "sk_live_..." \
  --webhook-secret "whsec_..."

Options:

  • --provider <provider> - Billing provider: stripe, paypal, or razorpay (required)
  • --secret-key <key> - Provider API/secret key (required)
  • --webhook-secret <secret> - Webhook signing secret (optional)
  • --sandbox - Use sandbox/test mode (optional)

optare billing portal

Create a self-service customer billing portal session.

optare billing portal --return-url "https://myapp.com/settings"

Options:

  • --return-url <url> - URL to redirect after portal session (default: http://localhost:3000)

Opens the billing portal in your browser automatically.


Utility Commands

optare whoami

Display current authenticated user information.

optare whoami

optare dashboard

Open the Optare Dashboard in your browser.

optare dashboard

Environment Variables

| Variable | Description | Required | |----------|-------------|----------| | OPTARE_API_KEY | Your API key from the dashboard | Yes | | OPTARE_API_URL | API base URL | No (defaults to https://id.optare.one) | | OPTARE_DASHBOARD_URL | Dashboard URL for optare dashboard | No |

Configuration

The CLI stores configuration in ~/.config/optare-cli/config.json (or OS equivalent).

Stored data:

  • API key (if saved via config, not recommended)
  • Last used options

Security: We recommend using environment variables instead of storing the API key in config.

Examples

Full Project Setup

# 1. Set API key
export OPTARE_API_KEY="optk_..."

# 2. Initialize project
optare init

# 3. Create additional OAuth app for staging
optare apps:create --name "My App - Staging" --type web

# 4. Generate CI/CD key
optare keys:create --name "GitHub Actions"

Enterprise Setup with Products

# Create products
optare product:create \
  --name "Starter" \
  --slug "starter" \
  --features basic-support

optare product:create \
  --name "Enterprise" \
  --slug "enterprise" \
  --features sso saml audit-logs priority-support \
  --description "Full enterprise features"

# Create subscription
optare subscription:create \
  --organization "org_xyz" \
  --product "enterprise" \
  --seats 50 \
  --price 99.99 \
  --cycle yearly

Troubleshooting

"OPTARE_API_KEY not set"

Solution: Export your API key:

export OPTARE_API_KEY="your-key-from-dashboard"

Get your key from: https://id.optare.one/portal/settings

"Unauthorized" or 401 errors

Causes:

  • Expired or invalid API key
  • Insufficient permissions

Solution: Generate a new API key from the dashboard

Command not found: optare

Solution:

# Reinstall globally
npm install -g @optare/optareid-cli

# Or use npx
npx @optare/optareid-cli <command>

Documentation

Support

License

MIT