User-agent python-httpx Error 1202 (forbidden)
Posted Mar 27, 2023
Hello there,
The pleasure was mine to implement the Firehose API for Zendesk Sell. I wasn't familiar with the Firehose concept but I turns out to be a pleasant way to keep our data in sync.
For the implementation I used https://www.python-httpx.org/ as http client. This library can be seen as the successor of the famous requests library.
After some debugging I discovered that the default user agent (python-httpx) is blocked by Cloudflare.
This is a minimal example to illustrate the problem, a token isn't even required:
curl -v -A "python-httpx/0.23.3" "https://api.getbase.com/v3/contacts/stream" -H "Accept: application/json" -H "Authorization: Bearer {}"
Replacing -A with almost every string is allowed so I bypassed the issue by setting the user agent to "Do not block python-httpX".
Is this something that can be fixed?
Cheers, Jelmer
0
0
0 comments
Sign in to leave a comment.