zscaler-sdk-python 2.0.0__tar.gz → 2.0.0b2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (440) hide show
  1. zscaler_sdk_python-2.0.0b2/PKG-INFO +928 -0
  2. zscaler_sdk_python-2.0.0b2/README.md +881 -0
  3. zscaler_sdk_python-2.0.0b2/pyproject.toml +112 -0
  4. zscaler_sdk_python-2.0.0b2/setup.cfg +4 -0
  5. zscaler_sdk_python-2.0.0b2/zscaler_sdk_python.egg-info/PKG-INFO +928 -0
  6. zscaler_sdk_python-2.0.0b2/zscaler_sdk_python.egg-info/SOURCES.txt +102 -0
  7. zscaler_sdk_python-2.0.0b2/zscaler_sdk_python.egg-info/dependency_links.txt +1 -0
  8. zscaler_sdk_python-2.0.0b2/zscaler_sdk_python.egg-info/requires.txt +25 -0
  9. zscaler_sdk_python-2.0.0b2/zscaler_sdk_python.egg-info/top_level.txt +1 -0
  10. zscaler_sdk_python-2.0.0b2/zssdk/__init__.py +55 -0
  11. zscaler_sdk_python-2.0.0/zscaler/zwa/zwa_service.py → zscaler_sdk_python-2.0.0b2/zssdk/__version__.py +1 -25
  12. zscaler_sdk_python-2.0.0b2/zssdk/session.py +267 -0
  13. zscaler_sdk_python-2.0.0b2/zssdk/session.pyi +59 -0
  14. zscaler_sdk_python-2.0.0b2/zssdk/zscore/__init__.py +98 -0
  15. zscaler_sdk_python-2.0.0b2/zssdk/zscore/args.py +57 -0
  16. zscaler_sdk_python-2.0.0b2/zssdk/zscore/auth.py +98 -0
  17. zscaler_sdk_python-2.0.0b2/zssdk/zscore/case.py +118 -0
  18. zscaler_sdk_python-2.0.0b2/zssdk/zscore/client.py +544 -0
  19. zscaler_sdk_python-2.0.0b2/zssdk/zscore/config.py +180 -0
  20. zscaler_sdk_python-2.0.0b2/zssdk/zscore/configloader.py +84 -0
  21. zscaler_sdk_python-2.0.0b2/zssdk/zscore/configprovider.py +153 -0
  22. zscaler_sdk_python-2.0.0b2/zssdk/zscore/credentials.py +266 -0
  23. zscaler_sdk_python-2.0.0b2/zssdk/zscore/csv_utils.py +212 -0
  24. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/_errors.json +14 -0
  25. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/_retry.json +85 -0
  26. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/endpoints.json +38 -0
  27. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/exception.json +46 -0
  28. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/zcc/v1/paginators-1.json +102 -0
  29. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/zcc/v1/service-1.json +5815 -0
  30. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/zdx/v1/paginators-1.json +60 -0
  31. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/zdx/v1/service-1.json +3981 -0
  32. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/zia/v1/errors-1.json +40 -0
  33. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/zia/v1/paginators-1.json +396 -0
  34. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/zia/v1/service-1.json +30535 -0
  35. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/zid/v1/paginators-1.json +46 -0
  36. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/zid/v1/service-1.json +1677 -0
  37. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/zpa/v1/paginators-1.json +326 -0
  38. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/zpa/v1/service-1.json +17746 -0
  39. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/ztw/v1/errors-1.json +40 -0
  40. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/ztw/v1/paginators-1.json +137 -0
  41. zscaler_sdk_python-2.0.0b2/zssdk/zscore/data/ztw/v1/service-1.json +7737 -0
  42. zscaler_sdk_python-2.0.0b2/zssdk/zscore/endpoint.py +110 -0
  43. zscaler_sdk_python-2.0.0b2/zssdk/zscore/errorfactory.py +210 -0
  44. zscaler_sdk_python-2.0.0b2/zssdk/zscore/errorutils.py +297 -0
  45. zscaler_sdk_python-2.0.0b2/zssdk/zscore/exceptions.py +589 -0
  46. zscaler_sdk_python-2.0.0b2/zssdk/zscore/handlers.py +58 -0
  47. zscaler_sdk_python-2.0.0b2/zssdk/zscore/hooks.py +302 -0
  48. zscaler_sdk_python-2.0.0b2/zssdk/zscore/httpsession.py +225 -0
  49. zscaler_sdk_python-2.0.0b2/zssdk/zscore/loaders.py +136 -0
  50. zscaler_sdk_python-2.0.0b2/zssdk/zscore/logger.py +737 -0
  51. zscaler_sdk_python-2.0.0b2/zssdk/zscore/model.py +205 -0
  52. zscaler_sdk_python-2.0.0b2/zssdk/zscore/paginate.py +351 -0
  53. zscaler_sdk_python-2.0.0b2/zssdk/zscore/parsers.py +440 -0
  54. zscaler_sdk_python-2.0.0b2/zssdk/zscore/regions.py +52 -0
  55. zscaler_sdk_python-2.0.0/zscaler/zpa/models/auth_domain.py → zscaler_sdk_python-2.0.0b2/zssdk/zscore/request.py +15 -17
  56. zscaler_sdk_python-2.0.0b2/zssdk/zscore/response.py +99 -0
  57. zscaler_sdk_python-2.0.0b2/zssdk/zscore/retry.py +371 -0
  58. zscaler_sdk_python-2.0.0b2/zssdk/zscore/serialize.py +499 -0
  59. zscaler_sdk_python-2.0.0b2/zssdk/zscore/session.py +389 -0
  60. zscaler_sdk_python-2.0.0b2/zssdk/zscore/session.pyi +33 -0
  61. zscaler_sdk_python-2.0.0b2/zssdk/zscore/stub.py +225 -0
  62. zscaler_sdk_python-2.0.0b2/zssdk/zscore/tokenprovider.py +146 -0
  63. zscaler_sdk_python-2.0.0b2/zssdk/zscore/useragent.py +81 -0
  64. zscaler_sdk_python-2.0.0b2/zssdk/zscore/utils.py +124 -0
  65. zscaler_sdk_python-2.0.0b2/zssdk/zscore/validate.py +132 -0
  66. zscaler_sdk_python-2.0.0b2/zssdk/zscore/zcc_client.pyi +875 -0
  67. zscaler_sdk_python-2.0.0b2/zssdk/zscore/zdx_client.pyi +188 -0
  68. zscaler_sdk_python-2.0.0b2/zssdk/zscore/zia_client.pyi +5980 -0
  69. zscaler_sdk_python-2.0.0b2/zssdk/zscore/zid_client.pyi +458 -0
  70. zscaler_sdk_python-2.0.0b2/zssdk/zscore/zpa_client.pyi +3478 -0
  71. zscaler_sdk_python-2.0.0b2/zssdk/zscore/ztw_client.pyi +584 -0
  72. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/__init__.py +74 -0
  73. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/action.py +118 -0
  74. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/base.py +196 -0
  75. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/base.pyi +12 -0
  76. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/collection.py +475 -0
  77. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/collection.pyi +29 -0
  78. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/data/zcc/v1/resources-1.json +7052 -0
  79. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/data/zdx/v1/resources-1.json +3600 -0
  80. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/data/zia/v1/resources-1.json +46276 -0
  81. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/data/zid/v1/resources-1.json +1678 -0
  82. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/data/zpa/v1/resources-1.json +26043 -0
  83. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/data/ztw/v1/resources-1.json +10816 -0
  84. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/dictionary.py +127 -0
  85. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/dictionary.pyi +16 -0
  86. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/exception_factory.py +160 -0
  87. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/exceptions.py +236 -0
  88. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/exceptions.pyi +42 -0
  89. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/factory.py +1112 -0
  90. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/params.py +66 -0
  91. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/response.py +173 -0
  92. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/service.py +84 -0
  93. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/service.pyi +14 -0
  94. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/subresource.py +469 -0
  95. zscaler_sdk_python-2.0.0/zscaler/__init__.py → zscaler_sdk_python-2.0.0b2/zssdk/zsresource/utils.py +8 -15
  96. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/validation.py +91 -0
  97. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/zcc_resources.pyi +2683 -0
  98. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/zdx_resources.pyi +933 -0
  99. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/zia_resources.pyi +12486 -0
  100. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/zid_resources.pyi +633 -0
  101. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/zpa_resources.pyi +6947 -0
  102. zscaler_sdk_python-2.0.0b2/zssdk/zsresource/ztw_resources.pyi +2330 -0
  103. zscaler_sdk_python-2.0.0/PKG-INFO +0 -1107
  104. zscaler_sdk_python-2.0.0/README.md +0 -1067
  105. zscaler_sdk_python-2.0.0/pyproject.toml +0 -85
  106. zscaler_sdk_python-2.0.0/zscaler/api_client.py +0 -70
  107. zscaler_sdk_python-2.0.0/zscaler/cache/cache.py +0 -105
  108. zscaler_sdk_python-2.0.0/zscaler/cache/no_op_cache.py +0 -60
  109. zscaler_sdk_python-2.0.0/zscaler/cache/zscaler_cache.py +0 -171
  110. zscaler_sdk_python-2.0.0/zscaler/config/__init__.py +0 -0
  111. zscaler_sdk_python-2.0.0/zscaler/config/config_setter.py +0 -195
  112. zscaler_sdk_python-2.0.0/zscaler/config/config_validator.py +0 -173
  113. zscaler_sdk_python-2.0.0/zscaler/constants.py +0 -46
  114. zscaler_sdk_python-2.0.0/zscaler/error_messages.py +0 -46
  115. zscaler_sdk_python-2.0.0/zscaler/errors/__init__.py +0 -0
  116. zscaler_sdk_python-2.0.0/zscaler/errors/error.py +0 -10
  117. zscaler_sdk_python-2.0.0/zscaler/errors/http_error.py +0 -20
  118. zscaler_sdk_python-2.0.0/zscaler/errors/zscaler_api_error.py +0 -28
  119. zscaler_sdk_python-2.0.0/zscaler/exceptions/__init__.py +0 -1
  120. zscaler_sdk_python-2.0.0/zscaler/exceptions/exceptions.py +0 -101
  121. zscaler_sdk_python-2.0.0/zscaler/helpers.py +0 -154
  122. zscaler_sdk_python-2.0.0/zscaler/logger.py +0 -124
  123. zscaler_sdk_python-2.0.0/zscaler/oneapi_client.py +0 -445
  124. zscaler_sdk_python-2.0.0/zscaler/oneapi_collection.py +0 -16
  125. zscaler_sdk_python-2.0.0/zscaler/oneapi_http_client.py +0 -419
  126. zscaler_sdk_python-2.0.0/zscaler/oneapi_oauth_client.py +0 -239
  127. zscaler_sdk_python-2.0.0/zscaler/oneapi_object.py +0 -77
  128. zscaler_sdk_python-2.0.0/zscaler/oneapi_response.py +0 -286
  129. zscaler_sdk_python-2.0.0/zscaler/ratelimiter/__init__.py +0 -0
  130. zscaler_sdk_python-2.0.0/zscaler/ratelimiter/ratelimiter.py +0 -60
  131. zscaler_sdk_python-2.0.0/zscaler/request_executor.py +0 -579
  132. zscaler_sdk_python-2.0.0/zscaler/user_agent.py +0 -21
  133. zscaler_sdk_python-2.0.0/zscaler/utils.py +0 -845
  134. zscaler_sdk_python-2.0.0/zscaler/zcc/__init__.py +0 -0
  135. zscaler_sdk_python-2.0.0/zscaler/zcc/admin_user.py +0 -266
  136. zscaler_sdk_python-2.0.0/zscaler/zcc/company.py +0 -71
  137. zscaler_sdk_python-2.0.0/zscaler/zcc/devices.py +0 -479
  138. zscaler_sdk_python-2.0.0/zscaler/zcc/entitlements.py +0 -195
  139. zscaler_sdk_python-2.0.0/zscaler/zcc/fail_open_policy.py +0 -116
  140. zscaler_sdk_python-2.0.0/zscaler/zcc/forwarding_profile.py +0 -145
  141. zscaler_sdk_python-2.0.0/zscaler/zcc/legacy.py +0 -353
  142. zscaler_sdk_python-2.0.0/zscaler/zcc/manage_pass.py +0 -65
  143. zscaler_sdk_python-2.0.0/zscaler/zcc/models/admin_roles.py +0 -163
  144. zscaler_sdk_python-2.0.0/zscaler/zcc/models/admin_user.py +0 -69
  145. zscaler_sdk_python-2.0.0/zscaler/zcc/models/devices.py +0 -215
  146. zscaler_sdk_python-2.0.0/zscaler/zcc/models/failopenpolicy.py +0 -104
  147. zscaler_sdk_python-2.0.0/zscaler/zcc/models/forwardingprofile.py +0 -343
  148. zscaler_sdk_python-2.0.0/zscaler/zcc/models/manage_pass.py +0 -96
  149. zscaler_sdk_python-2.0.0/zscaler/zcc/models/secrets_otp.py +0 -74
  150. zscaler_sdk_python-2.0.0/zscaler/zcc/models/secrets_passwords.py +0 -60
  151. zscaler_sdk_python-2.0.0/zscaler/zcc/models/trustednetworks.py +0 -97
  152. zscaler_sdk_python-2.0.0/zscaler/zcc/models/webappservice.py +0 -85
  153. zscaler_sdk_python-2.0.0/zscaler/zcc/models/webpolicy.py +0 -176
  154. zscaler_sdk_python-2.0.0/zscaler/zcc/models/webprivacy.py +0 -84
  155. zscaler_sdk_python-2.0.0/zscaler/zcc/models/zdxgroupentitlements.py +0 -72
  156. zscaler_sdk_python-2.0.0/zscaler/zcc/models/zpagroupentitlements.py +0 -73
  157. zscaler_sdk_python-2.0.0/zscaler/zcc/secrets.py +0 -111
  158. zscaler_sdk_python-2.0.0/zscaler/zcc/trusted_networks.py +0 -198
  159. zscaler_sdk_python-2.0.0/zscaler/zcc/web_app_service.py +0 -81
  160. zscaler_sdk_python-2.0.0/zscaler/zcc/web_policy.py +0 -186
  161. zscaler_sdk_python-2.0.0/zscaler/zcc/web_privacy.py +0 -120
  162. zscaler_sdk_python-2.0.0/zscaler/zcc/zcc_service.py +0 -131
  163. zscaler_sdk_python-2.0.0/zscaler/zdx/__init__.py +0 -0
  164. zscaler_sdk_python-2.0.0/zscaler/zdx/admin.py +0 -162
  165. zscaler_sdk_python-2.0.0/zscaler/zdx/alerts.py +0 -323
  166. zscaler_sdk_python-2.0.0/zscaler/zdx/apps.py +0 -467
  167. zscaler_sdk_python-2.0.0/zscaler/zdx/devices.py +0 -841
  168. zscaler_sdk_python-2.0.0/zscaler/zdx/inventory.py +0 -175
  169. zscaler_sdk_python-2.0.0/zscaler/zdx/legacy.py +0 -382
  170. zscaler_sdk_python-2.0.0/zscaler/zdx/models/activeapplications.py +0 -61
  171. zscaler_sdk_python-2.0.0/zscaler/zdx/models/administration.py +0 -48
  172. zscaler_sdk_python-2.0.0/zscaler/zdx/models/alerts.py +0 -132
  173. zscaler_sdk_python-2.0.0/zscaler/zdx/models/application_users.py +0 -92
  174. zscaler_sdk_python-2.0.0/zscaler/zdx/models/applications.py +0 -165
  175. zscaler_sdk_python-2.0.0/zscaler/zdx/models/call_quality_metrics.py +0 -58
  176. zscaler_sdk_python-2.0.0/zscaler/zdx/models/common.py +0 -167
  177. zscaler_sdk_python-2.0.0/zscaler/zdx/models/devices.py +0 -437
  178. zscaler_sdk_python-2.0.0/zscaler/zdx/models/software_inventory.py +0 -121
  179. zscaler_sdk_python-2.0.0/zscaler/zdx/models/troubleshooting.py +0 -370
  180. zscaler_sdk_python-2.0.0/zscaler/zdx/models/users.py +0 -98
  181. zscaler_sdk_python-2.0.0/zscaler/zdx/troubleshooting.py +0 -681
  182. zscaler_sdk_python-2.0.0/zscaler/zdx/users.py +0 -167
  183. zscaler_sdk_python-2.0.0/zscaler/zdx/zdx_service.py +0 -86
  184. zscaler_sdk_python-2.0.0/zscaler/zia/__init__.py +0 -0
  185. zscaler_sdk_python-2.0.0/zscaler/zia/activate.py +0 -106
  186. zscaler_sdk_python-2.0.0/zscaler/zia/admin_roles.py +0 -244
  187. zscaler_sdk_python-2.0.0/zscaler/zia/admin_users.py +0 -422
  188. zscaler_sdk_python-2.0.0/zscaler/zia/advanced_settings.py +0 -210
  189. zscaler_sdk_python-2.0.0/zscaler/zia/apptotal.py +0 -221
  190. zscaler_sdk_python-2.0.0/zscaler/zia/atp_policy.py +0 -401
  191. zscaler_sdk_python-2.0.0/zscaler/zia/audit_logs.py +0 -160
  192. zscaler_sdk_python-2.0.0/zscaler/zia/authentication_settings.py +0 -309
  193. zscaler_sdk_python-2.0.0/zscaler/zia/cloud_applications.py +0 -182
  194. zscaler_sdk_python-2.0.0/zscaler/zia/cloud_apps.py +0 -526
  195. zscaler_sdk_python-2.0.0/zscaler/zia/cloud_browser_isolation.py +0 -87
  196. zscaler_sdk_python-2.0.0/zscaler/zia/cloud_firewall.py +0 -2255
  197. zscaler_sdk_python-2.0.0/zscaler/zia/cloud_firewall_dns.py +0 -382
  198. zscaler_sdk_python-2.0.0/zscaler/zia/cloud_firewall_ips.py +0 -375
  199. zscaler_sdk_python-2.0.0/zscaler/zia/cloud_firewall_rules.py +0 -346
  200. zscaler_sdk_python-2.0.0/zscaler/zia/cloud_nss.py +0 -688
  201. zscaler_sdk_python-2.0.0/zscaler/zia/cloudappcontrol.py +0 -774
  202. zscaler_sdk_python-2.0.0/zscaler/zia/device_management.py +0 -201
  203. zscaler_sdk_python-2.0.0/zscaler/zia/dlp_dictionary.py +0 -524
  204. zscaler_sdk_python-2.0.0/zscaler/zia/dlp_engine.py +0 -404
  205. zscaler_sdk_python-2.0.0/zscaler/zia/dlp_resources.py +0 -635
  206. zscaler_sdk_python-2.0.0/zscaler/zia/dlp_templates.py +0 -301
  207. zscaler_sdk_python-2.0.0/zscaler/zia/dlp_web_rules.py +0 -439
  208. zscaler_sdk_python-2.0.0/zscaler/zia/end_user_notification.py +0 -164
  209. zscaler_sdk_python-2.0.0/zscaler/zia/file_type_control_rule.py +0 -361
  210. zscaler_sdk_python-2.0.0/zscaler/zia/forwarding_control.py +0 -473
  211. zscaler_sdk_python-2.0.0/zscaler/zia/gre_tunnel.py +0 -731
  212. zscaler_sdk_python-2.0.0/zscaler/zia/intermediate_certificates.py +0 -684
  213. zscaler_sdk_python-2.0.0/zscaler/zia/iot_report.py +0 -205
  214. zscaler_sdk_python-2.0.0/zscaler/zia/ipv6_config.py +0 -190
  215. zscaler_sdk_python-2.0.0/zscaler/zia/legacy.py +0 -796
  216. zscaler_sdk_python-2.0.0/zscaler/zia/locations.py +0 -1054
  217. zscaler_sdk_python-2.0.0/zscaler/zia/malware_protection_policy.py +0 -506
  218. zscaler_sdk_python-2.0.0/zscaler/zia/models/__init__.py +0 -0
  219. zscaler_sdk_python-2.0.0/zscaler/zia/models/activation.py +0 -46
  220. zscaler_sdk_python-2.0.0/zscaler/zia/models/admin_roles.py +0 -93
  221. zscaler_sdk_python-2.0.0/zscaler/zia/models/admin_users.py +0 -327
  222. zscaler_sdk_python-2.0.0/zscaler/zia/models/advanced_settings.py +0 -320
  223. zscaler_sdk_python-2.0.0/zscaler/zia/models/advanced_threat_settings.py +0 -217
  224. zscaler_sdk_python-2.0.0/zscaler/zia/models/apptotal.py +0 -257
  225. zscaler_sdk_python-2.0.0/zscaler/zia/models/authentication_settings.py +0 -91
  226. zscaler_sdk_python-2.0.0/zscaler/zia/models/cloud_app_policy.py +0 -52
  227. zscaler_sdk_python-2.0.0/zscaler/zia/models/cloud_browser_isolation.py +0 -51
  228. zscaler_sdk_python-2.0.0/zscaler/zia/models/cloud_firewall_app_services.py +0 -48
  229. zscaler_sdk_python-2.0.0/zscaler/zia/models/cloud_firewall_destination_groups.py +0 -64
  230. zscaler_sdk_python-2.0.0/zscaler/zia/models/cloud_firewall_dns_rules.py +0 -251
  231. zscaler_sdk_python-2.0.0/zscaler/zia/models/cloud_firewall_ips_rules.py +0 -212
  232. zscaler_sdk_python-2.0.0/zscaler/zia/models/cloud_firewall_nw_application_groups.py +0 -54
  233. zscaler_sdk_python-2.0.0/zscaler/zia/models/cloud_firewall_nw_applications.py +0 -51
  234. zscaler_sdk_python-2.0.0/zscaler/zia/models/cloud_firewall_nw_service.py +0 -89
  235. zscaler_sdk_python-2.0.0/zscaler/zia/models/cloud_firewall_nw_service_groups.py +0 -52
  236. zscaler_sdk_python-2.0.0/zscaler/zia/models/cloud_firewall_rules.py +0 -237
  237. zscaler_sdk_python-2.0.0/zscaler/zia/models/cloud_firewall_source_groups.py +0 -59
  238. zscaler_sdk_python-2.0.0/zscaler/zia/models/cloud_firewall_time_windows.py +0 -55
  239. zscaler_sdk_python-2.0.0/zscaler/zia/models/cloud_nss.py +0 -611
  240. zscaler_sdk_python-2.0.0/zscaler/zia/models/cloudappcontrol.py +0 -256
  241. zscaler_sdk_python-2.0.0/zscaler/zia/models/common.py +0 -175
  242. zscaler_sdk_python-2.0.0/zscaler/zia/models/device_groups.py +0 -57
  243. zscaler_sdk_python-2.0.0/zscaler/zia/models/devices.py +0 -65
  244. zscaler_sdk_python-2.0.0/zscaler/zia/models/dlp_dictionary.py +0 -244
  245. zscaler_sdk_python-2.0.0/zscaler/zia/models/dlp_engine.py +0 -90
  246. zscaler_sdk_python-2.0.0/zscaler/zia/models/dlp_resources.py +0 -189
  247. zscaler_sdk_python-2.0.0/zscaler/zia/models/dlp_templates.py +0 -66
  248. zscaler_sdk_python-2.0.0/zscaler/zia/models/dlp_web_rules.py +0 -232
  249. zscaler_sdk_python-2.0.0/zscaler/zia/models/endusernotification.py +0 -155
  250. zscaler_sdk_python-2.0.0/zscaler/zia/models/filetyperules.py +0 -178
  251. zscaler_sdk_python-2.0.0/zscaler/zia/models/forwarding_control_policy.py +0 -243
  252. zscaler_sdk_python-2.0.0/zscaler/zia/models/gre_recommended_list.py +0 -73
  253. zscaler_sdk_python-2.0.0/zscaler/zia/models/gre_tunnel_info.py +0 -69
  254. zscaler_sdk_python-2.0.0/zscaler/zia/models/gre_tunnels.py +0 -135
  255. zscaler_sdk_python-2.0.0/zscaler/zia/models/gre_vips.py +0 -166
  256. zscaler_sdk_python-2.0.0/zscaler/zia/models/intermediate_certificates.py +0 -157
  257. zscaler_sdk_python-2.0.0/zscaler/zia/models/iotreport.py +0 -105
  258. zscaler_sdk_python-2.0.0/zscaler/zia/models/ipv6_config.py +0 -106
  259. zscaler_sdk_python-2.0.0/zscaler/zia/models/location_group.py +0 -81
  260. zscaler_sdk_python-2.0.0/zscaler/zia/models/location_management.py +0 -306
  261. zscaler_sdk_python-2.0.0/zscaler/zia/models/malware_protection_settings.py +0 -101
  262. zscaler_sdk_python-2.0.0/zscaler/zia/models/organization_information.py +0 -452
  263. zscaler_sdk_python-2.0.0/zscaler/zia/models/pac_files.py +0 -98
  264. zscaler_sdk_python-2.0.0/zscaler/zia/models/proxy_gatways.py +0 -72
  265. zscaler_sdk_python-2.0.0/zscaler/zia/models/remoteassistance.py +0 -58
  266. zscaler_sdk_python-2.0.0/zscaler/zia/models/rule_labels.py +0 -69
  267. zscaler_sdk_python-2.0.0/zscaler/zia/models/sandboxrules.py +0 -162
  268. zscaler_sdk_python-2.0.0/zscaler/zia/models/security_policy_settings.py +0 -49
  269. zscaler_sdk_python-2.0.0/zscaler/zia/models/shadow_it_report.py +0 -298
  270. zscaler_sdk_python-2.0.0/zscaler/zia/models/ssl_inspection_rules.py +0 -493
  271. zscaler_sdk_python-2.0.0/zscaler/zia/models/subclouds.py +0 -286
  272. zscaler_sdk_python-2.0.0/zscaler/zia/models/system_audit.py +0 -284
  273. zscaler_sdk_python-2.0.0/zscaler/zia/models/traffic_extranet.py +0 -165
  274. zscaler_sdk_python-2.0.0/zscaler/zia/models/traffic_static_ip.py +0 -88
  275. zscaler_sdk_python-2.0.0/zscaler/zia/models/traffic_vpn_credentials.py +0 -88
  276. zscaler_sdk_python-2.0.0/zscaler/zia/models/url_filter_cloud_app_settings.py +0 -114
  277. zscaler_sdk_python-2.0.0/zscaler/zia/models/url_filtering_rules.py +0 -199
  278. zscaler_sdk_python-2.0.0/zscaler/zia/models/urlcategory.py +0 -181
  279. zscaler_sdk_python-2.0.0/zscaler/zia/models/user_management.py +0 -181
  280. zscaler_sdk_python-2.0.0/zscaler/zia/models/workload_groups.py +0 -63
  281. zscaler_sdk_python-2.0.0/zscaler/zia/models/zpa_gateway.py +0 -89
  282. zscaler_sdk_python-2.0.0/zscaler/zia/organization_information.py +0 -172
  283. zscaler_sdk_python-2.0.0/zscaler/zia/pac_files.py +0 -507
  284. zscaler_sdk_python-2.0.0/zscaler/zia/policy_export.py +0 -92
  285. zscaler_sdk_python-2.0.0/zscaler/zia/remote_assistance.py +0 -144
  286. zscaler_sdk_python-2.0.0/zscaler/zia/rule_labels.py +0 -236
  287. zscaler_sdk_python-2.0.0/zscaler/zia/sandbox.py +0 -346
  288. zscaler_sdk_python-2.0.0/zscaler/zia/sandbox_rules.py +0 -333
  289. zscaler_sdk_python-2.0.0/zscaler/zia/security_policy_settings.py +0 -260
  290. zscaler_sdk_python-2.0.0/zscaler/zia/ssl_inspection_rules.py +0 -355
  291. zscaler_sdk_python-2.0.0/zscaler/zia/sub_clouds.py +0 -173
  292. zscaler_sdk_python-2.0.0/zscaler/zia/system_audit.py +0 -84
  293. zscaler_sdk_python-2.0.0/zscaler/zia/traffic_extranet.py +0 -243
  294. zscaler_sdk_python-2.0.0/zscaler/zia/traffic_static_ip.py +0 -350
  295. zscaler_sdk_python-2.0.0/zscaler/zia/traffic_vpn_credentials.py +0 -368
  296. zscaler_sdk_python-2.0.0/zscaler/zia/url_categories.py +0 -714
  297. zscaler_sdk_python-2.0.0/zscaler/zia/url_filtering.py +0 -547
  298. zscaler_sdk_python-2.0.0/zscaler/zia/user_management.py +0 -1010
  299. zscaler_sdk_python-2.0.0/zscaler/zia/workload_groups.py +0 -91
  300. zscaler_sdk_python-2.0.0/zscaler/zia/zia_service.py +0 -479
  301. zscaler_sdk_python-2.0.0/zscaler/zia/zpa_gateway.py +0 -351
  302. zscaler_sdk_python-2.0.0/zscaler/zpa/__init__.py +0 -0
  303. zscaler_sdk_python-2.0.0/zscaler/zpa/app_connector_groups.py +0 -364
  304. zscaler_sdk_python-2.0.0/zscaler/zpa/app_connector_schedule.py +0 -223
  305. zscaler_sdk_python-2.0.0/zscaler/zpa/app_connectors.py +0 -281
  306. zscaler_sdk_python-2.0.0/zscaler/zpa/app_protection.py +0 -1112
  307. zscaler_sdk_python-2.0.0/zscaler/zpa/app_segment_by_type.py +0 -160
  308. zscaler_sdk_python-2.0.0/zscaler/zpa/app_segments_inspection.py +0 -490
  309. zscaler_sdk_python-2.0.0/zscaler/zpa/app_segments_pra.py +0 -468
  310. zscaler_sdk_python-2.0.0/zscaler/zpa/application_segment.py +0 -627
  311. zscaler_sdk_python-2.0.0/zscaler/zpa/authdomains.py +0 -72
  312. zscaler_sdk_python-2.0.0/zscaler/zpa/cbi_banner.py +0 -256
  313. zscaler_sdk_python-2.0.0/zscaler/zpa/cbi_certificate.py +0 -249
  314. zscaler_sdk_python-2.0.0/zscaler/zpa/cbi_profile.py +0 -383
  315. zscaler_sdk_python-2.0.0/zscaler/zpa/cbi_region.py +0 -69
  316. zscaler_sdk_python-2.0.0/zscaler/zpa/cbi_zpa_profile.py +0 -121
  317. zscaler_sdk_python-2.0.0/zscaler/zpa/certificates.py +0 -352
  318. zscaler_sdk_python-2.0.0/zscaler/zpa/cloud_connector_groups.py +0 -128
  319. zscaler_sdk_python-2.0.0/zscaler/zpa/customer_version_profile.py +0 -91
  320. zscaler_sdk_python-2.0.0/zscaler/zpa/emergency_access.py +0 -350
  321. zscaler_sdk_python-2.0.0/zscaler/zpa/enrollment_certificates.py +0 -141
  322. zscaler_sdk_python-2.0.0/zscaler/zpa/idp.py +0 -142
  323. zscaler_sdk_python-2.0.0/zscaler/zpa/legacy.py +0 -624
  324. zscaler_sdk_python-2.0.0/zscaler/zpa/lss.py +0 -577
  325. zscaler_sdk_python-2.0.0/zscaler/zpa/machine_groups.py +0 -137
  326. zscaler_sdk_python-2.0.0/zscaler/zpa/microtenants.py +0 -402
  327. zscaler_sdk_python-2.0.0/zscaler/zpa/models/app_connector_groups.py +0 -273
  328. zscaler_sdk_python-2.0.0/zscaler/zpa/models/app_connector_schedule.py +0 -55
  329. zscaler_sdk_python-2.0.0/zscaler/zpa/models/app_connectors.py +0 -176
  330. zscaler_sdk_python-2.0.0/zscaler/zpa/models/app_protection.py +0 -317
  331. zscaler_sdk_python-2.0.0/zscaler/zpa/models/app_protection_predefined_controls.py +0 -182
  332. zscaler_sdk_python-2.0.0/zscaler/zpa/models/application_segment.py +0 -587
  333. zscaler_sdk_python-2.0.0/zscaler/zpa/models/application_segment_inspection.py +0 -173
  334. zscaler_sdk_python-2.0.0/zscaler/zpa/models/application_segment_pra.py +0 -211
  335. zscaler_sdk_python-2.0.0/zscaler/zpa/models/application_servers.py +0 -62
  336. zscaler_sdk_python-2.0.0/zscaler/zpa/models/cbi_banner.py +0 -60
  337. zscaler_sdk_python-2.0.0/zscaler/zpa/models/cbi_certificate.py +0 -48
  338. zscaler_sdk_python-2.0.0/zscaler/zpa/models/cbi_profile.py +0 -216
  339. zscaler_sdk_python-2.0.0/zscaler/zpa/models/cbi_region.py +0 -45
  340. zscaler_sdk_python-2.0.0/zscaler/zpa/models/cbi_zpa_profile.py +0 -119
  341. zscaler_sdk_python-2.0.0/zscaler/zpa/models/certificates.py +0 -93
  342. zscaler_sdk_python-2.0.0/zscaler/zpa/models/cloud_connector_groups.py +0 -62
  343. zscaler_sdk_python-2.0.0/zscaler/zpa/models/common.py +0 -363
  344. zscaler_sdk_python-2.0.0/zscaler/zpa/models/customer_version_profile.py +0 -104
  345. zscaler_sdk_python-2.0.0/zscaler/zpa/models/emergency_access.py +0 -58
  346. zscaler_sdk_python-2.0.0/zscaler/zpa/models/enrollment_certificates.py +0 -110
  347. zscaler_sdk_python-2.0.0/zscaler/zpa/models/idp.py +0 -223
  348. zscaler_sdk_python-2.0.0/zscaler/zpa/models/lss.py +0 -165
  349. zscaler_sdk_python-2.0.0/zscaler/zpa/models/machine_groups.py +0 -69
  350. zscaler_sdk_python-2.0.0/zscaler/zpa/models/microtenants.py +0 -235
  351. zscaler_sdk_python-2.0.0/zscaler/zpa/models/policyset_controller_v1.py +0 -287
  352. zscaler_sdk_python-2.0.0/zscaler/zpa/models/policyset_controller_v2.py +0 -246
  353. zscaler_sdk_python-2.0.0/zscaler/zpa/models/posture_profiles.py +0 -106
  354. zscaler_sdk_python-2.0.0/zscaler/zpa/models/pra_approval.py +0 -134
  355. zscaler_sdk_python-2.0.0/zscaler/zpa/models/pra_console.py +0 -156
  356. zscaler_sdk_python-2.0.0/zscaler/zpa/models/pra_cred_pool_controller.py +0 -76
  357. zscaler_sdk_python-2.0.0/zscaler/zpa/models/pra_credential.py +0 -67
  358. zscaler_sdk_python-2.0.0/zscaler/zpa/models/pra_portal.py +0 -102
  359. zscaler_sdk_python-2.0.0/zscaler/zpa/models/provisioning_keys.py +0 -77
  360. zscaler_sdk_python-2.0.0/zscaler/zpa/models/saml_attributes.py +0 -64
  361. zscaler_sdk_python-2.0.0/zscaler/zpa/models/scim_attributes.py +0 -79
  362. zscaler_sdk_python-2.0.0/zscaler/zpa/models/scim_groups.py +0 -58
  363. zscaler_sdk_python-2.0.0/zscaler/zpa/models/segment_group.py +0 -75
  364. zscaler_sdk_python-2.0.0/zscaler/zpa/models/server_group.py +0 -94
  365. zscaler_sdk_python-2.0.0/zscaler/zpa/models/service_edge_groups.py +0 -148
  366. zscaler_sdk_python-2.0.0/zscaler/zpa/models/service_edge_schedule.py +0 -55
  367. zscaler_sdk_python-2.0.0/zscaler/zpa/models/service_edges.py +0 -160
  368. zscaler_sdk_python-2.0.0/zscaler/zpa/models/trusted_network.py +0 -66
  369. zscaler_sdk_python-2.0.0/zscaler/zpa/policies.py +0 -3308
  370. zscaler_sdk_python-2.0.0/zscaler/zpa/posture_profiles.py +0 -142
  371. zscaler_sdk_python-2.0.0/zscaler/zpa/pra_approval.py +0 -391
  372. zscaler_sdk_python-2.0.0/zscaler/zpa/pra_console.py +0 -437
  373. zscaler_sdk_python-2.0.0/zscaler/zpa/pra_credential.py +0 -384
  374. zscaler_sdk_python-2.0.0/zscaler/zpa/pra_credential_pool.py +0 -354
  375. zscaler_sdk_python-2.0.0/zscaler/zpa/pra_portal.py +0 -289
  376. zscaler_sdk_python-2.0.0/zscaler/zpa/provisioning.py +0 -385
  377. zscaler_sdk_python-2.0.0/zscaler/zpa/saml_attributes.py +0 -179
  378. zscaler_sdk_python-2.0.0/zscaler/zpa/scim_attributes.py +0 -189
  379. zscaler_sdk_python-2.0.0/zscaler/zpa/scim_groups.py +0 -150
  380. zscaler_sdk_python-2.0.0/zscaler/zpa/segment_groups.py +0 -364
  381. zscaler_sdk_python-2.0.0/zscaler/zpa/server_groups.py +0 -344
  382. zscaler_sdk_python-2.0.0/zscaler/zpa/servers.py +0 -287
  383. zscaler_sdk_python-2.0.0/zscaler/zpa/service_edge_group.py +0 -355
  384. zscaler_sdk_python-2.0.0/zscaler/zpa/service_edge_schedule.py +0 -223
  385. zscaler_sdk_python-2.0.0/zscaler/zpa/service_edges.py +0 -265
  386. zscaler_sdk_python-2.0.0/zscaler/zpa/trusted_networks.py +0 -146
  387. zscaler_sdk_python-2.0.0/zscaler/zpa/zpa_service.py +0 -378
  388. zscaler_sdk_python-2.0.0/zscaler/ztw/__init__.py +0 -0
  389. zscaler_sdk_python-2.0.0/zscaler/ztw/account_details.py +0 -276
  390. zscaler_sdk_python-2.0.0/zscaler/ztw/activation.py +0 -115
  391. zscaler_sdk_python-2.0.0/zscaler/ztw/admin_roles.py +0 -326
  392. zscaler_sdk_python-2.0.0/zscaler/ztw/admin_users.py +0 -400
  393. zscaler_sdk_python-2.0.0/zscaler/ztw/api_keys.py +0 -131
  394. zscaler_sdk_python-2.0.0/zscaler/ztw/ec_groups.py +0 -319
  395. zscaler_sdk_python-2.0.0/zscaler/ztw/forwarding_gateways.py +0 -235
  396. zscaler_sdk_python-2.0.0/zscaler/ztw/forwarding_rules.py +0 -368
  397. zscaler_sdk_python-2.0.0/zscaler/ztw/ip_destination_groups.py +0 -319
  398. zscaler_sdk_python-2.0.0/zscaler/ztw/ip_groups.py +0 -259
  399. zscaler_sdk_python-2.0.0/zscaler/ztw/ip_source_groups.py +0 -259
  400. zscaler_sdk_python-2.0.0/zscaler/ztw/legacy.py +0 -461
  401. zscaler_sdk_python-2.0.0/zscaler/ztw/location_management.py +0 -242
  402. zscaler_sdk_python-2.0.0/zscaler/ztw/location_template.py +0 -385
  403. zscaler_sdk_python-2.0.0/zscaler/ztw/models/activation.py +0 -57
  404. zscaler_sdk_python-2.0.0/zscaler/ztw/models/admin_roles.py +0 -97
  405. zscaler_sdk_python-2.0.0/zscaler/ztw/models/admin_users.py +0 -150
  406. zscaler_sdk_python-2.0.0/zscaler/ztw/models/api_keys.py +0 -91
  407. zscaler_sdk_python-2.0.0/zscaler/ztw/models/common.py +0 -88
  408. zscaler_sdk_python-2.0.0/zscaler/ztw/models/ec_group_vm.py +0 -121
  409. zscaler_sdk_python-2.0.0/zscaler/ztw/models/ecgroup.py +0 -457
  410. zscaler_sdk_python-2.0.0/zscaler/ztw/models/forwarding_gateways.py +0 -111
  411. zscaler_sdk_python-2.0.0/zscaler/ztw/models/forwarding_rules.py +0 -347
  412. zscaler_sdk_python-2.0.0/zscaler/ztw/models/ip_destination_groups.py +0 -72
  413. zscaler_sdk_python-2.0.0/zscaler/ztw/models/ip_groups.py +0 -58
  414. zscaler_sdk_python-2.0.0/zscaler/ztw/models/ip_source_groups.py +0 -58
  415. zscaler_sdk_python-2.0.0/zscaler/ztw/models/location_management.py +0 -255
  416. zscaler_sdk_python-2.0.0/zscaler/ztw/models/location_templates.py +0 -173
  417. zscaler_sdk_python-2.0.0/zscaler/ztw/models/nw_service.py +0 -95
  418. zscaler_sdk_python-2.0.0/zscaler/ztw/models/nw_service_groups.py +0 -56
  419. zscaler_sdk_python-2.0.0/zscaler/ztw/models/provisioning_url.py +0 -224
  420. zscaler_sdk_python-2.0.0/zscaler/ztw/models/traffic_vpn_credentials.py +0 -90
  421. zscaler_sdk_python-2.0.0/zscaler/ztw/models/zpa_resources.py +0 -61
  422. zscaler_sdk_python-2.0.0/zscaler/ztw/nw_service.py +0 -299
  423. zscaler_sdk_python-2.0.0/zscaler/ztw/nw_service_groups.py +0 -99
  424. zscaler_sdk_python-2.0.0/zscaler/ztw/provisioning_url.py +0 -126
  425. zscaler_sdk_python-2.0.0/zscaler/ztw/ztw_service.py +0 -180
  426. zscaler_sdk_python-2.0.0/zscaler/zwa/__init__.py +0 -0
  427. zscaler_sdk_python-2.0.0/zscaler/zwa/audit_logs.py +0 -132
  428. zscaler_sdk_python-2.0.0/zscaler/zwa/dlp_incidents.py +0 -656
  429. zscaler_sdk_python-2.0.0/zscaler/zwa/legacy.py +0 -268
  430. zscaler_sdk_python-2.0.0/zscaler/zwa/models/audit_logs.py +0 -135
  431. zscaler_sdk_python-2.0.0/zscaler/zwa/models/change_history.py +0 -61
  432. zscaler_sdk_python-2.0.0/zscaler/zwa/models/common.py +0 -712
  433. zscaler_sdk_python-2.0.0/zscaler/zwa/models/generated_tickets.py +0 -152
  434. zscaler_sdk_python-2.0.0/zscaler/zwa/models/incident_details.py +0 -203
  435. zscaler_sdk_python-2.0.0/zscaler/zwa/models/incident_evidence.py +0 -57
  436. zscaler_sdk_python-2.0.0/zscaler/zwa/models/incident_group_search.py +0 -59
  437. zscaler_sdk_python-2.0.0/zscaler/zwa/models/incident_search.py +0 -93
  438. zscaler_sdk_python-2.0.0/zscaler/zwa/models/incident_trigger.py +0 -45
  439. {zscaler_sdk_python-2.0.0 → zscaler_sdk_python-2.0.0b2}/LICENSE.md +0 -0
  440. /zscaler_sdk_python-2.0.0/zscaler/cache/__init__.py → /zscaler_sdk_python-2.0.0b2/zssdk/py.typed +0 -0
