Skip to content

ccproxy.plugins.claude_sdk.auth

ccproxy.plugins.claude_sdk.auth

No-op auth manager for Claude SDK plugin.

NoOpAuthManager

No-operation auth manager for Claude SDK.

The SDK handles authentication internally through the CLI, so we don't need to manage auth headers.

get_access_token async

get_access_token()

Return empty token since SDK handles auth internally.

Source code in ccproxy/plugins/claude_sdk/auth.py
async def get_access_token(self) -> str:
    """Return empty token since SDK handles auth internally."""
    return ""

get_credentials async

get_credentials()

Return dummy credentials since SDK handles auth internally.

Source code in ccproxy/plugins/claude_sdk/auth.py
async def get_credentials(self) -> ClaudeCredentials:
    """Return dummy credentials since SDK handles auth internally."""
    # Create minimal credentials object with OAuthToken

    oauth_token = ClaudeOAuthToken(
        accessToken=SecretStr("sdk-managed"),
        refreshToken=SecretStr("sdk-managed"),
        expiresAt=None,
        scopes=[],
        subscriptionType="sdk",
    )
    return ClaudeCredentials(claudeAiOauth=oauth_token)

is_authenticated async

is_authenticated()

Always return True since SDK handles auth internally.

Source code in ccproxy/plugins/claude_sdk/auth.py
async def is_authenticated(self) -> bool:
    """Always return True since SDK handles auth internally."""
    return True

get_user_profile async

get_user_profile()

Return None because the SDK does not surface profile metadata.

Source code in ccproxy/plugins/claude_sdk/auth.py
async def get_user_profile(self) -> StandardProfileFields | None:
    """Return ``None`` because the SDK does not surface profile metadata."""
    return None

validate_credentials async

validate_credentials()

Always return True since SDK handles auth internally.

Source code in ccproxy/plugins/claude_sdk/auth.py
async def validate_credentials(self) -> bool:
    """Always return True since SDK handles auth internally."""
    return True

get_provider_name

get_provider_name()

Get the provider name for logging.

Source code in ccproxy/plugins/claude_sdk/auth.py
def get_provider_name(self) -> str:
    """Get the provider name for logging."""
    return "claude-sdk"