Skip to content

Instantly share code, notes, and snippets.

@rajrao
Last active November 25, 2024 22:21
Show Gist options
  • Save rajrao/becc05b75a815a1f624fac03b87705c4 to your computer and use it in GitHub Desktop.
Save rajrao/becc05b75a815a1f624fac03b87705c4 to your computer and use it in GitHub Desktop.
Python 3.x debug data being sent as part of a request and the response info
from requests_toolbelt.utils import dump
headers = {'Content-Type': 'application/json'}
response = requests.post(
url,
headers=headers,
json=jdata,
)
print(dump.dump_all(response).decode("utf-8"))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment