Infrastructure¶
-
tnglib.clean_infrastructure()¶ Delete all vims and wims
Returns: A tuple. [0] is a bool with the result.
-
tnglib.delete_vim(vim_uuid)¶ Delete a vim.
Parameters: vim_uuid – uuid of the vim to be deleted. Returns: A tuple. [0] is a bool with the result. [1] is response message.
-
tnglib.delete_wim(wim_uuid)¶ Delete a wim.
Parameters: wim_uuid – uuid of the wim to be deleted. Returns: A tuple. [0] is a bool with the result. [1] is response message.
-
tnglib.get_vim(vim_uuid)¶ Get a vim.
Parameters: vim_uuid – uuid of the vim. Returns: A tuple. [0] is a bool with the result. [1] is response message.
-
tnglib.get_wim(wim_uuid)¶ Get a wim.
Parameters: wim_uuid – uuid of the wim. Returns: A tuple. [0] is a bool with the result. [1] is response message.
-
tnglib.get_vims(vim_type=None)¶ Obtain the available Vims.
Parameters: type – optional type of vim Returns: A tuple. [0] is a bool with the result. [1] is a list of dictionaries. Each dictionary contains a vim.
-
tnglib.get_wims(wim_type=None)¶ Obtain the available Wims.
Parameters: type – optional type of wim Returns: A tuple. [0] is a bool with the result. [1] is a list of dictionaries. Each dictionary contains a wim.
-
tnglib.post_vim(vim_type, payload)¶ Post a vim
Parameters: - vim_type – the type of vim
- json_payload – the payload as json
Returns: A tuple. [0] is a bool with the result. [1] the uuid of the vim.
-
tnglib.post_wim(wim_type, payload)¶ Post a wim
Parameters: - wim_type – the type of wim
- json_payload – the payload as json
Returns: A tuple. [0] is a bool with the result. [1] the uuid of the wim.