orchestrator package

Submodules

orchestrator.exceptions module

exception orchestrator.exceptions.OrchestratorAuthException(value, message)[source]

Bases: Exception

exception orchestrator.exceptions.OrchestratorFormatException(value, message)[source]

Bases: Exception

exception orchestrator.exceptions.OrchestratorMissingParam(value, message)[source]

Bases: Exception

orchestrator.orchestrator module

class orchestrator.orchestrator.Orchestrator(client_id=None, refresh_token=None, tenant_name=None, folder_id=None, session=None, file=None)[source]

Bases: orchestrator.orchestrator_http.OrchestratorHTTP

Constructor.

@client_id: the client id @refresh_token: a refresh token @tenant_name: account’s logical name @folder_id: a folder id (optional) @session: a session object (options) @file: a credentials file containing client_id, refresh_token and tenant_name (optional)

get_folder_by_id(folder_id)[source]

Returns a single folder by its id

@returns: a Folder object with the specified folder id

get_folder_by_name(folder_name)[source]

Returns a single folder by its name

@returns: a Folder object with the specified folder_name

get_folder_ids(options=None)[source]

Returns a dictionary with the folder ids

@returns: a dictionary where the keys are the ids and the values the names of the folders in the given organization

get_folders(options=None)[source]

Gets all the folders from a given organization

@returns: a list of Folders of the given organization

get_libraries(options=None)[source]

Gets all the libraries of a given organization

@returns: a list of Libraries of the given organization

get_machine_by_id(machine_id)[source]

Returns a single machine by its id

@machine_id: the id of the machine

get_machine_ids(options=None)[source]

Returns a dictionary of the machine keys and their names

@options: dictionary of odata filtering options

get_machines(options=None)[source]

Gets all the machines of a given organization

get_process_by_key(process_key)[source]

Returns a single process by is key

@returns: a Process object with the specified process key

get_processes(options=None)[source]

Gets all the processes of a given organization

@returns: a list of Processes of the given organization

get_processes_keys(options=None)[source]

Returns a dictionary with the processes keys

@returns: a dictionary where the keys are the process’ key and the values the process’ title of the processes in the given organization

permissions(options=None)[source]
usernames(options=None)[source]

No se por que no va

orchestrator.orchestrator_asset module

class orchestrator.orchestrator_asset.Asset(client_id, refresh_token, tenant_name, folder_id=None, folder_name=None, session=None, asset_id=None, asset_name=None, access_token=None)[source]

Bases: orchestrator.orchestrator_http.OrchestratorHTTP

Container class for asset entities in Orchestrator Cloud.

:param client_id - the client id of your cloud organization unit. :type client_id - str

:param refresh_token - a refresh token. :type refresh_token - str

:param tenant_name - your account’s logical name :type tenant_name - str

:param folder_id - the id of the folder (UiPath’s organizations unit) :type folder_id - str

:param folder_name - the name of the folder :type folder_name : str

:param session - a session object to deal with the requests :type session - Session

:param asset_id - the id of the asset :type asset_id - int

:param asset_name - the name of the asset :type asset_id - str

delete(body=None)[source]
edit(body=None)[source]

Edits an asset

:param body - the body of the request with the attributes changed :type body - dict

info()[source]

Gives back information about the current asset.

orchestrator.orchestrator_folder module

class orchestrator.orchestrator_folder.Folder(client_id, refresh_token, tenant_name, session=None, folder_name=None, folder_id=None, access_token=None)[source]

Bases: orchestrator.orchestrator_http.OrchestratorHTTP

Constructor

:param client_id - the client id of your organization :type client_id - str

:param refresh_token - a refresh token. :type refresh_token - str

:param tenant_name - your account’s logical name :type tenant_name - str

:param session - an optional session object :type session - Session

:param folder_id - the id of the folder (UiPath’s organizations unit) :type folder_id - str

:param folder_name - the name of the folder :type folder_name : str

create_asset(body=None)[source]
get_asset_by_id(asset_id)[source]
get_asset_ids(options=None)[source]

Returns a dictionary of ky value pairs where keys are the assets names and the values are the ids

:param options - dictionary of odata filter options

