Skip to main content

SDK to customize event-driven actions in your Canvas instance

Project description

Getting Started

Create a file ~/.canvas/credentials.ini and add the client_id and client_secret credentials for each of your Canvas instances. You can define your default host with is_default=true. If no default is explicitly defined, the Canvas CLI will use the first instance in the file as the default for each of the CLI commands.

Example:

[my-canvas-instance]
client_id=myclientid
client_secret=myclientsecret

[my-dev-canvas-instance]
client_id=devclientid
client_secret=devclientsecret
is_default=true

[localhost]
client_id=localclientid
client_secret=localclientsecret

Next, you're ready to install canvas.

pip install canvas

Usage:

$ canvas [OPTIONS] COMMAND [ARGS]...

Options:

  • --version
  • --help: Show this message and exit.

Commands:

  • init: Create a new plugin
  • install: Install a plugin into a Canvas instance
  • uninstall: Uninstall a plugin from a Canvas instance
  • disable: Disable a plugin from a Canvas instance
  • enable: Enable a plugin from a Canvas instance
  • list: List all plugins from a Canvas instance
  • validate-manifest: Validate the Canvas Manifest json file
  • logs: Listen and print log streams from a Canvas instance

canvas init

Create a new plugin.

Usage:

$ canvas init [OPTIONS]

Options:

  • --help: Show this message and exit.

canvas install

Install a plugin into a Canvas instance.

Usage:

$ canvas install [OPTIONS] PLUGIN_NAME

Arguments:

  • PLUGIN_NAME: Path to plugin to install [required]

Options:

  • --host TEXT: Canvas instance to connect to
  • --help: Show this message and exit.

canvas uninstall

Uninstall a plugin from a Canvas instance..

Usage:

$ canvas uninstall [OPTIONS] NAME

Arguments:

  • NAME: Plugin name to delete [required]

Options:

  • --host TEXT: Canvas instance to connect to
  • --help: Show this message and exit.

canvas enable

Enable a plugin from a Canvas instance..

Usage:

$ canvas enable [OPTIONS] NAME

Arguments:

  • NAME: Plugin name to enable [required]

Options:

  • --host TEXT: Canvas instance to connect to
  • --help: Show this message and exit.

canvas disable

Disable a plugin from a Canvas instance..

Usage:

$ canvas disable [OPTIONS] NAME

Arguments:

  • NAME: Plugin name to disable [required]

Options:

  • --host TEXT: Canvas instance to connect to
  • --help: Show this message and exit.

canvas list

List all plugins from a Canvas instance.

Usage:

$ canvas list [OPTIONS]

Options:

  • --host TEXT: Canvas instance to connect to
  • --help: Show this message and exit.

canvas validate-manifest

Validate the Canvas Manifest json file.

Usage:

$ canvas validate-manifest [OPTIONS] PACKAGE

Arguments:

  • PLUGIN_NAME: Path to plugin to install [required]

Options:

  • --help: Show this message and exit.

canvas logs

Listens and prints log streams from the instance.

Usage:

$ canvas logs [OPTIONS]

Options:

  • --host TEXT: Canvas instance to connect to
  • --help: Show this message and exit.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

canvas-0.7.1.tar.gz (696.2 kB view details)

Uploaded Source

Built Distribution

canvas-0.7.1-py3-none-any.whl (795.8 kB view details)

Uploaded Python 3

File details

Details for the file canvas-0.7.1.tar.gz.

File metadata

  • Download URL: canvas-0.7.1.tar.gz
  • Upload date:
  • Size: 696.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for canvas-0.7.1.tar.gz
Algorithm Hash digest
SHA256 a7e0cf61158870f045d3dcd0c4b99699c9c883da0f72324d6f8567606e2f39c5
MD5 afd7daf6aa2549afceab2f1f1f3fed64
BLAKE2b-256 c9995c4a56b6fd57aa126a5108e672c90e31cc7392b459fa3c05340b1586371e

See more details on using hashes here.

Provenance

The following attestation bundles were made for canvas-0.7.1.tar.gz:

Publisher: publish-and-release.yml on canvas-medical/canvas-plugins

Attestations:

File details

Details for the file canvas-0.7.1-py3-none-any.whl.

File metadata

  • Download URL: canvas-0.7.1-py3-none-any.whl
  • Upload date:
  • Size: 795.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for canvas-0.7.1-py3-none-any.whl
Algorithm Hash digest
SHA256 7eedc542961dd50b9ffb73aa61d7287c2a385d3262bb82a900944fa1807cb76b
MD5 15ece8bef5bc146274140da1bfaf607d
BLAKE2b-256 4ed22fab19af8ee263a18d8e237378e6e7dcc8e78f1e6478628c0cb3ae2c1877

See more details on using hashes here.

Provenance

The following attestation bundles were made for canvas-0.7.1-py3-none-any.whl:

Publisher: publish-and-release.yml on canvas-medical/canvas-plugins

Attestations:

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page