Re: 403 forbidden using API for Readwise - Zotero sync

129 views
Skip to first unread message
Message has been deleted

Dan Stillman

unread,
Jan 11, 2025, 1:24:30 AMJan 11
to zoter...@googlegroups.com
On 1/11/25 1:12 AM, Ben Gook wrote:
I've been using e-alizadeh/Zotero2Readwise: A Python Library to retrieve annotations and notes from Zotero and upload them to your Readwise.

However, in the last week, the sync has stopped working. I've tried both local (desktop) and Github auto sync versions (e-alizadeh/Zotero2Readwise-Sync).

I'm getting the same "forbidden" error in both when I try to access the API.

Here's the error output:
Traceback (most recent call last):
  File "C:\Users\bengo\AppData\Local\Programs\Python\Python312\Lib\site-packages\pyzotero\zotero.py", line 490, in _retrieve_data
    self.request.raise_for_status()
  File "C:\Users\bengo\AppData\Local\Programs\Python\Python312\Lib\site-packages\httpx\_models.py", line 829, in raise_for_status
    raise HTTPStatusError(message, request=request, response=self)
httpx.HTTPStatusError: Client error '400 Bad Request' for url 'https://api.zotero.org/users/33952/items?locale=en-US&itemType=%7B%27annotation%27%7D&since=0&format=json&limit=100'
For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/400

That's not a 403 Forbidden. It's a 400 Bad Request, as you can see in the error you posted, and it's for the reason adamsmith said your forum post — the call should be `itemType=annotation`, not `itemType={'annotation'}`. The response body from the API would also tell you this.

You 'll need to report this to the developer of the tool you're using.
Reply all
Reply to author
Forward
Message has been deleted
0 new messages