op-session

Initialize and manage 1Password CLI sessions for non-TTY subprocess environments.

189|25|Updated Jan 30, 2026
One-click install
npx skills add https://github.com/sd0xdev/sd0x-harness --skill op-session-sd0xdev
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: op-session
Source: https://github.com/sd0xdev/sd0x-harness/tree/main/skills/op-session
Command: npx skills add https://github.com/sd0xdev/sd0x-harness --skill op-session-sd0xdev

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve? Claude Code runs each Bash call in a new subprocess without a TTY, so 1Password CLI's app integration triggers a biometric prompt on every op call. This Skill establishes a reusable session so secrets can be read without repeated authentication prompts. ## Core Features & Use Cases - Dual Auth Mode Detection: Automatically detects whether token-based auth or App Integration auth applies, and configures the session accordingly. - Session Lifecycle Management: Initialize, check status, list accounts, and clear sessions stored in ~/.op-claude-session with owner-only permissions. - Secure Wrapper Script: op-with-session.sh validates the session before every call and injects the correct --session and --account flags per auth mode. - Use Case: A developer needs database credentials from a 1Password vault during a Claude Code session. Run the init script once, then read secrets via the wrapper without further biometric prompts. ## Quick Start Initialize a 1Password session for this project and then read the secret at op://vault/item/field using the session wrapper.

Frequently Asked Questions about op-session

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I stop 1Password CLI from prompting for biometric auth on every op call?▼

Run the op-session-init.sh script once to create a cached session in ~/.op-claude-session. Subsequent op calls through the op-with-session.sh wrapper reuse that session token or app integration mode without new biometric prompts.

How to use 1Password CLI with Claude Code or other AI coding agents?▼

Initialize a session with bash scripts/op-session-init.sh, then route all op commands through scripts/op-with-session.sh. The wrapper handles session loading, validation, and the correct flags for your auth mode automatically.

What is the difference between token mode and App Integration mode in 1Password CLI?▼

Token mode caches a session token on disk and passes it via the --session flag, expiring after 30 minutes idle. App Integration mode stores no token and authenticates through the desktop app via IPC, but fails when the app is locked.

Why does my 1Password session fail when the desktop app is locked?▼

In App Integration mode the CLI communicates with the desktop app over IPC, so a locked app causes op calls to fail. Unlock the 1Password app or rerun the init script to reinitialize the session.

Is the 1Password session token stored securely on disk?▼

The session file is written with umask 077, making it readable only by the owner. Token mode carries moderate risk since the token sits on disk, so clear it with the --clear flag when finished.