Skip to main content

云枢开放服务平台集成SDK工具(Python版)

Project description

云枢开放平台Python版工具使用

调用云枢开放平台接口集成工具,支持RSA数据加密,请求业务接口可集成到客户端系统中

1. 安装与使用

  1. 安装依赖
  • python版本要求:>=3.7.12
pip install open-sdk-py

2. 使用

from open_sdk_py import OpenPlatformClient

# 建立请求云枢客户端
client = OpenPlatformClient.create(
            app_key="企业端key值",
            app_secret="企业端secret值",
            request_url="企业申请能力接口,通过后可在申请详情获取接口地址",
            request_data=data # 请求数据,推荐dict格式或json格式
            headers={} # 【若有】dict类型,包含请求头键值对
        )

# 发送请求
result = client.send()  # type为dict类型

也可以采用链式构建客户端

client = OpenPlatformClient.create(
            app_key="企业端key值",
            app_secret="企业端secret值",
            request_url="企业申请能力接口,通过后可在申请详情获取接口地址")
            .set_request_data({}).set_headers({})

result = client.send()

3. 云枢平台自身错误响应

错误编码 错误信息(含义)
M0411 app_keyapp_secretrequest_url是必填参数,不能为空
M0429 请求次数过多,请稍后重试
M0430 不支持的请求类型
M0500 系统繁忙,请稍后重试
M0555 参数校验失败
M0511 三方服务调用失败
M0512 获取接口信息失败
M0513 响应信息转换失败
M0514 接口请求参数不能为空
M0515 接口请求头不能为空

补充


云枢开放平台地址:https://open.yljr.com

问题反馈联系方式:wantless_wty@163.com

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

open_sdk_py-0.2.1.tar.gz (248.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

open_sdk_py-0.2.1-py3-none-any.whl (248.9 kB view details)

Uploaded Python 3

File details

Details for the file open_sdk_py-0.2.1.tar.gz.

File metadata

  • Download URL: open_sdk_py-0.2.1.tar.gz
  • Upload date:
  • Size: 248.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.4

File hashes

Hashes for open_sdk_py-0.2.1.tar.gz
Algorithm Hash digest
SHA256 11910a8a147d1b1f7d5136595bbb0eeedcf630fcfdb470e072fca4ef09c6f0b6
MD5 139a4e9332138b656a41f78fee49da4c
BLAKE2b-256 ac37d4839bb7c2c35cb639eff905b5b45b9fd0f54680a83b43877c72829748be

See more details on using hashes here.

File details

Details for the file open_sdk_py-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: open_sdk_py-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 248.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.4

File hashes

Hashes for open_sdk_py-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 3884a2224041929dbea708f359b5a738ae443dc5e65c634c4f86fd331c97d1ff
MD5 1eaa5232743a0fdf0ad36025b7a87d23
BLAKE2b-256 1265a2a77b3c8fc157047619d1b67806ce77f9dbc5cfac67b9c943bc19e660bf

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page