Skip to main content
Filter by
Sorted by
Tagged with
-3 votes
0 answers
49 views

I have this code: import requests url = 'some url see below' try: response = requests.request('GET', url, verify=False, timeout=5) print('Response ok.') except Exception as err: errtxt = '...
mangelo's user avatar
0 votes
0 answers
38 views

I am building a WhatsApp bot using FastAPI and UltraMsg. When my webhook receives a message, it generates an AI response and tries to send it back using the requests library. Even though I am ...
Sardar Farhan's user avatar
0 votes
1 answer
73 views

Code written in Python on Mac. Url retrived from inspect in google chrome. Trying to fetch information from an XHR but does not succeed. The print at the end gives the response <Response [405]>. ...
NewDev's user avatar
  • 107
4 votes
2 answers
120 views

I have been trying to make a scraper that downloads comics from Poorly Drawn Lines but I keep on getting a requests.exceptions.ConnectionError: ('Connection aborted.', RemoteDisconnected('Remote end ...
The python duck's user avatar
Best practices
0 votes
1 replies
79 views

I am developing a Python application that interacts with a third-party API. The API enforces strict rate limits, and I want to make sure my application handles these efficiently without causing errors ...
Online Water Bottle's user avatar
Best practices
0 votes
6 replies
90 views

I'm working with a 3rd party API. The API uses an elasticsearch-like query language. So queries can get quiet complex. Often I have such a complex query (eg. long json string) which has 1 or maybe 2 ...
beginner_'s user avatar
  • 7,652
2 votes
2 answers
177 views

I am new to python and programming in general and I got to Chapter 13 of Automate The Boring Stuff With Python which teaches Web Scraping, I succeeded in some projects but I'm having trouble getting ...
Wpythonic's user avatar
0 votes
1 answer
80 views

I am working on automatically storing reports I receive as a download link via email everyday. The cybersecurity company we work with uses Edgepilot (a security proxy) to protect our links so every ...
Jawn's user avatar
  • 11
0 votes
1 answer
87 views

I'm retrieving data from a URL using reqests.get(). My device is connected by wifi. Occasionally, there is no internet access and my appliaction fails with the following error: OSError: [Errno 101] ...
hareti's user avatar
  • 59
Best practices
1 vote
8 replies
114 views

I am making API Calls and expect to get some null responses or NoneTypes. However I am trying to handle them gracefully. This is the default behavior: res = req.json() res.get("key", {})....
Capeya's user avatar
  • 43
0 votes
0 answers
73 views

I’m integrating ERPNext (Frappe Framework) with the Pakistan FBR DI API. I’m facing a strange issue: When I send the request using cURL, the invoice is accepted successfully. When I send the exact ...
Marium Faisal's user avatar
0 votes
1 answer
104 views

I'm building a kind of gallery app. Users are adding images by inserting URLs into the database and the HTML page is then hotlinking those. Obviously, because of link rotting, the gallery is full of ...
Shady Medic's user avatar
Best practices
1 vote
3 replies
92 views

If I need to authenticate with a certificate, I have a few options available: Add the certificate to the bundle packaged with requests/certifi Add the certificate to the system store and override ...
Chris Decker's user avatar
0 votes
0 answers
97 views

When querying the referral sources endpoint on GitHub I'm only getting an empty list returned. I can get data for other endpoints in the same repo, even for other traffic endpoints. I'm expecting ...
mjpeterson's user avatar
3 votes
3 answers
120 views

Calling an api. For almost all calls the response comes clean but for a few there is garbage in the returned json. Executing the garbage one in the Firefox browser with the same parameters returns ...
Clodoaldo Neto's user avatar
0 votes
1 answer
93 views

I'm working on integration tests for a web application that's running in a Docker container within our GitLab CI/CD pipeline. The application is a frontend that requires Kerberos/SPNEGO authentication ...
ben green's user avatar
1 vote
0 answers
55 views

What I found While using the requests library for HTTP requests, I noticed that there were many TCP connections in the FIN_WAIT2 state on the server. Through code analysis, I found that these ...
oyealex's user avatar
  • 11
0 votes
1 answer
168 views

I have a serverless pipeline on Google Cloud. It consists of three total steps: A video uploader that sends videos to Google Cloud Storage. Working fine. An eventarc + pub/sub trigger that fires ...
Raul Chiarella's user avatar
3 votes
1 answer
101 views

I try to post large file and read response as streaming with requests python library. I have to send a large text file (2 million lines of log ) and receive response back as streaming. If I did by ...
mathieu's user avatar
  • 93
0 votes
0 answers
86 views

I am attempting to improve my python by working on a side-project, just interacting with websites to look at avaialble golf tee times. Zero intention/plans to do anything commercial, this is just a ...
tman's user avatar
  • 439
0 votes
0 answers
56 views

I checked a lot of trouble-shoot topics, but didn't find what might be wrong here... (This is a second attempt at fixing this issue, but this time I dug deeper.) I'm going off this API documentation: ...
ErikDB's user avatar
  • 69
1 vote
1 answer
253 views

I’ve been trying to scrape lottery results from a website that shows draws. The data is presented in a results table, but I keep running into strange issues where sometimes the numbers are captured ...
Zuryab's user avatar
  • 11
0 votes
1 answer
200 views

Congress API Down Over the past few days I've been building along term web app that interfaces with the official Congress.gov API (found here),but as of 20 minutes ago, the entire API seems to have ...
ACCE's user avatar
  • 25
2 votes
0 answers
266 views

I am able to post a video from a public URL as a REEL: import requests token = "..." api_version="v23.0" headers = { "Content-Type": "application/json", ...
Physics_Student's user avatar
1 vote
2 answers
323 views

I'm trying to download a protected PDF from the New York State Courts NYSCEF website using Python. The URL looks like this: https://iapps.courts.state.ny.us/nyscef/ViewDocument?docIndex=...
Daremitsu's user avatar
  • 655
0 votes
2 answers
83 views

I wish to use the Sumtracker API, and I want to connect and do a basic get for this endpoint. Let's say that my API key is 1234567890abc. The code is here: import requests url = "https://...
TheFaithfulLearner's user avatar
1 vote
0 answers
67 views

To automate processing of my e-mail messages on MS account, I have registered some application called "NameOfMyRegisteredApplication"; gave it all MS Graph Read rights; and then I ran the ...
Boba's user avatar
  • 43
0 votes
1 answer
120 views

I am trying to download a files from API via Python requests. I cannot emulate a browser despite using the headers. I tried using requests.get(link, headers=headers) and it did not work. I also don't ...
SheperoMah's user avatar
3 votes
0 answers
147 views

The following application performs a basic HTTP GET request against https://google.com, retrieves the peer certificate and saves it in PEM format into a file called cert.pem. After that it attempts ...
jwa's user avatar
  • 3,337
0 votes
1 answer
117 views

I'd like to send an http request, and then operate on its response: import requests s=requests.Session() .... (session setup...) .... (url and params setup...) .... r=s.get(url,params=params) print('...
Tom Grundy's user avatar
  • 1,034
1 vote
1 answer
280 views

I use httpx to make request to my LLM. Here is the code. import httpx import logging import json from httpx import TimeoutException try: content = '' logging.info(f"request payload:{...
haojie's user avatar
  • 783
3 votes
2 answers
387 views

I'm trying to create a script in Python to scrape all available titles that show up when clicking on the black-colored area on the map in this website. For example, when I click on a certain area on ...
MITHU's user avatar
  • 166
1 vote
2 answers
71 views

I have the following payload for the requests module in python and I want to make MAC and NAME a variable as I iterate through a csv of information? Is there a way to do this? payload = '''{ ...
Joseph Jenkins's user avatar
1 vote
0 answers
89 views

Trying to done simple GET request. Site have self-signed certificate. I was export it using Firefox (downloaded chained certificates) as a "pem" file. Here versions of libraries: [user@host]$...
Renat Zaripov's user avatar
0 votes
0 answers
95 views

I'm working on a Python bot that monitors a Shopify webshop, adds a product to the cart, and tries to continue to checkout. I'm using requests.Session() and BeautifulSoup to handle the stock check, ...
Denzel's user avatar
  • 13
0 votes
1 answer
163 views

I’m working on a downloader in Python using requests. My goal is to resume downloading large files after an interruption (e.g., crash or network failure). ✅ My constraints: I already have part of the ...
Subham Saurav's user avatar
0 votes
1 answer
368 views

I need to connect to a websocket in Python, but the problem is that the server where this websocket is located has Cloudflare protection, which blocks the connection to it and returns a 403 error. Try ...
Алексей Иванов's user avatar
0 votes
1 answer
64 views

I am trying to parse link extensions out of a script tag in a webpage loaded with requests. I'm able to request the page and load the script tag as a tag element in BeautifulSoup, it looks like this: {...
Brandon Benton's user avatar
1 vote
0 answers
24 views

I'm testing a function `fetch_recent_klines()` that fetches 1m kline data from the Bybit V5 API. It's designed to **halt and return `[]`** if it receives the same chunk of data twice — to detect stale ...
b-Water's user avatar
  • 11
0 votes
1 answer
36 views

import requests from lxml import html from selenium.webdriver.common.by import By headers = { "user-agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) ...
Roberto Cravioto's user avatar
2 votes
1 answer
140 views

I am intending to specify the single origins where I want my different endpoints to receive requests from. After looking at different options I thought that this might be the simplest way, and it ...
sg_b's user avatar
  • 23
0 votes
0 answers
94 views

I'm having issues when parsing JSON data from an API request. I get all pages from the API request using this code: try: limit = 100 # Max limit per page, can be reduced as needed ...
ZeusTM's user avatar
  • 1
0 votes
0 answers
55 views

I have a platform that I'm building, this platformed is designed to be very modular and each component manages its state, now one key component of my platform is a JWT Token that I have linked to a ...
Samuel Lino's user avatar
0 votes
1 answer
134 views

I have a very sensitive production script that I’ve been running consistently for the past 4 years. This specific function (runAPI) is called about 100 times every day and has never caused any issues —...
user376285's user avatar
1 vote
1 answer
102 views

TLDR: Python request session transmits data to API successfully for six hours and then suddenly only receives ConnectionErrors. Rate limits and other basic errors shouldn't be the issue as the ...
ölkjamin's user avatar
1 vote
1 answer
69 views

I am using Python requests to communicate with an external API. When I do something like: with requests.Session() as sess: resp1 = sess.put( api_url + f"stuff/{id}/endpoint1", ...
Thomas Arildsen's user avatar
0 votes
0 answers
78 views

My goal is to send a batch request of with the conversation id so I could get all the conversations that the user have in their inbox , I tried to read the docs many times but I find their docs ...
Hawanity's user avatar
0 votes
0 answers
48 views

So I'm messing around with the leetcode GRAPHQL api and trying to hit up company endpoints, in the follow synchronous code that I wrote, it works perfectly and the cookie is also saved correctly. It ...
aryan 's user avatar
  • 21
1 vote
1 answer
73 views

I have to make http requests through a proxy which requires ntlm authentication and a specific user agent. Here is the relevant part of the code : headers = {"User-Agent": "...
deb2014's user avatar
  • 219
0 votes
0 answers
512 views

Upon fecthing a large collection item from Postman's API I get the following error: RuntimeError: Chunked transfer error: ('Connection broken: IncompleteRead(50454677 bytes read, 35845891 more ...
Alvaro's user avatar
  • 115

1
2 3 4 5
441