@@ -0,0 +1,928 @@
1
+ Metadata-Version: 2.4
2
+ Name: zscaler-sdk-python
3
+ Version: 2.0.0b2
4
+ Summary: Zscaler SDK for Python
5
+ Author-email: "Zscaler Inc." <devrel@zscaler.com>
6
+ License-Expression: MIT
7
+ Project-URL: Homepage, https://github.com/zscaler/zscaler-sdk-python
8
+ Project-URL: Repository, https://github.com/zscaler/zscaler-sdk-python
9
+ Project-URL: Documentation, http://automation.zsapidocs.net/docs/
10
+ Project-URL: Bug Tracker, https://github.com/zscaler/zscaler-sdk-python/issues
11
+ Keywords: zscaler,sdk,zpa,zia,zdx,zcc,ztw,zid,zidentity
12
+ Classifier: Development Status :: 4 - Beta
13
+ Classifier: Intended Audience :: Developers
14
+ Classifier: Programming Language :: Python :: 3.10
15
+ Classifier: Programming Language :: Python :: 3.11
16
+ Classifier: Programming Language :: Python :: 3.12
17
+ Classifier: Operating System :: OS Independent
18
+ Classifier: Topic :: Security
19
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
20
+ Requires-Python: >=3.10
21
+ Description-Content-Type: text/markdown
22
+ License-File: LICENSE.md
23
+ Requires-Dist: cryptography>=46.0.0
24
+ Requires-Dist: httpx<2.0.0,>=0.28.0
25
+ Requires-Dist: jmespath>=1.0.0
26
+ Requires-Dist: pydantic<3.0.0,>=2.0.0
27
+ Requires-Dist: PyJWT<3.0.0,>=2.8.0
28
+ Requires-Dist: truststore>=0.9.0
29
+ Provides-Extra: examples
30
+ Requires-Dist: prettytable>=3.0.0; extra == "examples"
31
+ Provides-Extra: dev
32
+ Requires-Dist: black==25.12.0; extra == "dev"
33
+ Requires-Dist: faker>=30.0.0; extra == "dev"
34
+ Requires-Dist: flake8>=7.0.0; extra == "dev"
35
+ Requires-Dist: isort==7.0.0; extra == "dev"
36
+ Requires-Dist: pylint==4.0.4; extra == "dev"
37
+ Requires-Dist: pytest==9.0.1; extra == "dev"
38
+ Requires-Dist: pytest-mock>=3.12.0; extra == "dev"
39
+ Requires-Dist: pytest-httpserver>=1.0.0; extra == "dev"
40
+ Requires-Dist: build>=1.0.0; extra == "dev"
41
+ Requires-Dist: twine>=5.0.0; extra == "dev"
42
+ Requires-Dist: anyio==4.12.0; extra == "dev"
43
+ Requires-Dist: autopep8==2.3.2; extra == "dev"
44
+ Requires-Dist: tomlkit==0.13.3; extra == "dev"
45
+ Requires-Dist: uv==0.9.21; extra == "dev"
46
+ Dynamic: license-file
47
+
48
+ # Official Zscaler OneAPI SDK for Python
49
+
50
+ [![PyPI Version](https://img.shields.io/pypi/v/zscaler-sdk-python.svg)](https://pypi.org/project/zscaler-sdk-python)
51
+ [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/zscaler-sdk-python.svg)](https://pypi.org/project/zscaler-sdk-python)
52
+ [![License](https://img.shields.io/badge/license-ISC-blue.svg)](LICENSE.md)
53
+ [![PyPI - Downloads](https://img.shields.io/pypi/dw/zscaler-sdk-python)](https://pypistats.org/packages/zscaler-sdk-python)
54
+ [![Documentation Status](https://img.shields.io/badge/docs-online-success)](http://automation.zsapidocs.net/docs/)
55
+ [![Zscaler Community](https://img.shields.io/badge/zscaler-community-blue)](https://community.zscaler.com/)
56
+
57
+ ---
58
+
59
+ ## Table of Contents
60
+
61
+ - [Overview](#overview)
62
+ - [Why This SDK](#why-this-sdk)
63
+ - [Prerequisites](#prerequisites)
64
+ - [Installation](#installation)
65
+ - [Building the SDK](#building-the-sdk)
66
+ - [Getting Started](#getting-started)
67
+ - [Authentication](#authentication)
68
+ - [Basic Usage](#basic-usage)
69
+ - [Configuration](#configuration)
70
+ - [Configuration File](#configuration-file)
71
+ - [Environment Variables](#environment-variables)
72
+ - [Constructor Parameters](#constructor-parameters)
73
+ - [Configuration Precedence](#configuration-precedence)
74
+ - [API Layers](#api-layers)
75
+ - [Resource Layer (Recommended)](#resource-layer-recommended)
76
+ - [Service Client Layer](#service-client-layer)
77
+ - [Supported Products](#supported-products)
78
+ - [ZPA: customer_id Requirement](#zpa-customer_id-requirement)
79
+ - [ZIA and ZTW Context Manager](#zia-and-ztw-context-manager)
80
+ - [Collections and Pagination](#collections-and-pagination)
81
+ - [Error Handling](#error-handling)
82
+ - [Rate Limiting and Retry Mechanism](#rate-limiting-and-retry-mechanism)
83
+ - [Logging](#logging)
84
+ - [Auto-completion and IntelliSense](#auto-completion-and-intellisense)
85
+ - [Examples](#examples)
86
+ - [Migrating from zscaler-sdk-python](#migrating-from-zscaler-sdk-python)
87
+ - [Contributing](#contributing)
88
+ - [Need Help?](#need-help)
89
+
90
+ ---
91
+
92
+ ## Overview
93
+
94
+ The Zscaler OneAPI SDK for Python (`zscaler-sdk-python`) provides a convenient and consistent interface for interacting with Zscaler product APIs through the [OneAPI](https://help.zscaler.com/oneapi/understanding-oneapi) framework.
95
+
96
+ This SDK is designed exclusively for OneAPI. It uses OAuth2 authentication via [Zscaler Identity (Zidentity)](https://help.zscaler.com/zidentity/what-zidentity) and provides a high-level `Session` object that manages credentials, configuration, and API calls.
97
+
98
+ This SDK can be used in your server-side code to interact with the Zscaler API platform across multiple products such as:
99
+
100
+ - [ZPA API](https://automate.zscaler.com/docs/docs/api-reference-and-guides/api-reference/zpa)
101
+ - [ZIA API](https://automate.zscaler.com/docs/docs/api-reference-and-guides/api-reference/zia)
102
+ - [ZDX API](https://automate.zscaler.com/docs/docs/api-reference-and-guides/api-reference/zdx)
103
+ - [ZCC API](https://automate.zscaler.com/docs/docs/api-reference-and-guides/api-reference/zcc)
104
+ - [ZIdentity](https://automate.zscaler.com/docs/docs/api-reference-and-guides/api-reference/zid)
105
+ - [ZTW API](https://automate.zscaler.com/docs/docs/api-reference-and-guides/api-reference/zcloudconnector)
106
+
107
+ > **Note:** This SDK (`zscaler-sdk-python`) is the next-generation replacement for the previous [`zscaler-sdk-python`](https://github.com/zscaler/zscaler-sdk-python) package. See [Why This SDK](#why-this-sdk) and [Migrating from zscaler-sdk-python](#migrating-from-zscaler-sdk-python) below.
108
+
109
+ ### Key Features
110
+
111
+ - **True resource objects with dot notation** — Work with resources as Python objects (`user.name`, `cred.fqdn`), not raw dictionaries (`user["name"]`). Attribute access, assignment, and IDE auto-completion work out of the box.
112
+ - **Active Record pattern** — Create, read, update, and delete resources with natural method calls: `cred.create()`, `cred.load()`, `cred.update()`, `cred.delete()`. No need to call separate service methods and pass IDs around.
113
+ - **Non-standard operations as first-class methods** — Operations beyond CRUDL (e.g., `activate()`, `bulk_delete_assistant()`, `export_application()`, `validate_wild_card_domain_name()`) are dynamically generated from API metadata and exposed as snake_case methods on the same resource instances — no drop-down to a low-level client required.
114
+ - **Iterator-based collections with chaining** — Paginate effortlessly with `.all()`, apply server-side filters with `.filter()`, cap results with `.limit()`, tune performance with `.page_size()`, and apply client-side JMESPath queries with `.search()` — all chainable in a single expression.
115
+ - **Python exceptions, not error tuples** — Errors raise typed exceptions (`BadRequestException`, `NotFoundException`) with full context. Use standard `try`/`except` instead of unpacking `(result, response, error)` tuples on every call.
116
+ - **Automatic `snake_case` / `camelCase` conversion** — Write idiomatic Python everywhere. The SDK transparently converts to API `camelCase` on the wire and back.
117
+ - **One session, all products** — A single `Session` with unified OAuth2 authentication gives you `session.zia`, `session.zpa`, `session.zcc`, `session.zid`, `session.zdx`, and `session.ztw`. No per-product client setup or separate credentials.
118
+ - **IDE auto-completion and type checking** — Ships with PEP 484 `.pyi` type stubs. VS Code, PyCharm, and other editors provide auto-complete, parameter hints, and docstrings for every resource and method.
119
+ - **Transparent retry and rate-limit handling** — Built-in exponential backoff with `Retry-After` header support. Rate limits and transient errors are handled automatically — no retry logic needed in your code.
120
+ - **Metadata-driven architecture** — API operations, shapes, pagination, and error mappings are defined in JSON metadata generated from TypeSpec. New endpoints are added via JSON, not Python code.
121
+ - **Context managers for ZIA/ZTW activation** — `with session.zia as zia:` automatically activates staged configuration changes on exit. No manual activation calls required.
122
+
123
+ ### SDK Design and Data Model
124
+
125
+ This SDK uses a resource-oriented design with the following characteristics:
126
+
127
+ - **Resource objects** — Resources (e.g., `VpnCredential`, `UserProfile`) are Python objects with attribute access (dot notation), e.g., `cred.fqdn`, `user.login_name`.
128
+ - **Snake_case** — Property names use `snake_case` in Python while the SDK maps to/from API `camelCase` automatically.
129
+ - **Native types** — Data is represented as native Python types; responses are JSON-serializable.
130
+
131
+ ---
132
+
133
+ ## Why This SDK
134
+
135
+ If you are currently using [`zscaler-sdk-python`](https://github.com/zscaler/zscaler-sdk-python), here is why you should switch to `zscaler-sdk-python`:
136
+
137
+ | Capability | `zscaler-sdk-python` v1 | `zscaler-sdk-python` v2 |
138
+ |---|---|---|
139
+ | **Data access** | Raw `dict` — `user["name"]` | Resource objects — `user.name` |
140
+ | **CRUD pattern** | Service methods returning `(result, resp, error)` tuples | Active Record — `resource.create()`, `.load()`, `.update()`, `.delete()` |
141
+ | **Error handling** | Go-style tuples: `result, resp, err = ...` | Python exceptions: `try` / `except NotFoundException` |
142
+ | **Pagination** | Manual loop with `resp.has_next()` / `resp.next()` | Iterator-based: `for item in resources.all().limit(100)` |
143
+ | **Filtering** | Manual query params dict | Chainable `.filter()` + `.search()` (JMESPath) |
144
+ | **Case conversion** | Caller manages `camelCase` ↔ `snake_case` | Automatic — write `snake_case`, API receives `camelCase` |
145
+ | **IDE support** | No type stubs | PEP 484 `.pyi` stubs — auto-completion, param hints, docstrings |
146
+
147
+ ### Side-by-side comparison
148
+
149
+ **Previous SDK — dict access, error tuples, manual pagination:**
150
+
151
+ ```python
152
+ from zscaler import ZscalerClient
153
+
154
+ config = {"clientId": "...", "clientSecret": "...", "vanityDomain": "..."}
155
+
156
+ with ZscalerClient(config) as client:
157
+ # List users — must unpack tuple on every call
158
+ users, resp, err = client.zia.user_management.list_users()
159
+ if err:
160
+ print(f"Error: {err}")
161
+ else:
162
+ for user in users:
163
+ print(user["name"]) # dict access
164
+
165
+ # Manual pagination
166
+ while resp.has_next():
167
+ more_users, resp, err = resp.next()
168
+ if err:
169
+ break
170
+ for user in more_users:
171
+ print(user["name"])
172
+ ```
173
+
174
+ **This SDK — resource objects, exceptions, iterator collections:**
175
+
176
+ ```python
177
+ from zssdk import Session
178
+
179
+ session = Session(vanity_domain="...", client_id="...", client_secret="...")
180
+
181
+ # Iterate all users — pagination is automatic
182
+ for user in session.zia.admin_users.all():
183
+ print(user.name) # attribute access
184
+
185
+ # Chain filters, limits, and search in one expression
186
+ for user in session.zia.admin_users.filter(search="SDWAN").limit(10):
187
+ print(user.name)
188
+
189
+ # Errors are exceptions, not return values
190
+ from zssdk.zsresource.exceptions import NotFoundException
191
+ try:
192
+ role = session.zia.AdminRole(id=99999)
193
+ role.load()
194
+ except NotFoundException:
195
+ print("Role not found")
196
+ ```
197
+
198
+ ---
199
+
200
+ ## Prerequisites
201
+
202
+ - **Python 3.10+**
203
+ - An administrator account for the Zscaler products you wish to manage
204
+ - [API credentials](https://help.zscaler.com/zidentity/about-api-clients) created in the Zscaler Identity Admin UI (Client ID and Client Secret)
205
+
206
+ ---
207
+
208
+ ## Installation
209
+
210
+ Install the SDK from PyPI:
211
+
212
+ ```sh
213
+ pip install zscaler-sdk-python
214
+ ```
215
+
216
+ Or install from source (e.g., for development):
217
+
218
+ ```sh
219
+ pip install -e /path/to/oneapi-sdk/python
220
+ ```
221
+
222
+ ---
223
+
224
+ ## Building the SDK
225
+
226
+ In most cases, you won't need to build the SDK from source. If you want to build it yourself:
227
+
228
+ 1. Clone the repository
229
+ 2. Navigate to the `python` directory
230
+ 3. Run `python -m build` (requires the `build` package: `pip install build`)
231
+ 4. Install the built package: `pip install dist/zssdk_python-*.whl` or `pip install dist/zssdk_python-*.tar.gz`
232
+
233
+ ---
234
+
235
+ ## Getting Started
236
+
237
+ ### Authentication
238
+
239
+ The SDK uses OAuth2 via [Zscaler Identity (Zidentity)](https://help.zscaler.com/zidentity/what-zidentity). You must have an API Client created in the [ZIdentity platform](https://help.zscaler.com/zidentity/about-api-clients).
240
+
241
+ #### OneAPI (API Client Scope)
242
+
243
+ OneAPI resources are automatically created within the ZIdentity Admin UI based on the RBAC roles applicable to APIs within the various products. For example, in ZIA, navigate to **Administration → Role Management** and select **Add API Role**. Once this role has been saved, return to the ZIdentity Admin UI and from the **Integration** menu select **API Resources**. Click the **View** icon to the right of Zscaler APIs and under the ZIA dropdown you will see the newly created role. In the event a newly created role is not seen in the ZIdentity Admin UI, a **Sync Now** button is provided in the API Resources menu which initiates an on-demand sync of newly created roles.
244
+
245
+ **Required parameters:**
246
+
247
+ - **vanity_domain** — Your organization's vanity domain (e.g., `acme`). Use only the vanity part; full domains like `acme.zslogin.net` are not allowed. Refers to the domain used by your organization: `https://<vanity_domain>.zslogin.net/oauth2/v1/token`.
248
+ - **client_id** — Your Zidentity API Client ID
249
+ - **client_secret** — Your API Client secret
250
+ - **cloud** — (Optional) Omit for production. Use only when authenticating to a non-production environment such as `alpha` or `beta` (test-based tenants).
251
+
252
+ > **Caution:** Do not hard-code credentials. Use environment variables or the configuration file instead.
253
+
254
+ ### Basic Usage
255
+
256
+ Create a `Session` and access services as attributes. The SDK dynamically provides service resources when you access them.
257
+
258
+ ```python
259
+ import os
260
+ from zssdk import Session
261
+
262
+ # Create a session using environment variables (omit cloud for production)
263
+ session = Session(
264
+ cloud=os.getenv("ZSCALER_CLOUD"), # Optional: only for alpha/beta
265
+ vanity_domain=os.getenv("ZSCALER_VANITY_DOMAIN"),
266
+ client_id=os.getenv("ZSCALER_CLIENT_ID"),
267
+ client_secret=os.getenv("ZSCALER_CLIENT_SECRET"),
268
+ )
269
+
270
+ # Access ZIA and list VPN credentials
271
+ zia = session.zia
272
+ for cred in zia.vpn_credentials.all().limit(10):
273
+ print(cred.fqdn, cred.id)
274
+
275
+ # Access ZID and list user profiles
276
+ zid = session.zid
277
+ for user in zid.user_profiles.all().limit(5):
278
+ print(user.login_name, user.display_name)
279
+ ```
280
+
281
+ **Using the default session:** You can call `setup_default_session(**kwargs)` once to configure a shared session, then use `get_default_session()` anywhere. The `zssdk.client()` helper returns a low-level client from the default session.
282
+
283
+ ---
284
+
285
+ ## Configuration
286
+
287
+ ### Configuration File
288
+
289
+ Create a configuration file at `~/.zscaler/config`. The file uses INI format with named profiles (you can also use `config.ini` and pass `config_file="/path/to/config.ini"` to `Session`):
290
+
291
+ ```ini
292
+ [default]
293
+ vanity_domain = your_vanity_domain
294
+ client_id = your_client_id
295
+ client_secret = your_client_secret
296
+
297
+ [beta]
298
+ cloud = beta
299
+ vanity_domain = your_vanity_domain
300
+ client_id = your_beta_client_id
301
+ client_secret = your_beta_client_secret
302
+ ```
303
+
304
+ > **Note:** Profile names (e.g., `[default]`, `[beta]`) are arbitrary labels you choose. The `cloud` key within a profile is what selects the non-production Zscaler environment. Omit `cloud` entirely for production.
305
+
306
+ Use a profile by name:
307
+
308
+ ```python
309
+ session = Session(profile_name="beta")
310
+ ```
311
+
312
+ For multi-product setups with different clouds, define separate profiles and pass `profile_name` when creating the session for each product.
313
+
314
+ ### Environment Variables
315
+
316
+ **Credential and cloud settings** (prefix `ZSCALER_`):
317
+
318
+ | Variable | Description |
319
+ |--------------------------|----------------------------------------------------------|
320
+ | `ZSCALER_CLOUD` | Non-production environment only (e.g., `alpha`, `beta`); omit for production |
321
+ | `ZSCALER_VANITY_DOMAIN` | Your organization's vanity domain |
322
+ | `ZSCALER_CLIENT_ID` | OAuth2 Client ID |
323
+ | `ZSCALER_CLIENT_SECRET` | OAuth2 Client Secret |
324
+ | `ZSCALER_PRIVATE_KEY` | Private key string (for JWT Bearer auth) |
325
+ | `ZSCALER_CERT_FILE_PATH` | Path to private key file (for certificate-based auth) |
326
+ | `ZSCALER_PROFILE` | Default profile name (default: `default`) |
327
+
328
+ **SDK-level settings** (prefix `ZSSDK_`), defined in `zssdk.zscore.configprovider`:
329
+
330
+ | Variable | Description |
331
+ |--------------------------|----------------------------------------------------------|
332
+ | `ZSSDK_API_VERSION` | API version (default: `v1`) |
333
+ | `ZSSDK_USE_FIPS_ENDPOINT`| Use FIPS endpoints (`true` / `false`) |
334
+ | `ZSSDK_LOG_ENABLED` | Enable SDK logging (`true` / `false`) |
335
+ | `ZSSDK_LOG_VERBOSE` | Verbose logging (`true` / `false`) |
336
+ | `ZSSDK_LOG_TO_FILE` | Log to file (`true` / `false`) |
337
+ | `ZSSDK_LOG_FILE_PATH` | Log file path (default: `zssdk.log`) |
338
+ | `ZSSDK_LOG_FORMAT` | Log format: `basic`, `json`, or `custom` (see [Logging](#logging)) |
339
+
340
+ ### Constructor Parameters
341
+
342
+ You can pass credentials and settings directly to `Session`:
343
+
344
+ ```python
345
+ session = Session(
346
+ vanity_domain="acme",
347
+ client_id="your_client_id",
348
+ client_secret="your_client_secret",
349
+ profile_name="beta", # Use config file profile
350
+ config_file="/path/to/config", # Custom config path
351
+ )
352
+ ```
353
+
354
+ For JWT Bearer (client assertion) authentication:
355
+
356
+ ```python
357
+ session = Session(
358
+ vanity_domain="acme",
359
+ client_id="your_client_id",
360
+ cert_file_path="/path/to/private_key.pem", # Or private_key="<key string>"
361
+ )
362
+ ```
363
+
364
+ ### Configuration Precedence
365
+
366
+ Configuration is resolved in the following order (highest to lowest):
367
+
368
+ 1. Constructor arguments
369
+ 2. Instance variables set via `session.set_config_variable()`
370
+ 3. Environment variables
371
+ 4. Configuration file (profile)
372
+ 5. Default values
373
+
374
+ ### User-Agent and Custom Headers
375
+
376
+ The SDK sends a `User-Agent` header with each request in the format: `oneapi-sdk/<version> python/<py_version> <os>/<os_version>`. You can append custom text via the `Config` object:
377
+
378
+ ```python
379
+ from zssdk.zscore.config import Config
380
+
381
+ config = Config(user_agent_extra="my-app/1.0")
382
+ session = Session(config=config, profile_name="beta")
383
+ # User-Agent will be: oneapi-sdk/<version> python/<version> <os>/<release> my-app/1.0
384
+ ```
385
+
386
+ ---
387
+
388
+ ## API Layers
389
+
390
+ The SDK exposes two ways to interact with Zscaler APIs.
391
+
392
+ ### Resource Layer (Recommended)
393
+
394
+ The resource layer provides a Pythonic, object-oriented interface. Access services as session attributes and work with resources as objects.
395
+
396
+ **Creating and managing a resource:**
397
+
398
+ ```python
399
+ import zssdk
400
+
401
+ session = zssdk.Session(profile_name="default")
402
+ zia = session.zia
403
+
404
+ # Create a new VPN credential
405
+ cred = zia.VpnCredential()
406
+ cred.type = "UFQDN"
407
+ cred.fqdn = "office@example.zslogin.net"
408
+ cred.pre_shared_key = "somekey"
409
+ cred.create()
410
+ print(f"Created credential with ID: {cred.id}")
411
+
412
+ # Load an existing resource by ID
413
+ loaded = zia.VpnCredential(id=cred.id)
414
+ loaded.load()
415
+
416
+ # Update
417
+ loaded.pre_shared_key = "newkey"
418
+ loaded.update()
419
+
420
+ # Delete
421
+ cred.delete()
422
+ ```
423
+
424
+ **Working with collections:**
425
+
426
+ ```python
427
+ # List all (iterates over paginated results)
428
+ for item in zia.vpn_credentials.all():
429
+ print(item.fqdn)
430
+
431
+ # Apply server-side filters
432
+ for item in zia.vpn_credentials.all().filter(type="UFQDN"):
433
+ print(item.fqdn)
434
+
435
+ # Limit results
436
+ for item in zia.vpn_credentials.all().limit(20):
437
+ print(item.fqdn)
438
+
439
+ # Control page size for performance tuning
440
+ for item in zia.vpn_credentials.all().page_size(50).limit(100):
441
+ print(item.fqdn)
442
+
443
+ # Client-side filtering with JMESPath (see Collections and Pagination for more examples)
444
+ for item in zia.vpn_credentials.all().search("[?type=='UFQDN']"):
445
+ print(item.fqdn)
446
+
447
+ # Iterate by page
448
+ for page in zia.vpn_credentials.all().pages():
449
+ for item in page:
450
+ print(item.fqdn)
451
+ ```
452
+
453
+ **ZID (Zscaler Identity) example:**
454
+
455
+ ```python
456
+ zid = session.zid
457
+
458
+ # Create user profile
459
+ user = zid.UserProfile()
460
+ user.login_name = "john.doe@example.com"
461
+ user.display_name = "John Doe"
462
+ user.primary_email = "john.doe@example.com"
463
+ user.status = True
464
+ user.create()
465
+
466
+ # List groups
467
+ for group in zid.groups.all().limit(10):
468
+ print(group.name)
469
+ ```
470
+
471
+ ### Service Client Layer
472
+
473
+ For lower-level access, you can obtain a raw service client via `session.client("zia")`. This returns a low-level client whose methods map directly to API operations. For typical usage, prefer the resource layer above. Use `session.get_available_services()` to list available service names (`zia`, `zid`, `zcc`, `zpa`, `zdx`, `ztw`) and `session.get_available_resources()` for resource-style service names.
474
+
475
+ ---
476
+
477
+ ## Supported Products
478
+
479
+ | Product | Service Name | Description |
480
+ |----------------------------|--------------|--------------------------------------------------|
481
+ | Zscaler Internet Access | `zia` | ZIA administration and policy management |
482
+ | Zscaler Identity | `zid` | User, group, and API client management |
483
+ | Zscaler Client Connector | `zcc` | Client Connector administration |
484
+ | Zscaler Private Access | `zpa` | ZPA configuration and policies |
485
+ | Zscaler Digital Experience | `zdx` | ZDX monitoring and analytics |
486
+ | Zscaler Cloud & Branch Connector | `ztw` | Cloud & Branch Connector management |
487
+
488
+ ---
489
+
490
+ ## ZPA: customer_id Requirement
491
+
492
+ When interacting with **Zscaler Private Access (ZPA)** endpoints, you must provide `customer_id` in addition to the standard authentication parameters. The `customer_id` is the ZPA tenant ID, found under **Configuration & Control → Public API → API Keys** in the ZPA Admin Portal.
493
+
494
+ For ZPA resources, pass `customer_id` as a parameter to each operation. Every ZPA API call includes `customer_id` in the request path (e.g., `/customers/{customerId}/...`), so you must supply it when creating, updating, or querying ZPA resources.
495
+
496
+ `microtenant_id` is optional and only required when using ZPA with Microtenant; pass `0` for the default microtenant.
497
+
498
+ ---
499
+
500
+ ## ZIA and ZTW Context Manager
501
+
502
+ The SDK provides a context manager pattern for **ZIA** and **ZTW** that automatically activates configuration changes when exiting the block.
503
+
504
+ ### How It Works
505
+
506
+ When you use the `with` statement with `session.zia` or `session.ztw`:
507
+
508
+ 1. **Entry** — The service resource is returned; you make configuration changes within the block.
509
+ 2. **Exit** — When exiting the context (successfully or via exception), the SDK runs a finalize workflow that activates staged changes.
510
+
511
+ ### Activation Process
512
+
513
+ - **ZIA** — The finalize workflow calls the activation status endpoint. If the status is `PENDING`, it deauthenticates the session, which triggers activation of all staged configuration changes.
514
+ - **ZTW** — The finalize workflow fetches the status; if `PENDING`, it explicitly calls the Activate endpoint.
515
+
516
+ ### Example
517
+
518
+ ```python
519
+ import zssdk
520
+
521
+ session = zssdk.Session(profile_name="default")
522
+
523
+ # ZIA: context manager activates changes on exit
524
+ with session.zia as zia:
525
+ role = zia.AdminRole()
526
+ role.name = "New API Role"
527
+ role.description = "Role created via API"
528
+ role.create()
529
+ # All staged ZIA changes are activated here
530
+
531
+ # ZTW: context manager activates changes on exit
532
+ with session.ztw as ztw:
533
+ group = ztw.IpDestinationGroup()
534
+ group.name = "New IP Group"
535
+ group.description = "IP group via API"
536
+ group.create()
537
+ # All staged ZTW changes are activated here
538
+ ```
539
+
540
+ ### Benefits
541
+
542
+ - **Automatic activation** — No need to call activation endpoints manually.
543
+ - **Deterministic behavior** — Exiting the context always triggers the activation workflow.
544
+ - **Error handling** — Even if an exception occurs, the context manager runs the finalize logic on normal exit (exceptions are not suppressed).
545
+
546
+ ---
547
+
548
+ ## Collections and Pagination
549
+
550
+ Collections support the following methods:
551
+
552
+ | Method | Description |
553
+ |-----------------|-------------------------------------------------------------------|
554
+ | `.all()` | Returns an iterable over all resources (handles pagination) |
555
+ | `.filter(**kwargs)` | Applies server-side filters (snake_case or camelCase) |
556
+ | `.limit(n)` | Stops after yielding `n` resources |
557
+ | `.page_size(n)` | Sets the number of resources fetched per API request |
558
+ | `.search(expr)` | Client-side JMESPath filtering on each page |
559
+ | `.pages()` | Yields pages (lists) of resources instead of individual items |
560
+
561
+ Example with combined options:
562
+
563
+ ```python
564
+ # Server-side filter, custom page size, limit total results
565
+ for cred in (
566
+ zia.vpn_credentials.all()
567
+ .filter(type="UFQDN")
568
+ .page_size(25)
569
+ .limit(100)
570
+ ):
571
+ print(cred.fqdn)
572
+ ```
573
+
574
+ ### Client-side filtering with JMESPath
575
+
576
+ The `.search(expr)` method applies a [JMESPath](https://jmespath.org/) expression on each page of results. Use it when you need filtering that the API does not support server-side. The expression is applied to the items array, so you write it relative to each item.
577
+
578
+ ```python
579
+ # Exact match on a field
580
+ for user in zia.admin_users.search("[?name == 'SDWAN-SilverPeak']"):
581
+ print(user.name)
582
+
583
+ # Multiple values with OR
584
+ for user in zia.admin_users.search("[?name == 'SDWAN-SilverPeak' || name == 'SDWAN-VeloCloud']"):
585
+ print(user.name)
586
+
587
+ # Substring match using contains()
588
+ for user in zia.admin_users.search("[?contains(name, 'SilverPeak')]"):
589
+ print(user.name)
590
+
591
+ # Chain with server-side filter (filter first to reduce data, then search)
592
+ for user in zia.admin_users.filter(search="SDWAN").search("[?contains(name, 'SilverPeak')]"):
593
+ print(user.name)
594
+
595
+ # Chain with limit and page_size
596
+ for user in zia.admin_users.search("[?name == 'SDWAN-SilverPeak']").limit(10).page_size(50):
597
+ print(user.name)
598
+ ```
599
+
600
+ ---
601
+
602
+ ## Error Handling
603
+
604
+ The SDK raises structured exceptions:
605
+
606
+ | Exception | Base | When it occurs |
607
+ |----------------------|---------------|----------------------------------------------------|
608
+ | `OneApiError` | — | Base SDK error |
609
+ | `ZsResourceError` | `OneApiError` | Resource-level errors; includes `resource_name`, `action_name` |
610
+ | `BadRequestException`| `ZsResourceError` | API returns 400 Bad Request |
611
+ | `NotFoundException` | `ZsResourceError` | API returns 404 Not Found |
612
+
613
+ Additional resource-specific exceptions (e.g., `ConflictException`) may be defined in `zssdk.zsresource.exceptions`.
614
+
615
+ **Example:**
616
+
617
+ ```python
618
+ from zssdk.zscore import OneApiError
619
+ from zssdk.zsresource import ZsResourceError
620
+ from zssdk.zsresource.exceptions import BadRequestException
621
+
622
+ try:
623
+ cred = zia.VpnCredential()
624
+ cred.fqdn = "invalid"
625
+ cred.create()
626
+ except BadRequestException as e:
627
+ print(f"Bad request: {e}")
628
+ except ZsResourceError as e:
629
+ print(f"Resource error: {e.resource_name} / {e.action_name}: {e}")
630
+ except OneApiError as e:
631
+ print(f"SDK error: {e}")
632
+ ```
633
+
634
+ ---
635
+
636
+ ## Rate Limiting and Retry Mechanism
637
+
638
+ Each Zscaler product has its own rate limiting criteria. Product-specific limits and quotas are documented in the [Zscaler Automation Hub Rate Limiting Guide](https://automate.zscaler.com/docs/docs/api-reference-and-guides/api-reference/guides/rate-limiting).
639
+
640
+ ### Built-in Retry Mechanism
641
+
642
+ The SDK includes a built-in retry mechanism (configured in `zssdk.zscore.data._retry`) that handles rate limiting and transient failures automatically. When a retryable response or connection error occurs, the SDK:
643
+
644
+ 1. **Checks for rate limit headers** — If present, waits the specified time before retrying.
645
+ 2. **Falls back to exponential backoff** — If no header is present, uses exponential backoff (base 0.3s, growth factor 2).
646
+ 3. **Caps wait time** — Maximum wait is 300 seconds per retry.
647
+ 4. **Limits attempts** — Retries up to 3 times (`max_attempts`) before raising the final exception.
648
+
649
+ The retry logic is applied per request across all supported products (ZIA, ZID, ZCC, ZPA, ZDX, ZTW).
650
+
651
+ ### HTTP Status Codes That Trigger Retries
652
+
653
+ The SDK retries requests when it receives one of the following responses:
654
+
655
+ | Status Code | Meaning | Policy Name |
656
+ |-------------|-------------------------|--------------------|
657
+ | `429` | Too Many Requests | TooManyRequests, Throttling |
658
+ | `500` | Internal Server Error | ServerError (with TransientFailure) |
659
+ | `502` | Bad Gateway | BadGateway |
660
+ | `503` | Service Unavailable | ServiceUnavailable |
661
+ | `504` | Gateway Timeout | GatewayTimeout |
662
+
663
+ Connection errors (e.g., `ConnectionError`, `ReadTimeoutError`) also trigger retries.
664
+
665
+ ### Retry-After and Rate Limit Headers
666
+
667
+ When rate limiting is enabled (default), the SDK uses response headers to determine how long to wait before retrying. Headers are checked in this order:
668
+
669
+ 1. **`Retry-After`** or **`retry-after`** — Standard HTTP headers. Supports values like `9` (seconds) or `9s`.
670
+ 2. **`x-ratelimit-reset`**, **`X-RateLimit-Reset`**, **`RateLimit-Reset`**, **`X-Rate-Limit-Retry-After-Seconds`** — Product-specific headers indicating seconds until the rate limit resets.
671
+
672
+ If no rate limit header is present, the SDK falls back to **exponential backoff** (base 0.3s, growth factor 2).
673
+
674
+ ---
675
+
676
+ ## Logging
677
+
678
+ SDK logging is controlled by environment variables (see [Environment Variables](#environment-variables)) or a `LoggerConfig` object.
679
+
680
+ ### Log format (`ZSSDK_LOG_FORMAT`)
681
+
682
+ The `logging_format` setting supports three values:
683
+
684
+ | Format | Description |
685
+ |-----------|-----------------------------------------------------------------------------|
686
+ | `basic` | Human-readable lines: `%(asctime)s - %(name)s - %(module)s - %(levelname)s - %(message)s`. Default format. |
687
+ | `json` | Structured JSON output, one record per line, suitable for log aggregators (e.g., Grafana Loki). |
688
+ | `custom` | Use your own `logging.Formatter` instance. **Only available programmatically** via `LoggerConfig`; requires passing `custom_formatter` and cannot be set via environment variables. |
689
+
690
+ **Environment variables example:**
691
+
692
+ ```sh
693
+ export ZSSDK_LOG_ENABLED=true
694
+ export ZSSDK_LOG_VERBOSE=false
695
+ export ZSSDK_LOG_TO_FILE=false
696
+ export ZSSDK_LOG_FILE_PATH=zssdk.log
697
+ export ZSSDK_LOG_FORMAT=basic
698
+ ```
699
+
700
+ **Programmatic configuration:**
701
+
702
+ ```python
703
+ from zssdk.zscore.config import Config, LoggerConfig
704
+
705
+ config = Config(
706
+ logger_config=LoggerConfig(
707
+ enabled=True,
708
+ verbose=False,
709
+ logging_format="json",
710
+ log_to_file=True,
711
+ log_file_path="/var/log/zssdk.log",
712
+ )
713
+ )
714
+ session = Session(config=config, profile_name="default")
715
+ ```
716
+
717
+ **Custom format (programmatic only):**
718
+
719
+ ```python
720
+ import logging
721
+ from zssdk.zscore.config import Config, LoggerConfig
722
+
723
+ custom_formatter = logging.Formatter("%(levelname)s | %(message)s")
724
+ config = Config(
725
+ logger_config=LoggerConfig(
726
+ enabled=True,
727
+ logging_format="custom",
728
+ custom_formatter=custom_formatter,
729
+ )
730
+ )
731
+ session = Session(config=config, profile_name="default")
732
+ ```
733
+
734
+ Sensitive fields (tokens, secrets, passwords) are redacted in log output.
735
+
736
+ ---
737
+
738
+ ## Auto-completion and IntelliSense
739
+
740
+ The SDK ships with PEP 484 [type stub](https://peps.python.org/pep-0484/) files (`.pyi`) that enable rich IDE support. Compatible editors (e.g., VS Code with Pylance, PyCharm) automatically use these stubs for:
741
+
742
+ - **Auto-completion** — As you type `session.zia.` or `cred.`, the IDE suggests available resources, methods, and properties.
743
+ - **Parameter hints** — Method signatures and parameter names appear in tooltips.
744
+ - **Docstrings** — Resource and method documentation is shown in hover tooltips.
745
+ - **Type checking** — Static type checkers (e.g., Pyright, mypy) can validate your code.
746
+
747
+ ### What You Get
748
+
749
+ | Location | Stub file(s) | Purpose |
750
+ |-----------------------|------------------------|----------------------------------------------|
751
+ | Session / services | `session.pyi` | `session.zia`, `session.zid`, etc. |
752
+ | ZIA resources | `zia_resources.pyi` | `VpnCredential`, `AdminUser`, collections |
753
+ | ZID resources | `zid_resources.pyi` | `UserProfile`, `Group`, `ApiClient` |
754
+ | ZPA, ZCC, ZDX, ZTW | `*_resources.pyi` | Product-specific resources and methods |
755
+ | Low-level clients | `*_client.pyi` | Service client method signatures |
756
+
757
+ ### Setup
758
+
759
+ No additional setup is required. The stubs are part of the installed package and are picked up automatically by IDEs that support PEP 484. Ensure your IDE's Python interpreter points to the environment where `zscaler-sdk-python` is installed.
760
+
761
+ ### Example
762
+
763
+ When you type `session.zia.` in VS Code or PyCharm, you will see completions for resources such as `VpnCredential`, `AdminUser`, `vpn_credentials`, and `admin_users`. Selecting a resource shows its available properties and methods (e.g., `create()`, `load()`, `update()`, `delete()`).
764
+
765
+ ---
766
+
767
+ ## Examples
768
+
769
+ The repository includes runnable CLI scripts and inline examples under `examples/`, organized by product. Prerequisites and configuration are covered in the [Configuration](#configuration) section above.
770
+
771
+ All CLI scripts are self-documenting. Run any script with no arguments for a usage hint, or `--help` for the full reference:
772
+
773
+ ```sh
774
+ python examples/zid/user_management/user_management.py --help
775
+ python examples/zia/vpn_credentials_management/vpn_credentials_management.py --help
776
+ ```
777
+
778
+ ---
779
+
780
+ ## Migrating from zscaler-sdk-python
781
+
782
+ If you are coming from the previous [`zscaler-sdk-python`](https://github.com/zscaler/zscaler-sdk-python) package, here is what changes.
783
+
784
+ ### Installation
785
+
786
+ ```sh
787
+ # Remove the old package
788
+ pip uninstall zscaler-sdk-python
789
+
790
+ # Install the new package
791
+ pip install zscaler-sdk-python
792
+ ```
793
+
794
+ The import name changes from `zscaler` to `zssdk`.
795
+
796
+ ### Authentication
797
+
798
+ **Before:**
799
+
800
+ ```python
801
+ from zscaler import ZscalerClient
802
+
803
+ config = {
804
+ "clientId": "...",
805
+ "clientSecret": "...",
806
+ "vanityDomain": "...",
807
+ "cloud": "beta",
808
+ }
809
+ client = ZscalerClient(config)
810
+ ```
811
+
812
+ **After:**
813
+
814
+ ```python
815
+ from zssdk import Session
816
+
817
+ session = Session(
818
+ client_id="...",
819
+ client_secret="...",
820
+ vanity_domain="...",
821
+ cloud="beta",
822
+ )
823
+ ```
824
+
825
+ Key differences:
826
+ - Constructor uses Python keyword arguments (`snake_case`) instead of a config dictionary (`camelCase`).
827
+ - Configuration can also come from `~/.zscaler/config` (INI format) or environment variables. See [Configuration](#configuration).
828
+
829
+ ### Working with resources
830
+
831
+ **Before** — dict access, error tuples:
832
+
833
+ ```python
834
+ with ZscalerClient(config) as client:
835
+ role, resp, err = client.zia.admin_roles.get_role(role_id="12345")
836
+ if err:
837
+ print(f"Error: {err}")
838
+ else:
839
+ print(role["name"])
840
+ ```
841
+
842
+ **After** — resource objects, exceptions:
843
+
844
+ ```python
845
+ from zssdk.zsresource.exceptions import NotFoundException
846
+
847
+ try:
848
+ role = session.zia.AdminRole(id=12345)
849
+ role.load()
850
+ print(role.name)
851
+ except NotFoundException:
852
+ print("Role not found")
853
+ ```
854
+
855
+ ### Pagination
856
+
857
+ **Before** — manual loop:
858
+
859
+ ```python
860
+ groups, resp, err = client.zia.user_management.list_groups()
861
+ while resp.has_next():
862
+ more, resp, err = resp.next()
863
+ if err:
864
+ break
865
+ groups.extend(more)
866
+ ```
867
+
868
+ **After** — iterator with chaining:
869
+
870
+ ```python
871
+ # All groups, paginated automatically
872
+ for group in session.zia.admin_roles.all():
873
+ print(group.name)
874
+
875
+ # With server-side filter and limit
876
+ for group in session.zia.admin_roles.filter(search="API").limit(50):
877
+ print(group.name)
878
+ ```
879
+
880
+ ### Configuration
881
+
882
+ **Before** — YAML file at `~/.zscaler/zscaler.yaml`:
883
+
884
+ ```yaml
885
+ zscaler:
886
+ client:
887
+ clientId: "..."
888
+ clientSecret: "..."
889
+ vanityDomain: "..."
890
+ ```
891
+
892
+ **After** — INI file at `~/.zscaler/config`:
893
+
894
+ ```ini
895
+ [default]
896
+ vanity_domain = ...
897
+ client_id = ...
898
+ client_secret = ...
899
+ ```
900
+
901
+ ### Quick reference
902
+
903
+ | What | `zscaler-sdk-python` v1 | `zscaler-sdk-python` v2 |
904
+ |---|---|---|
905
+ | Import | `from zscaler import ZscalerClient` | `from zssdk import Session` |
906
+ | Access field | `user["name"]` | `user.name` |
907
+ | Create resource | `client.zia.admin_roles.add_role(name="X")` | `role = session.zia.AdminRole(); role.name = "X"; role.create()` |
908
+ | Delete resource | `client.zia.admin_roles.delete_role(role_id="123")` | `role = session.zia.AdminRole(id=123); role.delete()` |
909
+ | Handle error | `result, resp, err = ...; if err: ...` | `try: ... except NotFoundException: ...` |
910
+ | Paginate | `while resp.has_next(): resp.next()` | `for item in collection.all():` |
911
+ | Filter | `query_params={"search": "X"}` | `.filter(search="X")` or `.search("[?name=='X']")` |
912
+ | Config file | `~/.zscaler/zscaler.yaml` | `~/.zscaler/config` (INI) |
913
+
914
+ ---
915
+
916
+ ## Contributing
917
+
918
+ Contributions are welcome. Please follow the project's coding standards and submit pull requests via the repository's normal workflow.
919
+
920
+ ---
921
+
922
+ ## Need Help?
923
+
924
+ - [Zscaler Community](https://community.zscaler.com/)
925
+ - [OneAPI Documentation](https://help.zscaler.com/oneapi/understanding-oneapi)
926
+ - [Zscaler Identity API](https://help.zscaler.com/zidentity/getting-started-zidentity-api)
927
+ - [ZIA API](https://help.zscaler.com/zia/getting-started-zia-api)
928
+ - [Automation Docs](http://automation.zsapidocs.net/docs/)