Skip to content

Jobs

Accessed via client.jobs.

pyawe.client.JobsClient

JobsClient(http: _HttpSession)

Methods for the /jobs resource.

list

list(team_id: Optional[Union[UUID, str]] = None) -> List[Job]

Return all jobs, optionally filtered by team.

Parameters:

Name Type Description Default
team_id Optional[Union[UUID, str]]

When supplied, returns only jobs for this team.

None

Returns:

Type Description
List[Job]

List of :class:~pyawe.models.Job objects.

Raises:

Type Description
AweAuthError

If not authenticated.

create

create(name: str, *, status: Optional[Union[Status, str]] = None, schedule_status: Optional[Union[ScheduleStatus, str]] = None, team_id: Optional[Union[UUID, str]] = None, project_id: Optional[Union[UUID, str]] = None, job_type: Optional[str] = None, start_date: Optional[str] = None, end_date: Optional[str] = None) -> Job

Create a new job.

Parameters:

Name Type Description Default
name str

Job name.

required
status Optional[Union[Status, str]]

Initial status (default "Not Started").

None
schedule_status Optional[Union[ScheduleStatus, str]]

Initial schedule status (default "N/A").

None
team_id Optional[Union[UUID, str]]

Assign to a team.

None
project_id Optional[Union[UUID, str]]

Associate with a project.

None
job_type Optional[str]

"sprint", "kanban", or "backlog".

None
start_date Optional[str]

Sprint start date (ISO 8601, e.g. "2026-01-01").

None
end_date Optional[str]

Sprint end date (ISO 8601).

None

Returns:

Type Description
Job

The newly created :class:~pyawe.models.Job.

Raises:

Type Description
AweAuthError

If not authenticated.

AweValidationError

On a 400 response.

get

get(job_id: Union[UUID, str]) -> JobWithWorkflows

Fetch a job with its associated workflows.

Parameters:

Name Type Description Default
job_id Union[UUID, str]

UUID of the job.

required

Returns:

Type Description
JobWithWorkflows

class:~pyawe.models.JobWithWorkflows.

Raises:

Type Description
AweNotFoundError

If the job does not exist.

AweAuthError

If not authenticated.

update

update(job_id: Union[UUID, str], *, name: Optional[str] = None, status: Optional[Union[Status, str]] = None, schedule_status: Optional[Union[ScheduleStatus, str]] = None, archived: Optional[bool] = None, project_id: Optional[Union[UUID, str]] = None, job_type: Optional[str] = None, start_date: Optional[str] = None, end_date: Optional[str] = None) -> Job

Update a job; only supplied fields are changed.

Parameters:

Name Type Description Default
job_id Union[UUID, str]

UUID of the job to update.

required
name Optional[str]

New name.

None
status Optional[Union[Status, str]]

New status.

None
schedule_status Optional[Union[ScheduleStatus, str]]

New schedule status.

None
archived Optional[bool]

Archive flag.

None
project_id Optional[Union[UUID, str]]

Reassign to a different project.

None
job_type Optional[str]

"sprint", "kanban", or "backlog".

None
start_date Optional[str]

Sprint start date (ISO 8601).

None
end_date Optional[str]

Sprint end date (ISO 8601).

None

Returns:

Type Description
Job

The updated :class:~pyawe.models.Job.

Raises:

Type Description
AweNotFoundError

If the job does not exist.

AweAuthError

If not authenticated.

delete

delete(job_id: Union[UUID, str]) -> None

Delete a job.

Parameters:

Name Type Description Default
job_id Union[UUID, str]

UUID of the job to delete.

required

Raises:

Type Description
AweNotFoundError

If the job does not exist.

AweAuthError

If not authenticated.

clone_workflow

clone_workflow(job_id: Union[UUID, str], workflow_id: Union[UUID, str]) -> WorkflowWithTasks

Clone a workflow template into a job.

Parameters:

Name Type Description Default
job_id Union[UUID, str]

UUID of the target job.

required
workflow_id Union[UUID, str]

UUID of the workflow template to clone.

required

Returns:

Type Description
WorkflowWithTasks

The new :class:~pyawe.models.WorkflowWithTasks inside the job.

Raises:

Type Description
AweNotFoundError

If the job or workflow does not exist.

AweAuthError

If not authenticated.

set_team

set_team(job_id: Union[UUID, str], team_id: Union[UUID, str]) -> Job

Assign a job to a team.

Parameters:

Name Type Description Default
job_id Union[UUID, str]

UUID of the job.

required
team_id Union[UUID, str]

UUID of the team.

required

Returns:

Type Description
Job

The updated :class:~pyawe.models.Job.

Raises:

Type Description
AweNotFoundError

If the job does not exist.

AweAuthError

If not authenticated.

clear_team

clear_team(job_id: Union[UUID, str]) -> Job

Remove the team assignment from a job.

Parameters:

Name Type Description Default
job_id Union[UUID, str]

UUID of the job.

required

Returns:

Type Description
Job

The updated :class:~pyawe.models.Job.

Raises:

Type Description
AweNotFoundError

If the job does not exist.

AweAuthError

If not authenticated.