Cogniac / cogniac-sdk-py

Python SDK for Cogniac Public API
Apache License 2.0
5 stars 6 forks source link

Feature Request: Deploy Workflows to Deployment Groups directly with the SDK #134

Open shiloh-cog opened 9 months ago

shiloh-cog commented 9 months ago

Summary: BNSF runs many tests, and it would help them to deploy programmatically in their testing scripts. With the current SDK this can be done using the CogniacConnection's _post() method.

Example:

deployment_group_id = 'cKSpUc7sanqs'
data = {'next_workflow_id': 'QCUCB:21'}
cc._post('/deploymentGroups/' + deployment_group_id, data=data)

It would be easier if users could instead do something like:

dg = cc.get_deploymentgroup('cKSpUc7sanqs')
dg.next_workflow = 'QCUCB:21'