Skip to main content

requests-base-url

Languate - Python PyPI - License PyPI PyPI - Downloads

Http client with base_url base on requests

Install

pip install requests-base-url

Simple Use

from requests_base_url import http

resp = http.get('https://httpbin.org/get?a=1&b=2')
print(resp)

Config base_url

from requests_base_url import HTTP

http = HTTP(basse_url='https://httpbin.org')
resp = http.get('/get?a=1&b=2')
print(resp)

resp = http.post('/post', data=dict(a=1, b=2))
print(resp)

Config default Headers, Params or Proxies

from requests_base_url import HTTP

http = HTTP(basse_url='https://httpbin.org', headers={"token": "xxx"})
resp = http.get('/get?a=1&b=2')
print(resp)

Metadata

Release files for requests-base-url 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for requests-base-url 0.1.0
File Size Uploaded
requests_base_url-0.1.0.tar.gz 3.2 kB Details

Release files / requests_base_url-0.1.0.tar.gz

Download URL requests_base_url-0.1.0.tar.gz
Size 3.2 kB
Tags Source
SHA-256 checksum
How to use checksums
b55b16647f8ff73a351ff2398741aa37476d6f3cbd08c69d7a50c0217479e30d
BLAKE2b-256 checksum
How to use checksums
a4c6154635300bb692a9a13bc72c32e0f363d55eaa826c54aaf664e0366e90d6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.9.6

Release history Release notifications | RSS feed

This release

0.1.0 This release

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page