here is a new method that could be integrated which allow to clone an adom into a new one
def clone_adom(self, name):"""clone existing adom from the FortiManager into a new one:param name: name of the new adom:return: Response of status code with data in JSON Format"""payload = {"method": "clone","params": [{"url": f"/dvmdb/adom/{self.adom}","data": {"name": f"{name}"}}]}payload.update({"session": self.sessionid})clone_adom = self.session.post(url=self.base_url, json=payload)return clone_adom.json()
here is a new method that could be integrated which allow to clone an adom into a new one
def clone_adom(self, name):
"""
clone existing adom from the FortiManager into a new one
:param name: name of the new adom
:return: Response of status code with data in JSON Format
"""
payload = {
"method": "clone",
"params": [
{
"url": f"/dvmdb/adom/{self.adom}",
"data": {
"name": f"{name}"
}
}
]
}
payload.update({"session": self.sessionid})
clone_adom = self.session.post(url=self.base_url, json=payload)
return clone_adom.json()