Skip to content

Image Attachment Fails with 403 Error #31

Open
@Katehuuh

Description

@Katehuuh

I was unable to send PNG image through the API, return 403 error:

[403] Unable to prepare file attachment -> Image.png
Reason: ��5��..

Code Example unofficial-claude-api version: 0.3.3

from claude_api.client import ClaudeAPIClient
from claude_api.session import SessionData

COOKIE = "user_cookie_here"
USER_AGENT = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36"
ORG_ID = "organization_id_here"

session = SessionData(COOKIE, USER_AGENT, ORG_ID)
client = ClaudeAPIClient(session)
chat_id = client.create_chat()
res = client.send_message(
    chat_id, 
    "Please describe this image.", 
    attachment_paths=["Image.png"]
)
  • Would be great to have settings extended thinking mode.

Metadata

Metadata

Assignees

Labels

bugSomething isn't workinghelp wantedExtra attention is needed

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions