The Complete claude -p Guide: Turn Claude CLI Into Your Agentic App Backend

Anthropic killed third-party OAuth tokens, leaving the official Claude CLI as the way to use a subscription programmatically. This guide covers claude -p input methods, output formats, JSON schema, tool whitelisting, sessions, streaming, and wrappers.