Simplify interaction with Hannon Hill's Cascade CMS 8 REST API
Project description
Cascade CMS 8 REST API Python Driver
This is a module for simplifying interaction with Hannon Hill's Cascade CMS 8 REST API. This was built to handle some day-to-day task automation with Cascade CMS 8, e.g., access control management, workflow management, file naming rule enforcement, and more.
How it Works
The driver class CascadeCMSRestDriver constructor accepts either a username and password combination or a user-specific API key (i.e., for a service account in Cascade CMS) in addition to an organization name, e.g. "cofc". From there, it uses these values to create some headers that are used in combination with the requests library to wrap requests against the Cascade CMS REST API in simple methods, like list_sites. The methods are based on the API's WSDL description. (Replace my-org in the previous link with your own organization).
Installation
To install the package, simply run:
pip install py-cascade-cms-api
Usage
# import
from cascadecmsdriver.driver import CascadeCMSRestDriver
# you can provide a username and password or alternatively an api key
# verbose boolean indicates whether to use verbose logging
driver = CascadeCMSRestDriver(
organization_name="my-org", api_key='my-api-key', verbose=True)
## driver = CascadeCMSRestDriver(
## organization_name="my-org", username='my-username', password='my-password',
## verbose=True)
##
sites = driver.list_sites()['sites']
for s in sites:
asset = driver.read_asset(asset_type='site', asset_identifier=s['id'])
driver.debug(asset)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file py-cascade-cms-api-1.0.9.tar.gz
.
File metadata
- Download URL: py-cascade-cms-api-1.0.9.tar.gz
- Upload date:
- Size: 7.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.10.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d8e637d70bb600b7a699d121bc2a6f6ef33c4e15aa45529f122c340bdfd73656 |
|
MD5 | 8ef33800655249095f83cc6f9846f233 |
|
BLAKE2b-256 | b89c9e9ddbc8e11386a7f75f9289b70b458daad982d25d946007638ecbd37258 |
File details
Details for the file py_cascade_cms_api-1.0.9-py3-none-any.whl
.
File metadata
- Download URL: py_cascade_cms_api-1.0.9-py3-none-any.whl
- Upload date:
- Size: 7.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.10.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d2104ea10d5030cd9226486639efe0efeacd7c765c390998b8fb69de2ca1c9f6 |
|
MD5 | 393d8e42a2cacc9d8b3d03f647ff785a |
|
BLAKE2b-256 | c81ea4c1357e64a8fc9a1407cc039941835d1c1a911593fb26cad7ebba8ea904 |