get_assets(options=None)[source]

Returns list of assets :options dict of odata filter options

get_job_by_key(key)[source]
get_job_keys(top='100', options=None)[source]
get_jobs(top='100', options=None)[source]

Returns the jobs of a given folder

@top : maximum number of results (100 default) @options: dictionary of odata filtering options

get_machine_runtime_sessions()[source]

No se por que no va

get_process_schedules(options=None)[source]
get_processing_records(options=None)[source]

Returns a list of queue processing records for all the queues

:param options - dictionary for odata options :type options - dict

get_queue_by_id(queue_id)[source]
get_queue_ids(options=None)[source]

Returns a list of dictionaries containing the queue name and the queue id

:options dictionary for odata options

get_queues(options=None)[source]

Parameters: :param options - dictionary of filtering odata options :type options - dict

get_schedule_ids(options=None)[source]
Returns a list of dictionaries

name – schedule_id

get_sessions(options=None)[source]

Gets all the sessions for the current folder

info()[source]

Returns a information of a single folder based on its folder id

job_triggers(options=None)[source]

orchestrator.orchestrator_http module

class orchestrator.orchestrator_http.OrchestratorHTTP(client_id=None, refresh_token=None, tenant_name=None, folder_id=None, session=None, file=None)[source]

Bases: object

access_token = None
account_url = 'https://account.uipath.com'
cloud_url = 'https://cloud.uipath.com'
static generate_reference()[source]
oauth_endpoint = '/oauth/token'

orchestrator.orchestrator_job module

class orchestrator.orchestrator_job.Job(client_id, refresh_token, tenant_name, folder_id=None, folder_name=None, session=None, job_id=None, job_key=None, job_name=None, access_token=None)[source]

Bases: orchestrator.orchestrator_http.OrchestratorHTTP

get_logs(trace='Info')[source]
info()[source]
kill()[source]

Kill the given job

restart()[source]

Restarts the given job

resume()[source]

Restarts the given job

stop()[source]

Stops the given job

orchestrator.orchestrator_library module

class orchestrator.orchestrator_library.Library(client_id, refresh_token, tenant_name, session=None, lib_key=None, lib_id=None, lib_title=None, folder_id=None, access_token=None)[source]

Bases: orchestrator.orchestrator_http.OrchestratorHTTP

orchestrator.orchestrator_logs module

class orchestrator.orchestrator_logs.Log(client_id, refresh_token, tenant_name, folder_id=None, folder_name=None, session=None, msg=None, trace=None, key=None, stamp=None)[source]

Bases: orchestrator.orchestrator_http.OrchestratorHTTP

create(level='Info', message=None)[source]

orchestrator.orchestrator_machine module

class orchestrator.orchestrator_machine.Machine(client_id, refresh_token, tenant_name, folder_id=None, session=None, machine_id=None, machine_key=None, machine_name=None, access_token=None)[source]

Bases: orchestrator.orchestrator_http.OrchestratorHTTP

Constructor.

@client_id: the client id @refresh_token: a refresh token @tenant_name: account’s logical name @folder_id: the folder id @folder_name: the folder name @session: a session object (options) @queue_name: the queue name @queue_id: the queue id

info()[source]

orchestrator.orchestrator_process module

class orchestrator.orchestrator_process.Process(client_id, refresh_token, tenant_name, folder_id=None, session=None, process_id=None, process_title=None, process_version=None, process_key=None, access_token=None)[source]

Bases: orchestrator.orchestrator_http.OrchestratorHTTP

get_available_versions()[source]

Gets all the available versions for a given process

info()[source]
parameters()[source]
versions()[source]

orchestrator.orchestrator_process_schedule module

class orchestrator.orchestrator_process_schedule.ProcessSchedule(client_id, refresh_token, tenant_name, folder_id=None, session=None, process_id=None, process_name=None, access_token=None)[source]

Bases: orchestrator.orchestrator_http.OrchestratorHTTP

delete()[source]

Deletes a schedule

enable(enable: bool = False, schedule_ids=[])[source]
info()[source]
schedule()[source]

orchestrator.orchestrator_queue module

