Skip to content

shmoeshmeps/zscaler_api_talkers

 
 

Repository files navigation

Unofficial Zscaler API talkers

ZIA API Talker

Python client to leverage Zscaler Internet Access API

ZPA API Talker

Python client to leverage Zscaler Private Access API

ZCC API Talker

Python client to leverage Zscaler Client Connector API. ( Currently in Beta status)

Installation

Option1: Run within a Docker Container

# Download Dockerfile
Linux:
curl -O https://raw.githubusercontent.com/sergitopereira/zscaler_api_talkers/sergiodevelop/Dockerfile
Windows:
wget -O Dockerfile https://raw.githubusercontent.com/sergitopereira/zscaler_api_talkers/sergiodevelop/Dockerfile 

# Build Image and Run Container
docker build -t zscaler_api_talkers .  
docker run -it zscaler_api_talkers bash

# Usage (program is in /zscaler_api_talkers/)
cd zscaler_api_talkers

Option2: Run in a Python Virtual Environment

* Create a virtual Environment:
  python3 -m venv .zs_api_talkers
* Activate virtual environment
  # Linux
  source .zs_api_talkers/bin/activate
  # Windows
  .\.zs_api_talkers\Scripts\activate
* Install Zscales API talkers
   pip install zscaler-api-talkers  

Zscaler Secure Internet and SaaS Access SDK (zia_talker)

Usage zia_talker

from zia_talker.zia_talker import ZiaTalker
zia=ZiaTalker('<Zscaler Cloud Name>')
zia.authenticate(apikey='API_KEY', username='USERNAME', password='PASSWORD')
zia.list_urlcategories()
zia.list_users()
# To view all methods available
print(dir(zia))

Usage zia_talker with OAUTH2.0

from zia_talker.zia_talker import ZiaTalker
a=ZiaTalker('<Zscaler Cloud Name>', <Bear oauth2.0 token))
a.list_url_categorie.url_categories()
a.list_users()
# To view all methods available
print(dir(a))

Zscaler Secure Private Access SDK (zpa_talker)

Usage zpa_talker

from zpa_talker.zpa_talker import ZpaTalker
a=ZpaTalker('customerID')
a.authenticate(client_id='clientID',client_secret='clientSecret')
# To view all methods available
print(dir(a))

Zscaler Client Connector SDK (zcc_talker)

Usage zcc_talker

from zcc_talker.zcc_talker import ZccTalker
a=ZccTalker('<Zscaler Cloud Name>')    
a.authenticate(clientid='clientID',secretkey='clientSecret')
a.list_devices('companyID')
a.list_OTP('companyID','user device id')
# To view all methods available
print(dir(a))

Usage example

https://github.com/sergitopereira/zscaler_api_talkers#usage-example

Bugs and enhancements

Feel free to open an issues using Gihub Issues

Author

Sergio Pereira

Zscaler Professional Services

About

Zscaler python SDK for ZIA, ZPA, ZCC

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 99.8%
  • Dockerfile 0.2%