chariot.awm package

Submodules

chariot.awm.models module

class chariot.awm.models.PodDetails(name: str, status: str)[source]

Bases: Base

Pod details.

name: str
status: str
class chariot.awm.models.Workflow(id: str, name: str, description: str, project_id: str, config: dict[str, Any] | None, public_settings: dict[str, WorkflowPublicSettingRef] | None, created_at: datetime, created_by: str, updated_at: datetime, updated_by: str, deleted_at: datetime | None, deleted_by: str | None)[source]

Bases: Base

An instance of a workflow.

config: dict[str, Any] | None
created_at: datetime
created_by: str
deleted_at: datetime | None
deleted_by: str | None
description: str
id: str
name: str
project_id: str
public_settings: dict[str, WorkflowPublicSettingRef] | None
updated_at: datetime
updated_by: str
class chariot.awm.models.WorkflowPublicSettingRef(ref: str, schema: Any | None = None)[source]

Bases: Base

A reference to a public setting, with optional schema.

ref: str
schema: Any | None = None
class chariot.awm.models.WorkflowPublicSettingValue(value: Any, schema: Any | None = None)[source]

Bases: Base

A public setting value. The schema (if one exists), should be treated as read-only and is used for documentation purposes.

schema: Any | None = None
value: Any
class chariot.awm.models.WorkflowResourceDetails(valid: bool, deployment: str, pods: list[PodDetails])[source]

Bases: Base

Resources of a workflow. Valid is false if any resources are missing, and any attempts to use this workflow will likely fail.

deployment: str
pods: list[PodDetails]
valid: bool

chariot.awm.workflows module

chariot.awm.workflows.create_workflow(project_id: str, name: str, description: str, config: dict[str, Any], paused: bool = False, public_settings: dict[str, WorkflowPublicSettingRef] | None = None) Workflow[source]

Create a workflow for a project.

Parameters:
  • project_id (str) – Project id

  • name (str) – Name of the workflow

  • description (str) – Description of the workflow

  • config (Dict[str, Any]) – The workflow configuration

  • paused (bool) – Set to true to not create an agent process pod

  • public_settings (Optional[Dict[str, models.WorkflowPublicSettingRef]]) – Public settings for the workflow

Return type:

models.Workflow

chariot.awm.workflows.delete_workflow(workflow_id: str)[source]

Delete a workflow for a project.

Parameters:

workflow_id (str) – Workflow id

Return type:

None

chariot.awm.workflows.get_public_setting_values(workflow_id: str) dict[str, WorkflowPublicSettingValue][source]

Get workflow public setting values.

Parameters:

workflow_id (str) – Workflow id

Return type:

dict[str, models.WorkflowPublicSettingValue]

chariot.awm.workflows.get_workflow(workflow_id: str) Workflow[source]

Get a workflow for a project.

Parameters:

workflow_id (str) – Workflow id

Return type:

models.Workflow

chariot.awm.workflows.get_workflows(name: str | None = None, project_ids: list[str] | None = None, include_deleted: bool | None = None, limit: int | None = None, after_key: str | None = None) Generator[Workflow, None, None][source]

List workflows matching the specified filters.

Parameters:
  • name (Optional[str]) – Partial, case-insensitive name filter

  • project_ids (Optional[List[str]]) – List of project ids to filter

  • include_deleted (Optional[bool]) – Set to True to include deleted workflows

  • limit (Optional[int]) – The max number of items to return

  • after_key (Optional[str]) – The pagination key to fetch more items

Return type:

Generator[models.Workflow, None, None]

chariot.awm.workflows.initialize_workflow_user(workflow_id: str, agent_name: str)[source]

Initialize a user for a particular workflow and agent.

Parameters:
  • workflow_id (str) – Workflow id

  • agent_name (str) – Agent name

Return type:

None

chariot.awm.workflows.patch_public_setting_values(workflow_id: str, public_setting_values: dict[str, WorkflowPublicSettingValue]) dict[str, WorkflowPublicSettingValue][source]

Patch workflow public setting values.

Parameters:
Return type:

dict[str, models.WorkflowPublicSettingValue]

chariot.awm.workflows.update_workflow(workflow_id: str, name: str, description: str, config: dict[str, Any], paused: bool = False, public_settings: dict[str, WorkflowPublicSettingRef] | None = None) Workflow[source]

Update a workflow by the id.

Parameters:
  • workflow_id (str) – Workflow id

  • name (str) – Name of the workflow

  • description (str) – Description of the workflow

  • config (Dict[str, Any]) – The workflow configuration

  • paused (bool) – Set to true to not create an agent process pod

  • public_settings (Optional[Dict[str, models.WorkflowPublicSettingRef]]) – Public settings for the workflow

Return type:

models.Workflow

Module contents