官方SDK文档:https://github.com/KscSDK/ksc-sdk-python

安装

  1. pip install ksc-sdk-python

使用

  1. from kscore.session import get_session
  2. # 密钥
  3. ACCESS_KEY_ID = "your ak"
  4. SECRET_ACCESS_KEY = "your sk"
  5. s = get_session()
  6. client = s.create_client(
  7. "iam", ks_access_key_id=ACCESS_KEY_ID, ks_secret_access_key=SECRET_ACCESS_KEY
  8. )
  9. if __name__ == "__main__":
  10. s = get_session()
  11. client = s.create_client("kec", "cn-beijing-6", use_ssl=False)
  12. client.[your method]()