PasswordChange
Password Change resource for Zscaler Cloud & Branch Connector.
Resource operations
This resource supports the following standard methods: create(). They operate on the instance state — set properties with dot notation, then call the method with no arguments.
Quick Start
import zssdk
import logging
# Enable debug logging for PasswordChange
logging.getLogger('zssdk.ztw').setLevel(logging.DEBUG)
logging.basicConfig(level=logging.DEBUG)
session = zssdk.Session(
vanity_domain="your-vanity-domain",
client_id="your-client-id",
client_secret="your-client-secret",
)
# Call create on PasswordChange
resource = session.ztw.PasswordChange()
result = resource.create()
print(result)
# Debug output shows HTTP request/response details
Actions
create()
Creates a new PasswordChange. Set properties on the resource instance, then call create() — this method takes no arguments.
Properties for creation:
| Name | Type | Required | Description |
|---|---|---|---|
new_password | string | No | - |
old_password | string | No | - |
user_name | string | No | - |
Example:
resource = session.ztw.PasswordChange()
resource.new_password = "value"
resource.old_password = "value"
resource.user_name = "example-user-name"
resource.create()
print(f"Created with ID: {resource.id}")
Attributes
| Name | Type | Required | Description |
|---|---|---|---|
new_password | string | No | - |
old_password | string | No | - |
user_name | string | No | - |
Related
- PasswordChange - Data structure definition
- Logging guide - enable verbose logs while debugging this resource