Chinsese version of requests for grasspy
Project description
网络请求 (requests)
介绍
优雅简单的 python requests 库的草蟒中文版
安装方法
python -m pip install -U grasspy-requests
使用简介
GET 基本使用:
>>> 导入 网络请求
>>> 响应 = 网络请求.查_get('https://www.grasspy.cn')
>>> 响应.状态码
200
>>> '中文编程' 在 响应.内容.解码('utf-8')
True
... 或 POST:
>>> 数据 = 字典型(key1='value1', 键2='值2')
>>> 响应 = 网络请求.增_post('https://httpbin.org/post', 数据=数据)
>>> 打印(响应.文本)
{
...
"form": {
"key1": "value1",
"\u952e2": "\u503c2"
},
...
}
当然也支持其他 HTTP 方法.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
grasspy-requests-0.2.2271.tar.gz
(17.2 kB
view hashes)
Built Distribution
Close
Hashes for grasspy-requests-0.2.2271.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4f4672ea8d8d82839251110d40b69d03cde890cf034bf065d5253516b7fee476 |
|
MD5 | 417144bc6e56f59976bef22d244def01 |
|
BLAKE2b-256 | 202918bc9a7724268e057979c892322378611ed012baa4d03612af4d836e8d57 |
Close
Hashes for grasspy_requests-0.2.2271-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3d4b99a868d360774c74f79c581826c864eb3dfde7e6724de8a09757ce8e4ba7 |
|
MD5 | d929c87e2ba0427ecd61833da1271b85 |
|
BLAKE2b-256 | d5c9398d08bfc2fa70437a3617d648239c7b1e8a22e081a3523c6b598ee4d6c4 |