Skip to main content

Python

An overview of the Python Promise-writing SDK.

Features

  • Resource Management: Read and write Kratix resources and promises
  • Status Handling: Update resource status and write status files
  • Output Generation: Write workflow outputs to files
  • Destination Selectors: Configure where resources should be deployed
  • Environment Variables: Access workflow context (action, type, promise name, pipeline name)

Installation

pip install git+https://github.com/syntasso/kratix-python.git

Usage

import kratix_sdk as ks

def main():
sdk = ks.KratixSDK()
resource = sdk.read_resource_input()
print(f'Name" {resource.get_name()}')

if __name__ == '__main__':
main()
info

You can find more usage examples in the Repository github.com/syntasso/kratix-python

Resources

License

kratix-python is licensed under the Apache License 2.0. See the full License for details.