Proyectos
Ver en GitHub
qiniu/python-sdk
Acerca de
SDK de almacenamiento de recursos (en la nube) de Qiniu para Python
Herramientas de desarrolloCrecimiento de estrellas medido
- in 24h
- 0
- in 7 days
- 0
- in 15 days
- 0
- in 1 month
- Recopilando historial
Cambios netos en períodos que se solapan, no totales diarios. Los datos no disponibles se dejan en blanco. Las estrellas indican interés, no calidad.
README.md
OriginalQiniu Cloud SDK for Python
安装
通过pip
$ pip install qiniu
运行环境
| Qiniu SDK版本 | Python 版本 |
|---|---|
| 7.x | 2.7, 3.3, 3.4, 3.5, 3.6, 3.7, 3.8, 3.9 |
| 6.x | 2.7 |
使用方法
上传
import qiniu
...
q = qiniu.Auth(access_key, secret_key)
key = 'hello'
data = 'hello qiniu!'
token = q.upload_token(bucket_name)
ret, info = qiniu.put_data(token, key, data)
if ret is not None:
print('All is OK')
else:
print(info) # error message in info
...
更多参见SDK使用指南: https://developer.qiniu.com/kodo/sdk/python
Sandbox
Sandbox 的生命周期、持久快照、模板与请求注入用法见 Sandbox 示例说明。
测试
$ py.test
常见问题
- 第二个参数info保留了请求响应的信息,失败情况下ret 为none, 将info可以打印出来,提交给我们。
- API 的使用 demo 可以参考 examples示例。
- 如果碰到
ImportError: No module named requests.auth请安装requests。
代码贡献
详情参考代码提交指南。
贡献记录
联系我们
- 如果需要帮助,请提交工单(在portal右侧点击咨询和建议提交工单,或者直接向 [email protected] 发送邮件)
- 如果有什么问题,可以到问答社区提问,问答社区
- 更详细的文档,见官方文档站
- 如果发现了bug, 欢迎提交 issue
- 如果有功能需求,欢迎提交 issue
- 如果要提交代码,欢迎提交 pull request
- 欢迎关注我们的微信 微博,及时获取动态信息。
代码许可
The MIT License (MIT).详情见 License文件.
Explorar proyectos relacionados
Cargando…