class orchestrator.orchestrator_queue.Queue(client_id, refresh_token, tenant_name, folder_id=None, folder_name=None, session=None, queue_name=None, queue_id=None, access_token=None)[source]

Bases: orchestrator.orchestrator_http.OrchestratorHTTP

add_queue_item(specific_content=None, priority='Low')[source]

Creates a new Item

@specific_content: dictionary of key value pairs (it does not admit nested dictionaries; for it to work json.dumps first)

@priority - sets up the priority (Low by default)

bulk_create_items(specific_contents=None, priority='Low', progress='New', reference=None)[source]

Adds a list of items for a given queue @param specific_content: dictionary of key value pairs. It does not admit nested dictionaries. If you want to be able to pass a dictionary as a key value pair inside the specific content attribute, you need to

json.dumps(dict)

first for it to work. @priority: sets up the priority (default: Low) @progress: sets up the progress bar (default: New) @reference: indicates a specific field of the specific content to be used as a queue reference.

Specific Content includes by default the following columns:
  • BatchID: representing a unique ID for the specific batch of items to be uploaded

  • ReferenceID: a unique ID of the item

  • ItemID: if reference is set to true, ads a new field with the reference

check_duplicate(reference)[source]

Given a queue reference, it checks whether a given queue has already appeared in the queue once.

Parameters

reference (- param) – the reference or part of it of the new queue item

Returns

If a reference is found in the queue with the given status, it returns the first item whose reference matches the one indicated as an argument. Otherwise it returns False.

classes = ['Comments', 'Status', 'Reference', 'SpecificContent']

Constructor.

@client_id: the client id @refresh_token: a refresh token @tenant_name: account’s logical name @folder_id: the folder id @folder_name: the folder name @session: a session object (options) @queue_name: the queue name @queue_id: the queue id

delete_queue()[source]

Deletes the queue

edit_queue(name=None, description=None)[source]

Edits the queue with a new name and a new descriptions

@name: the new name of the queue @description: the new description of the queue

get_item_by_id(item_id)[source]

Gets a single Item by item id

@returns: an Item object with the specified item id

get_processing_records(num_days=1, options=None)[source]

Returns a list of processing records for a given queue and a certain number of days (by default, hourly reports from the last day)

@num_days: the number of days before today from which to get the processing records (default: 1) @options: dictionary of odata filtering options

get_queue_item_comments(q=None)[source]
get_queue_items(options=None)[source]

Returns a list of queue items of the given queue

@returns: a list of QueueItem objects of the given queue (Maximum number of results: 1000)

get_queue_items_by_status(status)[source]

Returns a list of QueueItems with the status as indicated in the argument.

get_queue_items_ids(options=None)[source]

Returns a list of dictionaries with the queue item ids

@returns: a dictionary where the keys are the queue item ids of the given queue and the values the queue name

info()[source]

Returns information about the queue

@returns: dictionary with more in depth information about the queue

start(machine_identifier, specific_content=None, reference=None, fields=None)[source]

Starts a given transaction

@machine_identifier: the machine’s unique identifier @specific_content: the specific content of the transaction @reference: a reference from the specific content @fields: a dictionary of additional fields to be added to the specific content

orchestrator.orchestrator_queue_item module

class orchestrator.orchestrator_queue_item.QueueItem(client_id, refresh_token, tenant_name, folder_id=None, folder_name=None, queue_name=None, queue_id=None, session=None, item_id=None, content=None, reference=None, access_token=None)[source]

Bases: orchestrator.orchestrator_http.OrchestratorHTTP

content()[source]
delete()[source]

Deletes the given queue item

edit(body=None)[source]

edits the given queue item

events()[source]

Gets queue item events associated to the current queue item

No funciona no se por que

history()[source]

Returns the history of the given queue item

info()[source]

Gets a single item by item id

Parameters:

:param item_id : item id

Necesito una clase Item

last_entry()[source]

Returns the last entry of the given queue item

make_comment(text=None)[source]
set_transaction_progress(status=None)[source]

Updates the progress field of a given queue item (note: it must be already In Progress)

set_transaction_status(success: bool, reason=None, details=None, exception_type=None, fail_reason=None)[source]

Module contents