Agent Connectivity
- class AgentConnectivity(api)
Bases:
_ClientWorkBase
- create(name, server_url='', proxy_url='', proxy_credentials=None, log_threshold='Info', attributes=None, get_if_already_exists=True)
- Parameters
name (str) – The name of the client work.
server_url (str) – The server url.
proxy_url (str) – The proxy url.
proxy_credentials (Union[config.Object, str]) – Config Object or Distinguished Name (DN) of the proxy credentials.
log_threshold (str) – The log threshold.
attributes (dict) – Additional attributes to apply to the object.
get_if_already_exists (bool) – If the objects already exists, just return it as is.
- Returns
Config Object of the client work.
- delete(work)
Deletes the client work.
- Parameters
work (Union[config.Object, str]) – Config Object or name of the client work.
- disable(work)
Disables the client work.
- Parameters
work (Union[config.Object, str]) – Config Object or name of the client work.
- enable(work)
Enables the client work.
- Parameters
work (Union[config.Object, str]) – Config Object or name of the client work.
- get(name, raise_error_if_not_exists=True)
- Parameters
name (str) – The name of the client work.
raise_error_if_not_exists (bool) – Raise an exception if the client work does not exist.
- Returns
Config Object of the client work.
- list()
Lists all client work.
- Returns
List of Config Object of all client work.
- schedule(work, start_time=None, daily=False, hourly=False, days_of_week=None, days_of_month=None, randomize_minutes=0)
Note
Only one of daily, hourly, days_of_week or days_of_month can be set.
Schedules the Agent Connectivity work to run.
- Parameters
work (Union[config.Object, str]) – Config Object or name of the client work.
start_time (int) – The 24-hour UTC hour format (i.e. 20 = 8PM UTC) for the job to start.
daily (bool) – Runs the client work daily
hourly (bool) – Runs the client work hourly
days_of_week (List[str]) – Runs the client work on specific days of the week. It is a Zero-based index of the days of the week (i.e. Sunday = ‘0’).
days_of_month (List[str]) – Runs the client work on specific days of the month.
randomize_minutes (int) – Randomize the given minutes for agent check-in to the server
- unschedule(work)
Removes any scheduling for the client work, but does not delete the client work.
- Parameters
work (Union[config.Object, str]) – Config Object or name of the client work.