forked from openmsa/python-sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmsa_sdk.json
More file actions
1 lines (1 loc) · 58.1 KB
/
msa_sdk.json
File metadata and controls
1 lines (1 loc) · 58.1 KB
1
{"Device": {"methods": [{"__init__": {"description": "Initialize.\n\nParameters\n----------\ncustomer_id: String\n Customer id\nname: String\n Name of the device\nmanufacturer_id: String\n Manufacture ID\nmodel_id: String\n Model ID\nlogin: String\n Login\npassword: String\n Password\npassword_admin: String\n Password Admin\nmanagement_address: Management Address\ndevice_external: Device External\nlog_enabled: Bool\n Log Enabled\nlog_more_enabled: More logs\nmail_alerting: Bool\n Mail alerting\nreporting: Bool\n Reporting\nsnmp_community: SNMP Community\ndevice_id: String\n Device ID\nmanagement_port: Integer\n Management Port\nfail: Bool\n Fail creating the device\n\n\nReturns\n-------\nNone", "parameters": "(customer_id=None, name=None, manufacturer_id=None, model_id=None, login=None, password=None, password_admin=None, management_address=None, device_external=None, log_enabled=True, log_more_enabled=True, mail_alerting=True, reporting=False, snmp_community='ubiqube', device_id=None, management_port=None)"}}, {"activate": {"description": "Activate device.\n\nReturns\n--------\nNone", "parameters": "()"}}, {"attach_files": {"description": "Attach files.\n\nParameters\n----------\nuris:\nposition: String\n default: AUTO\n\nReturns\n--------\nNone", "parameters": "(uris, position='AUTO')"}}, {"check_response": {"description": "Check reponse of a POST/GET/PUT/DELETE.\n\nReturns\n--------\nNone", "parameters": "()"}}, {"create": {"description": "Create device.\n\nReturns\n-------\nDict() with created device capabilities", "parameters": "()"}}, {"create_configuration_variable": {"description": "Create configuration variable.\n\nParameters\n----------\nname: String\n Variable name\nvalue: String\n Vriable Value\nconf_type: String\n Variable type\n Default: String\ncomment: String\n Comment\n Default: empty stirng\n\nReturns\n-------\nTrue: Variable has been created successdully\nFalse: Variable has not been created successfully", "parameters": "(name:str, value:str, conf_type:str='String', comment:str='') -> bool"}}, {"delete": {"description": "Delete device.\n\nParameters\n----------\nby_ref: String\n Path /id/ or /reference/\n\nReturns\n-------\nNone", "parameters": "(by_ref=False)"}}, {"detach_files": {"description": "Attach files.\n\nParameters\n----------\nuris: String\n\nReturns\n--------\nNone", "parameters": "(uris)"}}, {"execute_command_on_device": {"description": "MSA SDK method to 'Do execute command by managed entity id'.\n\nExcecute the given command on the device\nRun (*GET /device/v1/command/execute/{deviceId}?command=<command>).\n\nParameters\n----------\ncommand: String\n\nReturns\n-------\nThe result of the command.", "parameters": "(command:str) -> bool"}}, {"get_all_configuration_variables": {"description": "Get all configuration variables value.\n\nParameters\n----------\nNone\n\nReturns\n-------\nString: Dict() like { 'name': 'location_id', 'value': '101', 'comment': 'test'}", "parameters": "() -> dict"}}, {"get_all_manufacturers": {"description": "Get all sorted list of manufacturers with manufacturer Id and name and models with model Id and names.\n\nParameters\n----------\nNone\n\nReturns\n-------\nString: Dict() like { }", "parameters": "() -> dict"}}, {"get_configuration_status": {"description": "Get configuration status and add to device configuration.\n\nReturns\n--------\nNone", "parameters": "()"}}, {"get_configuration_variable": {"description": "Get configuration variable value.\n\nParameters\n----------\nname: String\n Variable name\n\nReturns\n-------\nString: Dict() like {'name': str(), 'value': str(), 'comment': str()}", "parameters": "(name:str) -> dict"}}, {"get_customer_id": {"description": "Get customer id /device/v1/customer/deviceId.\n\nParameters\n----------\nNone\n\nReturns\n-------\nString: Dict() like { }", "parameters": "() -> dict"}}, {"get_update_firmware_status": {"description": "Get firmware update status by managed entity id (/device/v1/getFirmwareUpdateStatusByDeviceId/{deviceId}).\n\nParameters\n----------\ncommand: String\n\nReturns\n-------\nThe result of the command.", "parameters": "()"}}, {"initial_provisioning": {"description": "Initialize provisioning.\n\nReturns\n--------\nNone", "parameters": "()"}}, {"is_device": {"description": "Check if is device.\n\nReturns\n--------\nDict() with True or False", "parameters": "()"}}, {"log_to_process_file": {"description": "Write log string with ISO timestamp to process log file.\n\nParameters\n----------\nprocess_id: String\n Process ID of current process\nlog_message: String\n Log text\n\nReturns\n-------\nTrue: log string has been written correctlly\nFalse: log string has not been written correctlly or the log\n file doesnt exist", "parameters": "(processId:str, log_message:str) -> bool"}}, {"ping": {"description": "Ping address.\n\nParameters\n----------\naddress: String\n Ip address.\n\nReturns\n--------\nPing response", "parameters": "(address)"}}, {"process_content": {"description": "Process content.\n\nParameters\n----------\nstatus: String\n Status ID: 'ENDED', 'FAIL', 'RUNNING', 'WARNING', 'PAUSE'\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nResponse content formated", "parameters": "(status, comment, new_params, log_response=False)"}}, {"profile_attach": {"description": "Attach new profile to device.\n\nParameters\n----------\nprofile_reference: String\n Profile external reference\n\nReturns\n--------\nNone", "parameters": "(profile_reference:str) -> None"}}, {"profile_detach": {"description": "Detaches device to a profile by profile reference to device (/profile/{profileReference}/detach).\n\nParameters\n----------\nprofile_reference: String\n Profile external reference like 'sdsPR55'\n\nReturns\n--------\nNone", "parameters": "(profile_reference:str) -> None"}}, {"profile_switch": {"description": "Profile Switch.\n\nParameters\n----------\nold_profile: String\n Old profile name\nnew_profile_ref: String\n New profile name\n\nReturns\n--------\nNone", "parameters": "(old_profile, new_profile_ref)"}}, {"provision": {"description": "Provision a device.\n\nReturns\n--------\nNone", "parameters": "()"}}, {"provision_status": {"description": "Get the provision status.\n\nReturns\n--------\nDict() with provision status", "parameters": "()"}}, {"push_configuration": {"description": "Push configuration.\n\nParameters\n----------\nconfiguration: String\n Configuration parameters for the device\n\nReturns\n--------\nNone", "parameters": "(configuration=None)"}}, {"push_configuration_status": {"description": "Push configuration status.\n\nReturns\n--------\nJson with configuration", "parameters": "()"}}, {"read": {"description": "Read device information.\n\nParameters\n----------\nby_ref: String\n Path /id/ or /reference/\n\nReturns\n--------\nJson formated string", "parameters": "(by_ref=False)"}}, {"run_jsa_command_device": {"description": "MSA SDK method to Sends jsa command to a device POST /sms/cmd/<command>/<id>. It will run the script /opt/sms/php/smsd/do_cmd_<command>.php or /opt/devops/OpenMSA_Adapters/adapters/<device_type)/do_cmd_<command>.php on the MSA.\n\nParameters\n----------\ncommand: String\n the Jsa command like 'get_files'\nparams : Json params if needed like {src_dir:'/tmp/',file_pattern='testfile.txt',dest_dir='/tmp'}\n\nReturns\n-------\nThe result of the command.", "parameters": "(command:str, params:{}) -> bool"}}, {"status": {"description": "Get device status.\n\nReturns\n--------\nOne word string", "parameters": "()"}}, {"task_error": {"description": "Task error and print.\n\nParameters\n----------\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nNone", "parameters": "(comment, context, log_response=True)"}}, {"task_success": {"description": "Task success and print.\n\nParameters\n----------\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nNone", "parameters": "(comment, context, log_response=True)"}}, {"update": {"description": "Update device.\n\nfield: String\n Modifyed device field\nvalue: String\n Modified field's value (str)\n\n\nReturns\n-------\nUpdated device capabilities: Dict()", "parameters": "(field:str, value:str) -> dict"}}, {"update_config": {"description": "Update config.\n\nReturns\n--------\nConfig in JSON form", "parameters": "()"}}, {"update_credentials": {"description": "Update Credentials.\n\nParameters\n----------\nlogin: String\n Credentials Login\npassword: String\n Credentials password\n\nReturns\n--------\nNone", "parameters": "(login, password)"}}, {"update_firmware": {"description": "MSA SDK method Update firmware (/device/v1/doFirmwareUpdateByDeviceId).\n\nUpdate Firmware of a managed entity.\nThe process is: The version is checked (not upgrade is done is the same version is installed) The firmware file is transfered to the managed entity flash The transfered file is verified The configuration is modified to boot using the new firmware The managed entity is rebooted If the managed entity successfully rebooted using the new firmware, the old firmware file is removed from flash Concerned files are the files uploaded in the Repository:/Firmware and attached to the device.\nParameters\n----------\nparams: String like, \"FILE=Datafiles/SYZ/SYZA11/csr1000v-universalk9.16.06.07.SPA.bin,file_server_addr=12.2.2.65\" \n\nReturns\n--------\nNone", "parameters": "(params:str) -> bool"}}, {"update_ip_address": {"description": "Update Ip Address.\n\nParameters\n----------\nip_addr: String\n IP Address format (xxx.xxx.xxx.xxx)\nnetmask: String\n Netmask, default 255.255.255.2555\n\nReturns\n--------\nNone", "parameters": "(ip_addr, netmask='255.255.255.255')"}}]}, "Lookup": {"methods": [{"__init__": {"description": "Initialize.", "parameters": "()"}}, {"check_response": {"description": "Check reponse of a POST/GET/PUT/DELETE.\n\nReturns\n--------\nNone", "parameters": "()"}}, {"log_to_process_file": {"description": "Write log string with ISO timestamp to process log file.\n\nParameters\n----------\nprocess_id: String\n Process ID of current process\nlog_message: String\n Log text\n\nReturns\n-------\nTrue: log string has been written correctlly\nFalse: log string has not been written correctlly or the log\n file doesnt exist", "parameters": "(processId:str, log_message:str) -> bool"}}, {"look_list_customer_by_operator_prefix": {"description": "List customer by operator prefix : /lookup/v1/customer-by-operator-prefix/{prefix}.\n\nParameters\n----------\nprefix String\n perator prefix (3 Letters Acronym) that uniquely identifies an operator like TLA, ARA, OPT\n\nReturns\n-------\narray like [ { \"actorId\" : 91,\"externalReference\" : \"opeA14\", \"firstname\" : \"\",\"id\" : 14,\"login\" : \"test14\",\"name\" : \"test\", \"operatorPrefix\" : \"ope\" }, {", "parameters": "(prefix)"}}, {"look_list_customer_ids": {"description": "Look list customer ids.\n\nReturns\n-------\nNone", "parameters": "()"}}, {"look_list_device_by_customer_ref": {"description": "Look list device by customer reference.\n\nParameters\n----------\nmanager_id: Integer\n Manager id\n\nReturns\n-------\nNone", "parameters": "(custom_ref)"}}, {"look_list_device_ids": {"description": "Look list devices ids.\n\nReturns\n-------\nNone", "parameters": "()"}}, {"look_list_manager_ids": {"description": "Look list manager ids.\n\nReturns\n-------\nNone", "parameters": "()"}}, {"look_list_operators_id": {"description": "Look list operators id.\n\nParameters\n----------\nmanager_id: Integer\n Manager id\n\nReturns\n-------\nNone", "parameters": "(manager_id)"}}, {"look_list_sec_nodes": {"description": "Look list sec nodes.\n\nReturns\n-------\nNone", "parameters": "()"}}, {"process_content": {"description": "Process content.\n\nParameters\n----------\nstatus: String\n Status ID: 'ENDED', 'FAIL', 'RUNNING', 'WARNING', 'PAUSE'\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nResponse content formated", "parameters": "(status, comment, new_params, log_response=False)"}}, {"task_error": {"description": "Task error and print.\n\nParameters\n----------\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nNone", "parameters": "(comment, context, log_response=True)"}}, {"task_success": {"description": "Task success and print.\n\nParameters\n----------\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nNone", "parameters": "(comment, context, log_response=True)"}}]}, "Order": {"methods": [{"__init__": {"description": "Initialize.", "parameters": "(device_id)"}}, {"activate": {"description": "Activate device.\n\nReturns\n--------\nNone", "parameters": "()"}}, {"attach_files": {"description": "Attach files.\n\nParameters\n----------\nuris:\nposition: String\n default: AUTO\n\nReturns\n--------\nNone", "parameters": "(uris, position='AUTO')"}}, {"check_response": {"description": "Check reponse of a POST/GET/PUT/DELETE.\n\nReturns\n--------\nNone", "parameters": "()"}}, {"command_call": {"description": "Command call.\n\nParameters\n-----------\ncommand: String\n CRUID method in microservice to call\nmode: Integer\n 0 - No application\n 1 - Apply to base\n 2 - Apply to device\nReturns\n--------\nNone", "parameters": "(command:str, mode:int, params, timeout=300) -> None"}}, {"command_execute": {"description": "Command execute.\n\nParameters\n-----------\ncommand: String\n Order command\n Available values : CREATE, UPDATE, IMPORT, LIST, READ, DELETE\n\nparams: dict\n Parameters in a dict format:\n\n {\n \"simple_firewall\": {\n \"12\": {\n \"object_id\": \"12\",\n \"src_ip\": \"3.4.5.6\",\n \"dst_port\": \"44\"\n }\n }\n timeout: int timeout in sec (300 secondes by default)\n\nReturns\n-------\nNone", "parameters": "(command:str, params:dict, timeout=300) -> None"}}, {"command_generate_configuration": {"description": "Command generate configuration.\n\nParameters\n-----------\ncommand: String\n Order command\n\nparams: dict\n Parameters\n\n\nReturns\n-------\nNone", "parameters": "(command:str, params:dict) -> None"}}, {"command_get_deployment_settings_id": {"description": "Get deployment settings ID for the device.\n\nReturns\n--------\nInteger:\n Deployment settings ID", "parameters": "() -> int"}}, {"command_objects_all": {"description": "Get all microservices attached to a device.\n\nReturns\n--------\nNone", "parameters": "() -> None"}}, {"command_objects_instances": {"description": "Get microservices instance by microservice name.\n\nParameters\n-----------\nobject_name: String\n Name of microservice\nReturns\n--------\nlist of object:\n List of object IDs per microservice", "parameters": "(object_name:str) -> dict"}}, {"command_objects_instances_by_id": {"description": "Get microservices instance by microservice object ID.\n\nParameters\n-----------\nobject_name: String\n Name of microservice\nobject_id: String\n Object ID of microservice instance\nReturns\n--------\nlist of object:\n Object of microservice parameters per object ID", "parameters": "(object_name:str, object_id:str) -> dict"}}, {"command_synchronize": {"description": "Command synchronize.\n\nParameters\n-----------\ntimeout: Integer\n Connection timeout\n\n\nReturns\n-------\nNone", "parameters": "(timeout:int) -> None"}}, {"command_synchronizeOneOrMoreObjectsFromDevice": {"description": "Command synchronize objects from a Device.\n\nParameters\n-----------\nmservice_uris: List\n List of microservices\n\ntimeout: Integer\n Connection timeout\n\nReturns\n-------\nNone", "parameters": "(mservice_uris:list, timeout:int) -> None"}}, {"create": {"description": "Create device.\n\nReturns\n-------\nDict() with created device capabilities", "parameters": "()"}}, {"create_configuration_variable": {"description": "Create configuration variable.\n\nParameters\n----------\nname: String\n Variable name\nvalue: String\n Vriable Value\nconf_type: String\n Variable type\n Default: String\ncomment: String\n Comment\n Default: empty stirng\n\nReturns\n-------\nTrue: Variable has been created successdully\nFalse: Variable has not been created successfully", "parameters": "(name:str, value:str, conf_type:str='String', comment:str='') -> bool"}}, {"delete": {"description": "Delete device.\n\nParameters\n----------\nby_ref: String\n Path /id/ or /reference/\n\nReturns\n-------\nNone", "parameters": "(by_ref=False)"}}, {"detach_files": {"description": "Attach files.\n\nParameters\n----------\nuris: String\n\nReturns\n--------\nNone", "parameters": "(uris)"}}, {"execute_command_on_device": {"description": "MSA SDK method to 'Do execute command by managed entity id'.\n\nExcecute the given command on the device\nRun (*GET /device/v1/command/execute/{deviceId}?command=<command>).\n\nParameters\n----------\ncommand: String\n\nReturns\n-------\nThe result of the command.", "parameters": "(command:str) -> bool"}}, {"get_all_configuration_variables": {"description": "Get all configuration variables value.\n\nParameters\n----------\nNone\n\nReturns\n-------\nString: Dict() like { 'name': 'location_id', 'value': '101', 'comment': 'test'}", "parameters": "() -> dict"}}, {"get_all_manufacturers": {"description": "Get all sorted list of manufacturers with manufacturer Id and name and models with model Id and names.\n\nParameters\n----------\nNone\n\nReturns\n-------\nString: Dict() like { }", "parameters": "() -> dict"}}, {"get_configuration_status": {"description": "Get configuration status and add to device configuration.\n\nReturns\n--------\nNone", "parameters": "()"}}, {"get_configuration_variable": {"description": "Get configuration variable value.\n\nParameters\n----------\nname: String\n Variable name\n\nReturns\n-------\nString: Dict() like {'name': str(), 'value': str(), 'comment': str()}", "parameters": "(name:str) -> dict"}}, {"get_customer_id": {"description": "Get customer id /device/v1/customer/deviceId.\n\nParameters\n----------\nNone\n\nReturns\n-------\nString: Dict() like { }", "parameters": "() -> dict"}}, {"get_update_firmware_status": {"description": "Get firmware update status by managed entity id (/device/v1/getFirmwareUpdateStatusByDeviceId/{deviceId}).\n\nParameters\n----------\ncommand: String\n\nReturns\n-------\nThe result of the command.", "parameters": "()"}}, {"initial_provisioning": {"description": "Initialize provisioning.\n\nReturns\n--------\nNone", "parameters": "()"}}, {"is_device": {"description": "Check if is device.\n\nReturns\n--------\nDict() with True or False", "parameters": "()"}}, {"log_to_process_file": {"description": "Write log string with ISO timestamp to process log file.\n\nParameters\n----------\nprocess_id: String\n Process ID of current process\nlog_message: String\n Log text\n\nReturns\n-------\nTrue: log string has been written correctlly\nFalse: log string has not been written correctlly or the log\n file doesnt exist", "parameters": "(processId:str, log_message:str) -> bool"}}, {"ping": {"description": "Ping address.\n\nParameters\n----------\naddress: String\n Ip address.\n\nReturns\n--------\nPing response", "parameters": "(address)"}}, {"process_content": {"description": "Process content.\n\nParameters\n----------\nstatus: String\n Status ID: 'ENDED', 'FAIL', 'RUNNING', 'WARNING', 'PAUSE'\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nResponse content formated", "parameters": "(status, comment, new_params, log_response=False)"}}, {"profile_attach": {"description": "Attach new profile to device.\n\nParameters\n----------\nprofile_reference: String\n Profile external reference\n\nReturns\n--------\nNone", "parameters": "(profile_reference:str) -> None"}}, {"profile_detach": {"description": "Detaches device to a profile by profile reference to device (/profile/{profileReference}/detach).\n\nParameters\n----------\nprofile_reference: String\n Profile external reference like 'sdsPR55'\n\nReturns\n--------\nNone", "parameters": "(profile_reference:str) -> None"}}, {"profile_switch": {"description": "Profile Switch.\n\nParameters\n----------\nold_profile: String\n Old profile name\nnew_profile_ref: String\n New profile name\n\nReturns\n--------\nNone", "parameters": "(old_profile, new_profile_ref)"}}, {"provision": {"description": "Provision a device.\n\nReturns\n--------\nNone", "parameters": "()"}}, {"provision_status": {"description": "Get the provision status.\n\nReturns\n--------\nDict() with provision status", "parameters": "()"}}, {"push_configuration": {"description": "Push configuration.\n\nParameters\n----------\nconfiguration: String\n Configuration parameters for the device\n\nReturns\n--------\nNone", "parameters": "(configuration=None)"}}, {"push_configuration_status": {"description": "Push configuration status.\n\nReturns\n--------\nJson with configuration", "parameters": "()"}}, {"read": {"description": "Read device information.\n\nParameters\n----------\nby_ref: String\n Path /id/ or /reference/\n\nReturns\n--------\nJson formated string", "parameters": "(by_ref=False)"}}, {"run_jsa_command_device": {"description": "MSA SDK method to Sends jsa command to a device POST /sms/cmd/<command>/<id>. It will run the script /opt/sms/php/smsd/do_cmd_<command>.php or /opt/devops/OpenMSA_Adapters/adapters/<device_type)/do_cmd_<command>.php on the MSA.\n\nParameters\n----------\ncommand: String\n the Jsa command like 'get_files'\nparams : Json params if needed like {src_dir:'/tmp/',file_pattern='testfile.txt',dest_dir='/tmp'}\n\nReturns\n-------\nThe result of the command.", "parameters": "(command:str, params:{}) -> bool"}}, {"status": {"description": "Get device status.\n\nReturns\n--------\nOne word string", "parameters": "()"}}, {"task_error": {"description": "Task error and print.\n\nParameters\n----------\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nNone", "parameters": "(comment, context, log_response=True)"}}, {"task_success": {"description": "Task success and print.\n\nParameters\n----------\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nNone", "parameters": "(comment, context, log_response=True)"}}, {"update": {"description": "Update device.\n\nfield: String\n Modifyed device field\nvalue: String\n Modified field's value (str)\n\n\nReturns\n-------\nUpdated device capabilities: Dict()", "parameters": "(field:str, value:str) -> dict"}}, {"update_config": {"description": "Update config.\n\nReturns\n--------\nConfig in JSON form", "parameters": "()"}}, {"update_credentials": {"description": "Update Credentials.\n\nParameters\n----------\nlogin: String\n Credentials Login\npassword: String\n Credentials password\n\nReturns\n--------\nNone", "parameters": "(login, password)"}}, {"update_firmware": {"description": "MSA SDK method Update firmware (/device/v1/doFirmwareUpdateByDeviceId).\n\nUpdate Firmware of a managed entity.\nThe process is: The version is checked (not upgrade is done is the same version is installed) The firmware file is transfered to the managed entity flash The transfered file is verified The configuration is modified to boot using the new firmware The managed entity is rebooted If the managed entity successfully rebooted using the new firmware, the old firmware file is removed from flash Concerned files are the files uploaded in the Repository:/Firmware and attached to the device.\nParameters\n----------\nparams: String like, \"FILE=Datafiles/SYZ/SYZA11/csr1000v-universalk9.16.06.07.SPA.bin,file_server_addr=12.2.2.65\" \n\nReturns\n--------\nNone", "parameters": "(params:str) -> bool"}}, {"update_ip_address": {"description": "Update Ip Address.\n\nParameters\n----------\nip_addr: String\n IP Address format (xxx.xxx.xxx.xxx)\nnetmask: String\n Netmask, default 255.255.255.2555\n\nReturns\n--------\nNone", "parameters": "(ip_addr, netmask='255.255.255.255')"}}]}, "Repository": {"methods": [{"__init__": {"description": "Initialize.", "parameters": "()"}}, {"change_workflow_definition": {"description": "Change workflow defenition.\n\nParameters\n----------\n file_uri: Path to workflow file\n workflow_definition_dict: Workflow definition\nReturns\n-------\n None", "parameters": "(file_uri:str, workflow_definition_dict:dict) -> None"}}, {"check_response": {"description": "Check reponse of a POST/GET/PUT/DELETE.\n\nReturns\n--------\nNone", "parameters": "()"}}, {"create_microservice": {"description": "Create a new microservice.\n\nParameters\n----------\nmicroservice_details: json\n JSON body of microservices detail\n\nReturns\n-------\nNone", "parameters": "(microservice_details)"}}, {"create_workflow_definition": {"description": "Change workflow defenition.\n\nParameters\n----------\n workflow_definition_dict: Workflow definition\n example:\n workflow_definition = ''' {\n \"example\": {\n \"content\": \"string\"\n },\n \"metaInformationList\": [\n {\n \"type\": \"FILE\",\n \"name\": \"TEST_NEW_WF.xml\",\n \"displayName\": \"TEST_NEW_WF\",\n \"repositoryName\": \"Process\",\n \"parentURI\": \"Process/workflows/TEST_NEW_WF\",\n \"fileType\": \"text\",\n \"tag\": \"string\",\n \"comment\": \"string\",\n \"modelId\": 0,\n \"vendorId\": 0,\n \"uri\": \"Process/workflows/TEST_NEW_WF/TEST_NEW_WF.xml\",\n \"file\": \"true\"\n }\n ],\n \"information\": {\n \"displayName\": \"TEST_NEW_WF\",\n \"icon\": \"string\",\n \"description\": \"TEST_NEW_WF\",\n \"category\": \"string\",\n \"displayField\": \"string\",\n \"serviceTaskType\": \"string\",\n \"order\": 0,\n \"visibility\": \"5\"\n },\n \"process\": [\n {\n \"name\": \"Process/workflows/TEST_NEW_WF/create\",\n \"displayName\": \"instanciate\",\n \"type\": \"CREATE\",\n \"visibility\": \"5\",\n \"allowSchedule\": false,\n \"tasks\": [\n {\n \"fileName\": \"Task1.py\",\n \"fileUri\": \"/opt/fmc_repository/Process/workflows/TEST_NEW_WF/Process_instanciate/Tasks\",\n \"displayName\": \"Task1\"\n }\n ]\n }\n ]\n } \n '''\n workflow_definition_dict = json.loads(workflow_definition) #convert string into dict\n \nReturns\n-------\n None if no error, else it return the error", "parameters": "(workflow_definition_dict:dict) -> None"}}, {"delete_repository_resource": {"description": "Delete repository resource.\n\nParameters\n----------\nfile_uri: String\n File path to microservice in repository\n\nReturns\n-------\nNone", "parameters": "(file_uri)"}}, {"delete_workflow_definition": {"description": "Delete Workflow resource.\n\nParameters\n----------\n file_uri: Path to workflow file 'like Process/workflows/TEST_WF1/TEST_WF1.xml'.\nReturns\n-------\n None if no error, else it return the error", "parameters": "(file_uri:str) -> dict"}}, {"detach_microserviceis_from_configuration_profile": {"description": "Detach microservice from configuration profile.\n\nParameters\n----------\n depoloyment_settings_id: Deployment settings id\n ms_list: List of microservice's URI to detach\nReturns\n-------\n None", "parameters": "(deployment_settings_id:str, ms_list:list) -> None"}}, {"file_update_comment": {"description": "File update document.\n\nParameters\n----------\nfile_uri: String\n File path\ncomment: Comment\n File comment\n\nReturns\n-------\nNone", "parameters": "(file_uri, comment)"}}, {"get_file": {"description": "Get file content.\n\nParameters\n----------\n file_uri: String\n File path in repository\nReturns\n-------\n\n\nDictionary: dict()\n Dictionary wich contains file content", "parameters": "(file_uri)"}}, {"get_microservice_details": {"description": "Get microservice details.\n\nParameters\n----------\n file_uri: String\n File path to microservice in repository\nReturns\n-------\n\n\nDictionary: dict()\n Dictionary wich contains microservice details", "parameters": "(file_uri)"}}, {"get_microservice_path_by_name": {"description": "Get MS file path by MS name and deployment settings ID.\n\nParameters\n----------\n microservice_name: Name of microservice\n depoloyment_settings_id: Deployment settings id\n\nReturns\n-------\nString: string\n Microservice file path or None", "parameters": "(microservice_name:str, deployment_settings_id:str)"}}, {"get_microservice_variables": {"description": "Get microservice variables.\n\nParameters\n----------\n file_uri: String\n File path to microservice in repository\nReturns\n-------\n\n\nDictionary: dict()\n Dictionary wich contains microservice variables definition", "parameters": "(file_uri)"}}, {"get_microservice_variables_default_value": {"description": "Get default values for microservice variables.\n\nParameters\n----------\n file_uri: Path to microservice file.\nReturns\n-------\n Dictionary: dict()\n Variables and their default values", "parameters": "(file_uri:str) -> dict"}}, {"get_workflow_definition": {"description": "Get workflow definition.\n\nParameters\n----------\n file_uri: Path to workflow file like 'Process/workflows/TEST_WF1/TEST_WF1.xml'.\nReturns\n-------\n Dictionary: dict()\n Variables and their default values", "parameters": "(file_uri:str) -> dict"}}, {"log_to_process_file": {"description": "Write log string with ISO timestamp to process log file.\n\nParameters\n----------\nprocess_id: String\n Process ID of current process\nlog_message: String\n Log text\n\nReturns\n-------\nTrue: log string has been written correctlly\nFalse: log string has not been written correctlly or the log\n file doesnt exist", "parameters": "(processId:str, log_message:str) -> bool"}}, {"post_repository_variables": {"description": "Get repository variables.\n\nParameters\n----------\nrepository: String\n File path repository variables\n\nReturns\n-------\nNone", "parameters": "(respository_uri)"}}, {"process_content": {"description": "Process content.\n\nParameters\n----------\nstatus: String\n Status ID: 'ENDED', 'FAIL', 'RUNNING', 'WARNING', 'PAUSE'\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nResponse content formated", "parameters": "(status, comment, new_params, log_response=False)"}}, {"put_microservice_details": {"description": "Put microservice details.\n\nParameters\n----------\nfile_uri: String\n File path to microservice in repository\n\nmicroservice_details: json\n JSON body of microservices detail\n\nReturns\n-------\nNone", "parameters": "(microservice_details)"}}, {"task_error": {"description": "Task error and print.\n\nParameters\n----------\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nNone", "parameters": "(comment, context, log_response=True)"}}, {"task_success": {"description": "Task success and print.\n\nParameters\n----------\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nNone", "parameters": "(comment, context, log_response=True)"}}]}, "Customer": {"methods": [{"__init__": {"description": "Initialize.", "parameters": "()"}}, {"attach_profile_by_reference": {"description": "Attach profile to customer by external reference.\n\nParameters\n-----------\nReference: String\n Customer reference\nProfile: String\n Profile\n\nReturns\n-------\nNone", "parameters": "(reference:str, profile='') -> None"}}, {"check_response": {"description": "Check reponse of a POST/GET/PUT/DELETE.\n\nReturns\n--------\nNone", "parameters": "()"}}, {"create_customer_by_prefix": {"description": "Create customer by prefix.\n\nParameters\n-------\nprefix: String\n Unique MSA assigned customer ID\nname: String (Optional)\n Name of customer\nreference: String (Optional)\n MSA reference of customer\nReturns\n-------\nNone", "parameters": "(prefix:str, name='', reference='') -> None"}}, {"delete_customer_by_id": {"description": "Delete customer by id.\n\nParameters\n-----------\ncustomer_id: Integer\n MSA ID for customer\n\nReturns\n-------\nNone", "parameters": "(customer_id:int) -> None"}}, {"delete_customer_by_reference": {"description": "Delete customer by reference.\n\nParameters\n-----------\nReference: String\n External reference for customer\n\nReturns\n-------\nNone", "parameters": "(reference:str) -> None"}}, {"delete_variable_by_name": {"description": "Delete configuration variable info by variable name.\n\nParameters\n-----------\ncustomer_id: Integer\n Customer ID\nname: String\n Variables name\n\nReturns\n-------\nNone", "parameters": "(customer_id:int, name:str) -> None"}}, {"detach_profile_by_reference": {"description": "Detach profile to customer by external reference.\n\nParameters\n-----------\nReference: String\n Customer reference\nProfile: String\n Profile\n\nReturns\n-------\nNone", "parameters": "(reference:str, profile='') -> None"}}, {"get_customer_by_id": {"description": "Get customer by id.\n\nParameters\n-----------\ncustomer_id: Integer\n MSA ID for customer\n\nReturns\n-------\nJSON with customer information", "parameters": "(customer_id:int) -> str"}}, {"get_customer_by_reference": {"description": "Get customer by reference.\n\nParameters\n-----------\nReference: String\n External reference for customer\n\nReturns\n-------\nJSON with customer information", "parameters": "(reference:str) -> str"}}, {"get_deployment_settings_by_customer_id": {"description": "Get list of deployment settings and their attributes.\n\nParameters\n----------\ncusotmer_id: integer\n Customer ID\nReturns\n-------\n Json:\n Deployment settings list for the customer", "parameters": "(customer_id:int) -> str"}}, {"get_device_list_by_id": {"description": "Get device list for the customer.\n\nParameters\n-------\nid: Integer\n MSA ID for customer\n\nReturns\n-------\nreturn_list: list()\n List of device Id of the customer", "parameters": "(customer_id:int) -> list"}}, {"get_variables_by_id": {"description": "Get configuration variables by customer ID.\n\nParameters\n-----------\ncustomer_id: Integer\n Customer ID\n\nReturns\n-------\nJSON body of configuration variables", "parameters": "(customer_id:int) -> str"}}, {"get_variables_by_name": {"description": "Get configuration variable info by variable name.\n\nParameters\n-----------\ncustomer_id: Integer\n Customer ID\nName: String\n Variables name\n\nReturns\n-------\nJSON body of variable info", "parameters": "(customer_id:int, name:str) -> str"}}, {"log_to_process_file": {"description": "Write log string with ISO timestamp to process log file.\n\nParameters\n----------\nprocess_id: String\n Process ID of current process\nlog_message: String\n Log text\n\nReturns\n-------\nTrue: log string has been written correctlly\nFalse: log string has not been written correctlly or the log\n file doesnt exist", "parameters": "(processId:str, log_message:str) -> bool"}}, {"process_content": {"description": "Process content.\n\nParameters\n----------\nstatus: String\n Status ID: 'ENDED', 'FAIL', 'RUNNING', 'WARNING', 'PAUSE'\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nResponse content formated", "parameters": "(status, comment, new_params, log_response=False)"}}, {"task_error": {"description": "Task error and print.\n\nParameters\n----------\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nNone", "parameters": "(comment, context, log_response=True)"}}, {"task_success": {"description": "Task success and print.\n\nParameters\n----------\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nNone", "parameters": "(comment, context, log_response=True)"}}, {"update_customer_by_id": {"description": "Update customer by id.\n\nParameters\n-----------\ncustomer_id: Integer\n MSA ID for customer\n\nReturns\n-------\nJSON with customer information", "parameters": "(customer_id:int, name='') -> None"}}, {"update_variables_by_reference": {"description": "Update variables by reference.\n\nParameters\n-----------\nReference: String\n Customer reference\nName: String\n Variable name\nValue: String\n Variable value\n\nReturns\n-------\nJSON body for variables", "parameters": "(reference, name='', value='') -> None"}}]}, "ConfProfile": {"methods": [{"__init__": {"description": "Initialize.\n\nParameters\n----------\nprofile_id: Integer\n Profile id\nname: String\n Profile Name\nexternalReference: String\n Configurable id for Profile\ncomment: String\n Configurable id for Profile\nvendor_id: Integer\n Manufacture ID\nmodel_id: Integer\n Model ID\nlogin: String\n Login\nmicroserviceUris: List\n List of Microservices you want to attach\ntemplateUris: List\n List of Templates you want to attach\nattachedManagedEntities: List\n List of Managed Entities you want to attach\ncustomer_id: Integer\n Customer id which you want to attach a created\n configuration profile\n\nReturns\n-------\nNone", "parameters": "(profile_id=None, name=None, externalReference=None, comment=None, vendor_id=None, model_id=None, microserviceUris=[], templateUris=[], attachedManagedEntities=[], customer_id=None)"}}, {"check_response": {"description": "Check reponse of a POST/GET/PUT/DELETE.\n\nReturns\n--------\nNone", "parameters": "()"}}, {"create": {"description": "Create configuration profile.\n\nReturns\n-------\nNone", "parameters": "() -> None"}}, {"delete": {"description": "Delete configuration profile by id.\n\nReturns\n-------\nNone", "parameters": "() -> None"}}, {"log_to_process_file": {"description": "Write log string with ISO timestamp to process log file.\n\nParameters\n----------\nprocess_id: String\n Process ID of current process\nlog_message: String\n Log text\n\nReturns\n-------\nTrue: log string has been written correctlly\nFalse: log string has not been written correctlly or the log\n file doesnt exist", "parameters": "(processId:str, log_message:str) -> bool"}}, {"process_content": {"description": "Process content.\n\nParameters\n----------\nstatus: String\n Status ID: 'ENDED', 'FAIL', 'RUNNING', 'WARNING', 'PAUSE'\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nResponse content formated", "parameters": "(status, comment, new_params, log_response=False)"}}, {"read": {"description": "Get configuration profile by id.\n\nReturns\n-------\nJSON with configuration profile information", "parameters": "() -> str"}}, {"task_error": {"description": "Task error and print.\n\nParameters\n----------\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nNone", "parameters": "(comment, context, log_response=True)"}}, {"task_success": {"description": "Task success and print.\n\nParameters\n----------\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nNone", "parameters": "(comment, context, log_response=True)"}}, {"update": {"description": "Update configuration profile by id.\n\nReturns\n-------\nJSON with configuration profile information", "parameters": "() -> str"}}]}, "Variables": {"methods": [{"__init__": {"description": "__init__.", "parameters": "()"}}, {"add": {"description": "Add a variable.\n\nParameters\n----------\nname: String\n Name of the variable\n\nvar_type: String\n The type of the variable\n\nvalues: List\n List of values possible\n\ndef_value: String\n Default value\n\nrequired: Bool\n Determine the variable is required\n\nReturns\n-------\nNone", "parameters": "(name, var_type='String', values=None, def_value=None, required=False) -> None"}}, {"check_mandatory_param": {"description": "Check if any required var has no value.\n\nParameters\n----------\ncontext: Dict\n Context com valores\n\nReturns\n-------\nNone", "parameters": "(context) -> None"}}, {"task_call": {"description": "Will print all the variables from an object.\n\nParameters\n----------\nvar_obj: Variables\n Variables Object\n\nReturns\n-------\nJson with all the variables", "parameters": "(var_obj=None)"}}, {"vars_definition": {"description": "All variables defined.\n\nReturns\n-------\njson: all variables defined", "parameters": "() -> str"}}]}, "Orchestration": {"methods": [{"__init__": {"description": "Initialize.", "parameters": "(ubiqube_id)"}}, {"attach_wf_to_subtenant": {"description": "Attach workflows to subtenants : POST /orchestration/service/attach.\n\nParameters\n----------\nuri: String\n uri corresponds to the relative path of the XML file of the repository. The relative path starts from Process and includes the .xml at the end. Example = Process/workflows/AutoAttached/organizations.xml\nubiqubeIds: String\n ubiqubeIds corresponds to the customer ids including the prefix. Example UBIA234\n\nReturns\n-------\nNone", "parameters": "(ubiqubeIds, uri)"}}, {"check_response": {"description": "Check reponse of a POST/GET/PUT/DELETE.\n\nReturns\n--------\nNone", "parameters": "()"}}, {"delete_service": {"description": "Delete service.\n\nParameters\n----------\nservice_id: Integer\n Service ID\n\nReturns\n-------\nNone", "parameters": "(service_id)"}}, {"execute_by_service": {"description": "Execute by service.\n\nParameters\n----------\nexternal_ref: String\n External reference\nservice_ref: String\n service reference\nservice_name: String\n service name\nprocess_name: String\n Process name\ndata: Json\n data json\n\nReturns\n-------\nNone", "parameters": "(external_ref, service_ref, service_name, process_name, data)"}}, {"execute_launch_process_instance": {"description": "Execute launch process service.\n\nParameters\n----------\nservice_id: Integer\n Service ID\nprocess_name: String\n Process name\ndata: dict()\n A dictionary containing workflow variables\n\nReturns\n-------\nNone", "parameters": "(service_id, process_name, data)"}}, {"execute_service": {"description": "Execute service.\n\nParameters\n----------\nservice_name: String\n Service Name\nprocess_name: String\n Process name\ndata: dict()\n A dictionary containing workflow variables\n\nReturns\n-------\nNone\n If the execution was failed\nservice_id: Integer\n If execution was success", "parameters": "(service_name:str, process_name:str, data:dict)"}}, {"execute_service_by_reference": {"description": "Execute service (start it, don't wait the end). If the instance is already running, it will wait the end of the current before to run this instance to prevent error.\n\nParameters\n----------\nexternal_ref: String\n external reference\nservice_reference: String\n Service reference\nservice_name: String\n Service name\nprocess_name: String\n Process name\ndata: Json\n data json\n\nReturns\n-------\nNone", "parameters": "(external_ref, service_ref, service_name, process_name, data, timeout=180, interval=5)"}}, {"execute_service_process": {"description": "Execute service.\n\nParameters\n----------\nservice_name: String\n Service Name\nprocess_name: String\n Process name\ndata: dict()\n A dictionary containing workflow variables\n\nReturns\n-------\nTuple\nprocess_id: Integer\n Id if execution was success, -1 if execution fails\n\nservice_id: Integer\n Id if execution was success, -1 if execution fails", "parameters": "(service_name:str, process_name:str, data:dict)"}}, {"get_list_service_by_status": {"description": "List services by status.\n\nParameters\n----------\nrange: Integer\n Number of days for the statistic\n\nReturns\n-------\nDict()\n Key: Name of service\n Value: Statistics by status", "parameters": "(range:int) -> dict"}}, {"get_process_instance": {"description": "Get process instance.\n\nParameters\n----------\nservice_id: Integer\n Service ID\n\nReturns\n-------\nNone", "parameters": "(service_id)"}}, {"get_process_status_by_id": {"description": "Return process status by process_id.\n\nParameters\n----------\nprocess_id: Integer\n Id of workflow instance\n\nReturns\n-------\nString: RUNNING|FAIL|ENDED\n Status of the service\nOR\nNone: In case if execution failed", "parameters": "(process_id:int)"}}, {"get_service_status_by_id": {"description": "Return service status by service_id.\n\nParameters\n----------\nservice_id: Integer\n Id of workflow instance\n\nReturns\n-------\nString: RUNNING|FAIL|ENDED\n Status of the service\nOR\nNone: In case if execution failed", "parameters": "(service_id:int)"}}, {"get_service_variable_by_name": {"description": "Get services variable by name.\n\nParameters\n----------\nservice_id: Integer\n Service ID\nvariabel_name: String\n Name of the variable\n\nReturns\n-------\nNone", "parameters": "(service_id, variable_name)"}}, {"get_service_variables": {"description": "Get service variables.\n\nParameters\n----------\nservice_id: Integer\n Service ID\n\nReturns\n-------\nNone", "parameters": "(service_id)"}}, {"list_process_instances_by_service": {"description": "List process instances by Service.\n\nParameters\n----------\nservice_id: Integer\n Service ID\n\nReturns\n-------\nNone", "parameters": "(service_id)"}}, {"list_service_instances": {"description": "List service instances.\n\nReturns\n-------\nNone", "parameters": "()"}}, {"log_to_process_file": {"description": "Write log string with ISO timestamp to process log file.\n\nParameters\n----------\nprocess_id: String\n Process ID of current process\nlog_message: String\n Log text\n\nReturns\n-------\nTrue: log string has been written correctlly\nFalse: log string has not been written correctlly or the log\n file doesnt exist", "parameters": "(processId:str, log_message:str) -> bool"}}, {"process_content": {"description": "Process content.\n\nParameters\n----------\nstatus: String\n Status ID: 'ENDED', 'FAIL', 'RUNNING', 'WARNING', 'PAUSE'\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nResponse content formated", "parameters": "(status, comment, new_params, log_response=False)"}}, {"read_service_instance": {"description": "Read service instance.\n\nParameters\n----------\nservice_id: Integer\n Service ID\n\nReturns\n-------\nNone", "parameters": "(service_id)"}}, {"read_service_instance_by_condition": {"description": "Read service instance by condition.\n\nParameters\n----------\nservices_to_search: list\n[\"str\",\"str\"]\nservice_instance_id: int\nservice_external_reference: string\nprocess_instance_id: int\nservice_execution_status: string\nservice_variables: list\n[\n {\n \"variable\": \"apps_to_deploy[0].app_port\",\n \"operator\": \"=\",\n \"value\": \"80\",\n \"next_condition_joinOperator\": \"OR\"\n },\n {\n \"variable\": \"deployment_name\",\n \"operator\": \"=\",\n \"value\": \"Wordpress\",\n \"next_condition_joinOperator\": \"\"\n }\n]\n\nReturns\n-------\nserviceIds", "parameters": "(services_to_search:list, service_instance_id:int, service_external_reference:str, process_instance_id:int, service_execution_status:str, service_variables:list)"}}, {"resume_failed_or_paused_process_instance": {"description": "Resume a FAILED or PAUSED process instance.\n\nParameters\n----------\nprocess_id: Integer\n\nReturns\n-------\nNone", "parameters": "(process_id)"}}, {"task_error": {"description": "Task error and print.\n\nParameters\n----------\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nNone", "parameters": "(comment, context, log_response=True)"}}, {"task_success": {"description": "Task success and print.\n\nParameters\n----------\ncomment: String\n Comment\nnew_params: Dictionary\n Context\nlog_response: Bool\n Write log to a file\n\nReturns\n-------\nNone", "parameters": "(comment, context, log_response=True)"}}, {"update_asynchronous_task_details": {"description": "Update task comments in GUI dynamically.\n\nParameters\n----------\nprocess_id: Integer\n Process ID\ntask_id: Integer\n Task ID\nexec_number: Integer\n Number exec\ndata: String\n Task comment\n\nReturns\n-------\nNone", "parameters": "(process_id:int, task_id:int, exec_number:int, data:str) -> None"}}, {"update_process_script_details": {"description": "Update process script details.\n\nParameters\n----------\nprocess_id: Integer\n Process ID\ntask_id: Integer\n Task ID\nexec_number: Integer\n Number exec\n\nReturns\n-------\nNone", "parameters": "(process_id, task_id, exec_number, data=None)"}}, {"update_service_instance_reference": {"description": "Update service instance reference.\n\nParameters\n----------\nservice_id: Integer\n Process ID\nservice_ref: Integer\n Service reference\n\nReturns\n-------\nNone", "parameters": "(service_id, service_ref)"}}, {"update_service_variable": {"description": "Update service variable.\n\nParameters\n----------\nservice_id: Integer\n Service ID\nvariabel_name: String\n Name of the variable\nnew_value: String\n New servie variable name\n\nReturns\n-------\nNone", "parameters": "(service_id, variable_name, new_value)"}}, {"wait_and_run_execute_service_by_reference": {"description": "For the given instance reference, if the instance is already running, it will wait the end of the current execution and after execute the instance (cf execute_service_by_reference) and wait the end of this new execution and return the response (to get the status, used response['status']['status'] and to get the details : response['status']['details'] ). Timeout for previous instance and timeout for new instance.\n\nParameters\n----------\nubiqube_id: String\n ubiqube_id like \"NTTA14\"\nservice_external_ref: String\n Service external reference like \"NTTSID2867\"\nservice_name: String\n Service name like \"Process/workflows/test_wait_and_run_execute_service_by_reference/test_wait_and_run_execute_service_by_reference\"\nprocess_name: String\n Process name like \"Process/workflows/test_wait_and_run_execute_service_by_reference/Process_very_long_task\"\ndata: Json\n data json like dict(playbook='pb1')\ntimeout: Integer\n Timeout\ninterval: Integer\n interval\n\nReturns\n-------\nresponse", "parameters": "(ubiqube_id, service_external_ref, service_name, process_name, data, timeout=300, interval=10)"}}, {"wait_end_get_process_instance": {"description": "Wait that wf instance has finish and return the final dict result (where the status value is ENDED or FAILED).\n\nParameters\n----------\nprocess_id: Integer\n Process ID\ntimeout: Integer\n Timeout\ninterval: Integer\n interval\nReturns\n-------\nresponse", "parameters": "(process_id, timeout=600, interval=5)"}}]}, "util": {"methods": [{"address_is_in_network": {"description": "Address is in network.\n\nParameters\n----------\naddr: String\n Address - 10.0.0.20\nnet: String\n Network - 10.0.0.0/24\nmask: String\n Network mask\n\nReturns\n-------\nBool - Returns if the address overlaps a network", "parameters": "(addr, net)"}}, {"cidr_match": {"description": "Match cidr.\n\nParameters\n----------\nip_addr: String\n IP Address eg: 10.1.0.20\ncidr: String\n cidr eg. 10.1.0.20/32\n\nReturns\n-------\nBool", "parameters": "(ip_addr, cidr)"}}, {"cidr_to_range": {"description": "Get the Start and End Address of the IP range from CIDR.\n\nEg.[10.0.0.0/24] => 10.0.0.0 - 10.0.0.255\n\nParameters\n----------\ncdir: String\n cdir range\n\nReturns\n-------\nlist: List of ip range", "parameters": "(cdir)"}}, {"cidr_to_subnet_and_subnetmask_address": {"description": "Get the subnet and subnetmast from a cidr.\n\nParameters\n----------\ncidr: String eg. '10.0.0.0/24'\n cidr value\n\nReturns\n-------\nDict: netmask and network_address", "parameters": "(cidr)"}}, {"convert_yang_into_xml_file": {"description": "Convert YANG files into one XML file.\n\nParameters\n----------\nyang_filenames: Array\n It contains the list of YANG files (with full path name of\n each files\n\nReturns\n-------\nxml_output_file: String\n Filename of the new YANG file", "parameters": "(yang_filenames, xml_output_file:str)"}}, {"get_ip_range": {"description": "Generate a list of all IP addresses between $start and $end (inclusive).\n\nFor Ex. (1.1.1.1, 1.1.1.5) => [1.1.1.1, 1.1.1.2, 1.1.1.3, 1.1.1.4, 1.1.1.5]\n\nParameters\n----------\nstart: String\n start of the range\nend: String\n end of the range\n\nReturns\n-------\nlist: List of range of ips", "parameters": "(start, end) -> list"}}, {"ip_network": {"description": "Take an IP string/int and return an object of the correct type.\n\nArgs:\n address: A string or integer, the IP network. Either IPv4 or\n IPv6 networks may be supplied; integers less than 2**32 will\n be considered to be IPv4 by default.\n\nReturns:\n An IPv4Network or IPv6Network object.\n\nRaises:\n ValueError: if the string passed isn't either a v4 or a v6\n address. Or if the network has host bits set.", "parameters": "(address, strict=True)"}}, {"is_cidr": {"description": "Check if a valid cidr.\n\nParameters\n----------\naddr: String\n IP address\n\nReturns\n-------\nbool: Valid cidr", "parameters": "(addr)"}}, {"is_overlapping_cidr": {"description": "Check if cidr1 overlaps cidr2.\n\nParameters\n---------\ncidr1: String\n First cidr to compare\ncidr2: String\n Second cidr to compare\n\nReturns\n-------\nbool: Cidr overlaps", "parameters": "(cidr1, cidr2)"}}, {"log_to_process_file": {"description": "Write log string with ISO timestamp to process log file.\n\nParameters\n----------\nservice_id: String\n Service ID of current process\nlog_message: String\n Log text\nprocess_id: String\n Process ID of current process\n\nReturns\n-------\nbool:\n true: log string has been written correctlly\n\n false: log string has not been written correctlly or the\n log file doesnt exist", "parameters": "(service_id:str, log_message:str, process_id:str=None) -> bool"}}, {"netmask_to_cidr": {"description": "Netmask to cidr.\n\nParameters\n----------\nnetmask: String\n Netmask\n\nReturns\n-------\nstring: cidr netmask", "parameters": "(netmask)"}}, {"obtain_file_lock": {"description": "Obtain lock file.\n\nParameters\n----------\nlock_file_name: String\n File name\nmode: String mode\n File mode\nprocess_param: options PROCESSINSTANCEID, TASKID, EXECNUMBER\n Process parameters\nsleep_time: Integer\n Time to wait until next try\ntimeout: Integer\n How much time (timeout * sleep_time) it will take to timeout\n\nReturns\n------\njson: Result of the lock", "parameters": "(lock_file_name, mode, process_param, sleep_time=60, timeout=300)"}}, {"obtain_file_lock_exclusif": {"description": "Lock one file exclusivly (only the subtenant and instance_id who make the lock can unlock the file. If the file is locked by one other subtenant or instance_id, it will retry many time (<max_try_nb) to get the lock.\n\nParameters\n----------\nlock_file_name: String\n File name\nmode: String mode like 'w+'\n File mode\nprocess_param: options PROCESSINSTANCEID, TASKID, EXECNUMBER\n Process parameters\nsleep_time: Integer\n Time to wait until next try\nmax_try_nb: Integer\n Max number of try, the timeout will be max_try_nb * sleep_time\n\nReturns\n------\nResult of the lock", "parameters": "(lock_file_name, process_param, mode='w+', sleep_time=15, max_try_nb=10)"}}, {"release_file_lock": {"description": "Release lock file.\n\nParameters\n----------\nlock_file_name: String\n File name\nprocess_param: options PROCESSINSTANCEID, TASKID, EXECNUMBER\n Process parameters\nsleep_time: Integer\n Time to wait until next try\ntimeout: Integer\n How much time (timeout * sleep_time) it will take to timeout\n\nReturns\n------\njson: Result of the release", "parameters": "(lock_file_name, process_param, sleep_time=60, timeout=300)"}}, {"release_file_lock_exclusif": {"description": "Release lock file exclusif (only the subtenant and instance_id who make the lock can unlock.\n\nParameters\n----------\nlock_file_name: String\n File name\nprocess_param: options PROCESSINSTANCEID, TASKID, EXECNUMBER\n Process parameters\nsleep_time: Integer\n Time to wait until next try\nmax_try_nb: Integer\n Max number of try, the timeout will be max_try_nb * sleep_time\n\n\nReturns\n------\nResult of the release", "parameters": "(lock_file_name, process_param, sleep_time=30, max_try_nb=10)"}}, {"update_asynchronous_task_details": {"description": "Update Asynchronous Task details.\n\nPrint task details during Process execution.\n\nParameters\n----------\ndetail: String\n The message to display in msa-ui\n\nReturns\n-------\nobject: Orchestration", "parameters": "(details:str)"}}]}}