Skip to content

Commit ed788a7

Browse files
santigamoclaude
andcommitted
debug: log auth method and token prefix on X API requests
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent a78207d commit ed788a7

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

server.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,8 +173,10 @@ async def sign_request(request: httpx.Request) -> None:
173173
request.headers["X-B3-Flags"] = b3_flags
174174
if bearer_token:
175175
request.headers["Authorization"] = f"Bearer {bearer_token}"
176+
LOGGER.info("Auth: app-only Bearer Token (%d chars, starts with %s)", len(bearer_token), bearer_token[:10])
176177
return
177178
await inject_oauth2_access_token(request, oauth_server)
179+
LOGGER.info("Auth: OAuth 2.0 user context")
178180

179181
async def log_request(request: httpx.Request) -> None:
180182
if not debug_enabled:

0 commit comments

Comments
 (0)