Jobs
JobsService ¶
Service for managing API payloads and job inbox interactions.
A job represents a single execution of an automation - it is created when you start a process and contains information about that specific run, including its status, start time, and any input/output data.
link_attachment ¶
Link an attachment to a job.
This method links an existing attachment to a specific job.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
attachment_key
|
UUID
|
The key of the attachment to link. |
required |
job_key
|
UUID
|
The key of the job to link the attachment to. |
required |
category
|
Optional[str]
|
Optional category for the attachment in the context of this job. |
None
|
folder_key
|
Optional[str]
|
The key of the folder. Override the default one set in the SDK config. |
None
|
folder_path
|
Optional[str]
|
The path of the folder. Override the default one set in the SDK config. |
None
|
Raises:
Type | Description |
---|---|
Exception
|
If the link operation fails. |
Examples:
link_attachment_async
async
¶
link_attachment_async(
*,
attachment_key,
job_key,
category=None,
folder_key=None,
folder_path=None,
)
Link an attachment to a job asynchronously.
This method asynchronously links an existing attachment to a specific job.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
attachment_key
|
UUID
|
The key of the attachment to link. |
required |
job_key
|
UUID
|
The key of the job to link the attachment to. |
required |
category
|
Optional[str]
|
Optional category for the attachment in the context of this job. |
None
|
folder_key
|
Optional[str]
|
The key of the folder. Override the default one set in the SDK config. |
None
|
folder_path
|
Optional[str]
|
The path of the folder. Override the default one set in the SDK config. |
None
|
Raises:
Type | Description |
---|---|
Exception
|
If the link operation fails. |
Examples:
import asyncio
from uipath import UiPath
client = UiPath()
async def main():
await client.jobs.link_attachment_async(
attachment_key=uuid.UUID("123e4567-e89b-12d3-a456-426614174000"),
job_key=uuid.UUID("123e4567-e89b-12d3-a456-426614174001"),
category="Result"
)
print("Attachment linked to job successfully")
list_attachments ¶
List attachments associated with a specific job.
This method retrieves all attachments linked to a job by its key.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
job_key
|
UUID
|
The key of the job to retrieve attachments for. |
required |
folder_key
|
Optional[str]
|
The key of the folder. Override the default one set in the SDK config. |
None
|
folder_path
|
Optional[str]
|
The path of the folder. Override the default one set in the SDK config. |
None
|
Returns:
Type | Description |
---|---|
List[Attachment]
|
List[Attachment]: A list of attachment objects associated with the job. |
Raises:
Type | Description |
---|---|
Exception
|
If the retrieval fails. |
Examples:
list_attachments_async
async
¶
List attachments associated with a specific job asynchronously.
This method asynchronously retrieves all attachments linked to a job by its key.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
job_key
|
UUID
|
The key of the job to retrieve attachments for. |
required |
folder_key
|
Optional[str]
|
The key of the folder. Override the default one set in the SDK config. |
None
|
folder_path
|
Optional[str]
|
The path of the folder. Override the default one set in the SDK config. |
None
|
Returns:
Type | Description |
---|---|
List[Attachment]
|
List[Attachment]: A list of attachment objects associated with the job. |
Raises:
Type | Description |
---|---|
Exception
|
If the retrieval fails. |
Examples:
resume ¶
Sends a payload to resume a paused job waiting for input, identified by its inbox ID.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
inbox_id
|
Optional[str]
|
The inbox ID of the job. |
None
|
job_id
|
Optional[str]
|
The job ID of the job. |
None
|
folder_key
|
Optional[str]
|
The key of the folder to execute the process in. Override the default one set in the SDK config. |
None
|
folder_path
|
Optional[str]
|
The path of the folder to execute the process in. Override the default one set in the SDK config. |
None
|
payload
|
Any
|
The payload to deliver. |
required |
resume_async
async
¶
Asynchronously sends a payload to resume a paused job waiting for input, identified by its inbox ID.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
inbox_id
|
Optional[str]
|
The inbox ID of the job. If not provided, the execution context will be used to retrieve the inbox ID. |
None
|
job_id
|
Optional[str]
|
The job ID of the job. |
None
|
folder_key
|
Optional[str]
|
The key of the folder to execute the process in. Override the default one set in the SDK config. |
None
|
folder_path
|
Optional[str]
|
The path of the folder to execute the process in. Override the default one set in the SDK config. |
None
|
payload
|
Any
|
The payload to deliver. |
required |
Examples: