1Password CLI (op) expert for secrets management and agentic autofill. Use when users need to read secrets, inject credentials, manage vaults, items, service accounts, configure agentic autofill for AI agents, or automate secrets in CI/CD pipelines.
Manages secrets, injects credentials, and automates 1Password CLI operations for CI/CD and agentic workflows.
npx claudepluginhub leobrival/topographic-plugins-officialThis skill is limited to using the following tools:
reference/commands-reference.mdreference/common-patterns.mdreference/troubleshooting.md1Password CLI (op) enables command-line access to secrets, vaults, items, and credential management. It supports biometric authentication, service accounts for automation, and agentic autofill for AI agent workflows. This guide provides essential workflows and quick references for common 1Password operations.
# Check CLI version
op --version
# Authenticate interactively
op signin
# Check current session
op whoami
# List vaults
op vault list
# List items in a vault
op item list --vault Development
# Read a specific secret
op read "op://Development/Database/password"
# Read a single secret
DB_PASSWORD=$(op read "op://Production/Database/password")
# Run a command with secrets injected from env vars
export DB_URL="op://Production/Database/connection-string"
op run -- ./start-server.sh
# Run with secrets from .env file
op run --env-file .env.tpl -- docker compose up -d
# Inject secrets into a config template
op inject --in-file config.yml.tpl --out-file config.yml
# Create a login item
op item create \
--category=login \
--title="Staging API" \
--vault=Development \
--url="https://api.staging.example.com" \
username="admin" \
password="secret123"
# Create with auto-generated password
op item create \
--category=login \
--title="New Service" \
--generate-password='32,letters,digits,symbols'
# Get item details
op item get "Staging API" --vault=Development
# Edit an item field
op item edit "Staging API" password="new-password" --vault=Development
# Delete an item (or archive)
op item delete "Staging API" --vault=Development
op item delete "Staging API" --vault=Development --archive
# Set up service account token (provided by admin)
export OP_SERVICE_ACCOUNT_TOKEN="ops_..."
# Verify service account access
op whoami
# Read secrets in CI pipeline
op read "op://CI-CD/Deploy-Key/private-key" --out-file deploy.pem
chmod 600 deploy.pem
# Inject secrets into deploy config
op run --env-file .env.production -- ./deploy.sh
# Multi-environment with variables
ENV=staging op run -- ./deploy.sh
# Resolves op://$ENV/Database/password -> op://staging/Database/password
# Upload a document
op document create ./cert.pem --title="TLS Certificate" --vault=Infrastructure
# Download a document
op document get "TLS Certificate" --vault=Infrastructure --out-file cert.pem
# Read SSH private key in OpenSSH format
op read "op://Development/SSH-Key/private-key?ssh-format=openssh" --out-file id_ed25519
chmod 600 id_ed25519
# Get OTP code
op read "op://Personal/GitHub/one-time-password?attribute=otp"
# Prerequisites: 1Password desktop app + browser extension installed
# 1. Create login items for services the AI agent will access
op item create \
--category=login \
--title="Service Dashboard" \
--vault="Agent-Credentials" \
--url="https://dashboard.example.com" \
username="agent@example.com" \
password="secure-password"
# 2. For 1Password Business: admin enables the policy
# Settings > Policies > Sharing and permissions
# Enable "Allow AI Agents to autofill for users"
# 3. Pair with Browserbase Director at director.ai
# User authenticates with 1Password during pairing
# 4. Agent requests login via natural language
# "Log in to dashboard.example.com using 1Password"
# User approves via biometric prompt in 1Password desktop app
When to use which command:
op read "op://vault/item/field"op run --env-file .env -- commandop inject --in-file template --out-file outputop item (create, get, list, edit, delete)op document (create, get, list, edit, delete)op vault (create, list, user/group grant/revoke)OP_SERVICE_ACCOUNT_TOKEN# Basic format
op://vault/item/field
# With section
op://vault/item/section/field
# Query parameters
op://vault/item/field?attribute=otp # OTP code
op://vault/item/file.pdf # File attachment
op://vault/item/key?ssh-format=openssh # SSH key format
# Environment variable in reference (multi-env)
op://${ENV}/Database/password
# Create vault
op vault create "Production-Secrets" --description "Production credentials"
# Grant user access
op vault user grant --vault="Production-Secrets" --user="user@example.com" --permissions=allow_viewing
# Grant group access
op vault group grant --vault="Production-Secrets" --group="DevOps" --permissions=allow_viewing,allow_editing
# List vault members
op vault user list --vault="Production-Secrets"
# JSON output (default)
op item get "Database" --format=json
# Specific fields with jq
op item get "Database" --format=json | jq '.fields[] | select(.label=="password") | .value'
# List items as table
op item list --vault=Development --format=json | jq -r '.[] | [.title, .category] | @tsv'
# End-to-end encrypted channel (Noise framework with key rotation)
# Agent CANNOT: list items, modify credentials, access without approval
# Agent CAN: request autofill (user must approve via biometric)
# Per-request approval flow:
# 1. Agent requests login to a URL
# 2. 1Password shows approval dialog with item details
# 3. User authenticates (Touch ID / Windows Hello)
# 4. Credential injected into browser form (never exposed in plaintext)
# 5. Keys rotated after each autofill operation
Common Issues:
Session expired
op signin to re-authenticateService account token invalid
OP_SERVICE_ACCOUNT_TOKEN is set and not expiredSecret reference not found
op item get "ItemName" --vault=VaultNamePermission denied on vault
op vault list and op vault user list --vault=VaultNameAgentic autofill not working
For detailed troubleshooting steps, see the Troubleshooting Guide.
Load as needed for detailed information:
Commands Reference - Complete CLI command documentation with all flags, options, and subcommands. Use when you need exact syntax or flag details for any op command.
Common Patterns - Real-world patterns and workflows for secrets injection, CI/CD automation, multi-environment setups, agentic autofill, and team administration. Use for implementing specific workflows or integrations.
Troubleshooting Guide - Detailed error messages, diagnosis steps, and resolution strategies for authentication, service accounts, secret references, permissions, and agentic autofill. Use when encountering errors or unexpected behavior.
When to use each reference:
Activates when the user asks about AI prompts, needs prompt templates, wants to search for prompts, or mentions prompts.chat. Use for discovering, retrieving, and improving prompts.
Search, retrieve, and install Agent Skills from the prompts.chat registry using MCP tools. Use when the user asks to find skills, browse skill catalogs, install a skill for Claude, or extend Claude's capabilities with reusable AI agent components.
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code, generative art, algorithmic art, flow fields, or particle systems. Create original algorithmic art rather than copying existing artists' work to avoid copyright violations.