]> git.proxmox.com Git - pmg-docs.git/commitdiff
update generated API schema
authorDietmar Maurer <dietmar@proxmox.com>
Tue, 24 Oct 2017 06:49:28 +0000 (08:49 +0200)
committerDietmar Maurer <dietmar@proxmox.com>
Tue, 24 Oct 2017 06:49:28 +0000 (08:49 +0200)
api-viewer/apidata.js

index 1990b16ec66ddcf9b11e4aa54115ad51efa6a355..d56e4f4c732c0627cccaa6ec221d27780466bffe 100644 (file)
@@ -12,6 +12,12 @@ var pmgapi = [
                         "parameters" : {
                            "additionalProperties" : 0
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "returns" : {
                            "type" : "string"
                         }
@@ -41,6 +47,12 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "proxyto" : "master",
                                     "returns" : {
                                        "properties" : {
@@ -105,6 +117,11 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "master",
                                     "returns" : {
@@ -139,6 +156,11 @@ var pmgapi = [
                                                 }
                                              }
                                           },
+                                          "permissions" : {
+                                             "check" : [
+                                                "admin"
+                                             ]
+                                          },
                                           "protected" : 1,
                                           "proxyto" : "master",
                                           "returns" : {
@@ -166,6 +188,12 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "proxyto" : "master",
                                     "returns" : {
                                        "items" : {
@@ -198,6 +226,11 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "master",
                                     "returns" : {
@@ -232,6 +265,11 @@ var pmgapi = [
                                                 }
                                              }
                                           },
+                                          "permissions" : {
+                                             "check" : [
+                                                "admin"
+                                             ]
+                                          },
                                           "protected" : 1,
                                           "proxyto" : "master",
                                           "returns" : {
@@ -259,6 +297,12 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "proxyto" : "master",
                                     "returns" : {
                                        "items" : {
@@ -291,6 +335,11 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "master",
                                     "returns" : {
@@ -325,6 +374,11 @@ var pmgapi = [
                                                 }
                                              }
                                           },
+                                          "permissions" : {
+                                             "check" : [
+                                                "admin"
+                                             ]
+                                          },
                                           "protected" : 1,
                                           "proxyto" : "master",
                                           "returns" : {
@@ -352,6 +406,12 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "proxyto" : "master",
                                     "returns" : {
                                        "items" : {
@@ -384,6 +444,11 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "master",
                                     "returns" : {
@@ -418,6 +483,11 @@ var pmgapi = [
                                                 }
                                              }
                                           },
+                                          "permissions" : {
+                                             "check" : [
+                                                "admin"
+                                             ]
+                                          },
                                           "protected" : 1,
                                           "proxyto" : "master",
                                           "returns" : {
@@ -445,6 +515,12 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "proxyto" : "master",
                                     "returns" : {
                                        "items" : {
@@ -477,6 +553,11 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "master",
                                     "returns" : {
@@ -511,6 +592,11 @@ var pmgapi = [
                                                 }
                                              }
                                           },
+                                          "permissions" : {
+                                             "check" : [
+                                                "admin"
+                                             ]
+                                          },
                                           "protected" : 1,
                                           "proxyto" : "master",
                                           "returns" : {
@@ -538,6 +624,12 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "proxyto" : "master",
                                     "returns" : {
                                        "items" : {
@@ -570,6 +662,11 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "master",
                                     "returns" : {
@@ -597,6 +694,11 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin"
+                                 ]
+                              },
                               "protected" : 1,
                               "proxyto" : "master",
                               "returns" : {
@@ -617,6 +719,12 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin",
+                                    "audit"
+                                 ]
+                              },
                               "returns" : {
                                  "items" : {
                                     "properties" : {
@@ -649,6 +757,12 @@ var pmgapi = [
                         "parameters" : {
                            "additionalProperties" : 0
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "proxyto" : "master",
                         "returns" : {
                            "items" : {
@@ -703,6 +817,11 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin"
+                           ]
+                        },
                         "protected" : 1,
                         "proxyto" : "master",
                         "returns" : {
@@ -734,6 +853,11 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "master",
                                     "returns" : {
@@ -754,6 +878,12 @@ var pmgapi = [
                               "parameters" : {
                                  "additionalProperties" : 0
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin",
+                                    "audit"
+                                 ]
+                              },
                               "proxyto" : "master",
                               "returns" : {
                                  "items" : {
@@ -798,6 +928,12 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "proxyto" : "master",
                                     "returns" : {
                                        "properties" : {
@@ -849,6 +985,11 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "master",
                                     "returns" : {
@@ -897,6 +1038,11 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin"
+                                 ]
+                              },
                               "protected" : 1,
                               "proxyto" : "master",
                               "returns" : {
@@ -908,69 +1054,35 @@ var pmgapi = [
                         "leaf" : 0,
                         "path" : "/config/ruledb/action/bcc",
                         "text" : "bcc"
-                     }
-                  ],
-                  "info" : {
-                     "GET" : {
-                        "description" : "Directory index.",
-                        "method" : "GET",
-                        "name" : "index",
-                        "parameters" : {
-                           "additionalProperties" : 0
-                        },
-                        "returns" : {
-                           "items" : {
-                              "properties" : {
-                                 "subdir" : {
-                                    "type" : "string"
-                                 }
-                              },
-                              "type" : "object"
-                           },
-                           "links" : [
-                              {
-                                 "href" : "{subdir}",
-                                 "rel" : "child"
-                              }
-                           ],
-                           "type" : "array"
-                        }
-                     }
-                  },
-                  "leaf" : 0,
-                  "path" : "/config/ruledb/action",
-                  "text" : "action"
-               },
-               {
-                  "children" : [
+                     },
                      {
                         "children" : [
                            {
                               "info" : {
                                  "GET" : {
-                                    "description" : "Get 'what' group properties",
+                                    "description" : "Read 'Header Attribute' object settings.",
                                     "method" : "GET",
-                                    "name" : "get_config",
+                                    "name" : "read_field",
                                     "parameters" : {
                                        "additionalProperties" : 0,
                                        "properties" : {
-                                          "ogroup" : {
-                                             "description" : "Object Group ID.",
-                                             "type" : "integer",
-                                             "typetext" : "<integer>"
+                                          "id" : {
+                                             "description" : "Action Object ID.",
+                                             "pattern" : "\\d+_\\d+",
+                                             "type" : "string"
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "proxyto" : "master",
                                     "returns" : {
                                        "properties" : {
                                           "id" : {
-                                             "type" : "integer"
-                                          },
-                                          "info" : {
-                                             "type" : "string"
-                                          },
-                                          "name" : {
                                              "type" : "string"
                                           }
                                        },
@@ -978,12 +1090,23 @@ var pmgapi = [
                                     }
                                  },
                                  "PUT" : {
-                                    "description" : "Modify 'what' group properties",
+                                    "description" : "Update 'Header Attribute' object.",
                                     "method" : "PUT",
-                                    "name" : "set_config",
+                                    "name" : "update_field",
                                     "parameters" : {
                                        "additionalProperties" : 0,
                                        "properties" : {
+                                          "field" : {
+                                             "description" : "The Field",
+                                             "maxLength" : 1024,
+                                             "pattern" : "[0-9a-zA-Z\\/\\\\[\\]\\+\\-\\.\\*\\_]+",
+                                             "type" : "string"
+                                          },
+                                          "id" : {
+                                             "description" : "Action Object ID.",
+                                             "pattern" : "\\d+_\\d+",
+                                             "type" : "string"
+                                          },
                                           "info" : {
                                              "description" : "Informational comment.",
                                              "maxLength" : 255,
@@ -992,19 +1115,25 @@ var pmgapi = [
                                              "typetext" : "<string>"
                                           },
                                           "name" : {
-                                             "description" : "Group name.",
+                                             "description" : "Action name.",
                                              "maxLength" : 255,
                                              "optional" : 1,
                                              "type" : "string",
                                              "typetext" : "<string>"
                                           },
-                                          "ogroup" : {
-                                             "description" : "Object Group ID.",
-                                             "type" : "integer",
-                                             "typetext" : "<integer>"
+                                          "value" : {
+                                             "description" : "The Value",
+                                             "maxLength" : 1024,
+                                             "pattern" : "[0-9a-zA-Z\\/\\\\[\\]\\+\\-\\.\\*\\_]+",
+                                             "type" : "string"
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "master",
                                     "returns" : {
@@ -1013,34 +1142,659 @@ var pmgapi = [
                                  }
                               },
                               "leaf" : 1,
-                              "path" : "/config/ruledb/what/{ogroup}/config",
-                              "text" : "config"
-                           },
-                           {
-                              "children" : [
-                                 {
+                              "path" : "/config/ruledb/action/field/{id}",
+                              "text" : "{id}"
+                           }
+                        ],
+                        "info" : {
+                           "POST" : {
+                              "description" : "Create 'Header Attribute' object.",
+                              "method" : "POST",
+                              "name" : "field",
+                              "parameters" : {
+                                 "additionalProperties" : 0,
+                                 "properties" : {
+                                    "field" : {
+                                       "description" : "The Field",
+                                       "maxLength" : 1024,
+                                       "pattern" : "[0-9a-zA-Z\\/\\\\[\\]\\+\\-\\.\\*\\_]+",
+                                       "type" : "string"
+                                    },
                                     "info" : {
-                                       "DELETE" : {
-                                          "description" : "Remove an object from the 'what' group.",
-                                          "method" : "DELETE",
-                                          "name" : "delete_object",
-                                          "parameters" : {
-                                             "additionalProperties" : 0,
-                                             "properties" : {
-                                                "id" : {
-                                                   "description" : "Object ID.",
-                                                   "type" : "integer",
-                                                   "typetext" : "<integer>"
-                                                },
-                                                "ogroup" : {
-                                                   "description" : "Object Group ID.",
-                                                   "type" : "integer",
-                                                   "typetext" : "<integer>"
-                                                }
-                                             }
-                                          },
-                                          "protected" : 1,
-                                          "proxyto" : "master",
+                                       "description" : "Informational comment.",
+                                       "maxLength" : 255,
+                                       "optional" : 1,
+                                       "type" : "string",
+                                       "typetext" : "<string>"
+                                    },
+                                    "name" : {
+                                       "description" : "Action name.",
+                                       "maxLength" : 255,
+                                       "type" : "string",
+                                       "typetext" : "<string>"
+                                    },
+                                    "value" : {
+                                       "description" : "The Value",
+                                       "maxLength" : 1024,
+                                       "pattern" : "[0-9a-zA-Z\\/\\\\[\\]\\+\\-\\.\\*\\_]+",
+                                       "type" : "string"
+                                    }
+                                 }
+                              },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin"
+                                 ]
+                              },
+                              "protected" : 1,
+                              "proxyto" : "master",
+                              "returns" : {
+                                 "description" : "The object ID.",
+                                 "type" : "string"
+                              }
+                           }
+                        },
+                        "leaf" : 0,
+                        "path" : "/config/ruledb/action/field",
+                        "text" : "field"
+                     },
+                     {
+                        "children" : [
+                           {
+                              "info" : {
+                                 "GET" : {
+                                    "description" : "Read 'Notification' object settings.",
+                                    "method" : "GET",
+                                    "name" : "read_notification",
+                                    "parameters" : {
+                                       "additionalProperties" : 0,
+                                       "properties" : {
+                                          "id" : {
+                                             "description" : "Action Object ID.",
+                                             "pattern" : "\\d+_\\d+",
+                                             "type" : "string"
+                                          }
+                                       }
+                                    },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
+                                    "proxyto" : "master",
+                                    "returns" : {
+                                       "properties" : {
+                                          "id" : {
+                                             "type" : "string"
+                                          }
+                                       },
+                                       "type" : "object"
+                                    }
+                                 },
+                                 "PUT" : {
+                                    "description" : "Update 'Notification' object.",
+                                    "method" : "PUT",
+                                    "name" : "update_notification",
+                                    "parameters" : {
+                                       "additionalProperties" : 0,
+                                       "properties" : {
+                                          "attach" : {
+                                             "default" : 0,
+                                             "description" : "Attach original E-Mail",
+                                             "optional" : 1,
+                                             "type" : "boolean",
+                                             "typetext" : "<boolean>"
+                                          },
+                                          "body" : {
+                                             "description" : "The Notification Body",
+                                             "maxLength" : 2048,
+                                             "type" : "string",
+                                             "typetext" : "<string>"
+                                          },
+                                          "id" : {
+                                             "description" : "Action Object ID.",
+                                             "pattern" : "\\d+_\\d+",
+                                             "type" : "string"
+                                          },
+                                          "info" : {
+                                             "description" : "Informational comment.",
+                                             "maxLength" : 255,
+                                             "optional" : 1,
+                                             "type" : "string",
+                                             "typetext" : "<string>"
+                                          },
+                                          "name" : {
+                                             "description" : "Action name.",
+                                             "maxLength" : 255,
+                                             "optional" : 1,
+                                             "type" : "string",
+                                             "typetext" : "<string>"
+                                          },
+                                          "subject" : {
+                                             "description" : "The Notification subject",
+                                             "maxLength" : 100,
+                                             "type" : "string",
+                                             "typetext" : "<string>"
+                                          },
+                                          "to" : {
+                                             "description" : "The Receiver E-Mail address",
+                                             "maxLength" : 200,
+                                             "type" : "string",
+                                             "typetext" : "<string>"
+                                          }
+                                       }
+                                    },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
+                                    "protected" : 1,
+                                    "proxyto" : "master",
+                                    "returns" : {
+                                       "type" : "null"
+                                    }
+                                 }
+                              },
+                              "leaf" : 1,
+                              "path" : "/config/ruledb/action/notification/{id}",
+                              "text" : "{id}"
+                           }
+                        ],
+                        "info" : {
+                           "POST" : {
+                              "description" : "Create 'Notification' object.",
+                              "method" : "POST",
+                              "name" : "notification",
+                              "parameters" : {
+                                 "additionalProperties" : 0,
+                                 "properties" : {
+                                    "attach" : {
+                                       "default" : 0,
+                                       "description" : "Attach original E-Mail",
+                                       "optional" : 1,
+                                       "type" : "boolean",
+                                       "typetext" : "<boolean>"
+                                    },
+                                    "body" : {
+                                       "description" : "The Notification Body",
+                                       "maxLength" : 2048,
+                                       "type" : "string",
+                                       "typetext" : "<string>"
+                                    },
+                                    "info" : {
+                                       "description" : "Informational comment.",
+                                       "maxLength" : 255,
+                                       "optional" : 1,
+                                       "type" : "string",
+                                       "typetext" : "<string>"
+                                    },
+                                    "name" : {
+                                       "description" : "Action name.",
+                                       "maxLength" : 255,
+                                       "type" : "string",
+                                       "typetext" : "<string>"
+                                    },
+                                    "subject" : {
+                                       "description" : "The Notification subject",
+                                       "maxLength" : 100,
+                                       "type" : "string",
+                                       "typetext" : "<string>"
+                                    },
+                                    "to" : {
+                                       "description" : "The Receiver E-Mail address",
+                                       "maxLength" : 200,
+                                       "type" : "string",
+                                       "typetext" : "<string>"
+                                    }
+                                 }
+                              },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin"
+                                 ]
+                              },
+                              "protected" : 1,
+                              "proxyto" : "master",
+                              "returns" : {
+                                 "description" : "The object ID.",
+                                 "type" : "string"
+                              }
+                           }
+                        },
+                        "leaf" : 0,
+                        "path" : "/config/ruledb/action/notification",
+                        "text" : "notification"
+                     },
+                     {
+                        "children" : [
+                           {
+                              "info" : {
+                                 "GET" : {
+                                    "description" : "Read 'Disclaimer' object settings.",
+                                    "method" : "GET",
+                                    "name" : "read_disclaimer",
+                                    "parameters" : {
+                                       "additionalProperties" : 0,
+                                       "properties" : {
+                                          "id" : {
+                                             "description" : "Action Object ID.",
+                                             "pattern" : "\\d+_\\d+",
+                                             "type" : "string"
+                                          }
+                                       }
+                                    },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
+                                    "proxyto" : "master",
+                                    "returns" : {
+                                       "properties" : {
+                                          "id" : {
+                                             "type" : "string"
+                                          }
+                                       },
+                                       "type" : "object"
+                                    }
+                                 },
+                                 "PUT" : {
+                                    "description" : "Update 'Disclaimer' object.",
+                                    "method" : "PUT",
+                                    "name" : "update_disclaimer",
+                                    "parameters" : {
+                                       "additionalProperties" : 0,
+                                       "properties" : {
+                                          "disclaimer" : {
+                                             "description" : "The Disclaimer",
+                                             "maxLength" : 2048,
+                                             "type" : "string",
+                                             "typetext" : "<string>"
+                                          },
+                                          "id" : {
+                                             "description" : "Action Object ID.",
+                                             "pattern" : "\\d+_\\d+",
+                                             "type" : "string"
+                                          },
+                                          "info" : {
+                                             "description" : "Informational comment.",
+                                             "maxLength" : 255,
+                                             "optional" : 1,
+                                             "type" : "string",
+                                             "typetext" : "<string>"
+                                          },
+                                          "name" : {
+                                             "description" : "Action name.",
+                                             "maxLength" : 255,
+                                             "optional" : 1,
+                                             "type" : "string",
+                                             "typetext" : "<string>"
+                                          }
+                                       }
+                                    },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
+                                    "protected" : 1,
+                                    "proxyto" : "master",
+                                    "returns" : {
+                                       "type" : "null"
+                                    }
+                                 }
+                              },
+                              "leaf" : 1,
+                              "path" : "/config/ruledb/action/disclaimer/{id}",
+                              "text" : "{id}"
+                           }
+                        ],
+                        "info" : {
+                           "POST" : {
+                              "description" : "Create 'Disclaimer' object.",
+                              "method" : "POST",
+                              "name" : "disclaimer",
+                              "parameters" : {
+                                 "additionalProperties" : 0,
+                                 "properties" : {
+                                    "disclaimer" : {
+                                       "description" : "The Disclaimer",
+                                       "maxLength" : 2048,
+                                       "type" : "string",
+                                       "typetext" : "<string>"
+                                    },
+                                    "info" : {
+                                       "description" : "Informational comment.",
+                                       "maxLength" : 255,
+                                       "optional" : 1,
+                                       "type" : "string",
+                                       "typetext" : "<string>"
+                                    },
+                                    "name" : {
+                                       "description" : "Action name.",
+                                       "maxLength" : 255,
+                                       "type" : "string",
+                                       "typetext" : "<string>"
+                                    }
+                                 }
+                              },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin"
+                                 ]
+                              },
+                              "protected" : 1,
+                              "proxyto" : "master",
+                              "returns" : {
+                                 "description" : "The object ID.",
+                                 "type" : "string"
+                              }
+                           }
+                        },
+                        "leaf" : 0,
+                        "path" : "/config/ruledb/action/disclaimer",
+                        "text" : "disclaimer"
+                     },
+                     {
+                        "children" : [
+                           {
+                              "info" : {
+                                 "GET" : {
+                                    "description" : "Read 'Remove attachments' object settings.",
+                                    "method" : "GET",
+                                    "name" : "read_removeattachments",
+                                    "parameters" : {
+                                       "additionalProperties" : 0,
+                                       "properties" : {
+                                          "id" : {
+                                             "description" : "Action Object ID.",
+                                             "pattern" : "\\d+_\\d+",
+                                             "type" : "string"
+                                          }
+                                       }
+                                    },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
+                                    "proxyto" : "master",
+                                    "returns" : {
+                                       "properties" : {
+                                          "id" : {
+                                             "type" : "string"
+                                          }
+                                       },
+                                       "type" : "object"
+                                    }
+                                 },
+                                 "PUT" : {
+                                    "description" : "Update 'Remove attachments' object.",
+                                    "method" : "PUT",
+                                    "name" : "update_removeattachments",
+                                    "parameters" : {
+                                       "additionalProperties" : 0,
+                                       "properties" : {
+                                          "all" : {
+                                             "description" : "Remove all attachments",
+                                             "optional" : 1,
+                                             "type" : "boolean",
+                                             "typetext" : "<boolean>"
+                                          },
+                                          "id" : {
+                                             "description" : "Action Object ID.",
+                                             "pattern" : "\\d+_\\d+",
+                                             "type" : "string"
+                                          },
+                                          "info" : {
+                                             "description" : "Informational comment.",
+                                             "maxLength" : 255,
+                                             "optional" : 1,
+                                             "type" : "string",
+                                             "typetext" : "<string>"
+                                          },
+                                          "name" : {
+                                             "description" : "Action name.",
+                                             "maxLength" : 255,
+                                             "optional" : 1,
+                                             "type" : "string",
+                                             "typetext" : "<string>"
+                                          },
+                                          "text" : {
+                                             "description" : "The replacement text.",
+                                             "maxLength" : 2048,
+                                             "type" : "string",
+                                             "typetext" : "<string>"
+                                          }
+                                       }
+                                    },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
+                                    "protected" : 1,
+                                    "proxyto" : "master",
+                                    "returns" : {
+                                       "type" : "null"
+                                    }
+                                 }
+                              },
+                              "leaf" : 1,
+                              "path" : "/config/ruledb/action/removeattachments/{id}",
+                              "text" : "{id}"
+                           }
+                        ],
+                        "info" : {
+                           "POST" : {
+                              "description" : "Create 'Remove attachments' object.",
+                              "method" : "POST",
+                              "name" : "removeattachments",
+                              "parameters" : {
+                                 "additionalProperties" : 0,
+                                 "properties" : {
+                                    "all" : {
+                                       "description" : "Remove all attachments",
+                                       "optional" : 1,
+                                       "type" : "boolean",
+                                       "typetext" : "<boolean>"
+                                    },
+                                    "info" : {
+                                       "description" : "Informational comment.",
+                                       "maxLength" : 255,
+                                       "optional" : 1,
+                                       "type" : "string",
+                                       "typetext" : "<string>"
+                                    },
+                                    "name" : {
+                                       "description" : "Action name.",
+                                       "maxLength" : 255,
+                                       "type" : "string",
+                                       "typetext" : "<string>"
+                                    },
+                                    "text" : {
+                                       "description" : "The replacement text.",
+                                       "maxLength" : 2048,
+                                       "type" : "string",
+                                       "typetext" : "<string>"
+                                    }
+                                 }
+                              },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin"
+                                 ]
+                              },
+                              "protected" : 1,
+                              "proxyto" : "master",
+                              "returns" : {
+                                 "description" : "The object ID.",
+                                 "type" : "string"
+                              }
+                           }
+                        },
+                        "leaf" : 0,
+                        "path" : "/config/ruledb/action/removeattachments",
+                        "text" : "removeattachments"
+                     }
+                  ],
+                  "info" : {
+                     "GET" : {
+                        "description" : "Directory index.",
+                        "method" : "GET",
+                        "name" : "index",
+                        "parameters" : {
+                           "additionalProperties" : 0
+                        },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
+                        "returns" : {
+                           "items" : {
+                              "properties" : {
+                                 "subdir" : {
+                                    "type" : "string"
+                                 }
+                              },
+                              "type" : "object"
+                           },
+                           "links" : [
+                              {
+                                 "href" : "{subdir}",
+                                 "rel" : "child"
+                              }
+                           ],
+                           "type" : "array"
+                        }
+                     }
+                  },
+                  "leaf" : 0,
+                  "path" : "/config/ruledb/action",
+                  "text" : "action"
+               },
+               {
+                  "children" : [
+                     {
+                        "children" : [
+                           {
+                              "info" : {
+                                 "GET" : {
+                                    "description" : "Get 'what' group properties",
+                                    "method" : "GET",
+                                    "name" : "get_config",
+                                    "parameters" : {
+                                       "additionalProperties" : 0,
+                                       "properties" : {
+                                          "ogroup" : {
+                                             "description" : "Object Group ID.",
+                                             "type" : "integer",
+                                             "typetext" : "<integer>"
+                                          }
+                                       }
+                                    },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
+                                    "proxyto" : "master",
+                                    "returns" : {
+                                       "properties" : {
+                                          "id" : {
+                                             "type" : "integer"
+                                          },
+                                          "info" : {
+                                             "type" : "string"
+                                          },
+                                          "name" : {
+                                             "type" : "string"
+                                          }
+                                       },
+                                       "type" : "object"
+                                    }
+                                 },
+                                 "PUT" : {
+                                    "description" : "Modify 'what' group properties",
+                                    "method" : "PUT",
+                                    "name" : "set_config",
+                                    "parameters" : {
+                                       "additionalProperties" : 0,
+                                       "properties" : {
+                                          "info" : {
+                                             "description" : "Informational comment.",
+                                             "maxLength" : 255,
+                                             "optional" : 1,
+                                             "type" : "string",
+                                             "typetext" : "<string>"
+                                          },
+                                          "name" : {
+                                             "description" : "Group name.",
+                                             "maxLength" : 255,
+                                             "optional" : 1,
+                                             "type" : "string",
+                                             "typetext" : "<string>"
+                                          },
+                                          "ogroup" : {
+                                             "description" : "Object Group ID.",
+                                             "type" : "integer",
+                                             "typetext" : "<integer>"
+                                          }
+                                       }
+                                    },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
+                                    "protected" : 1,
+                                    "proxyto" : "master",
+                                    "returns" : {
+                                       "type" : "null"
+                                    }
+                                 }
+                              },
+                              "leaf" : 1,
+                              "path" : "/config/ruledb/what/{ogroup}/config",
+                              "text" : "config"
+                           },
+                           {
+                              "children" : [
+                                 {
+                                    "info" : {
+                                       "DELETE" : {
+                                          "description" : "Remove an object from the 'what' group.",
+                                          "method" : "DELETE",
+                                          "name" : "delete_object",
+                                          "parameters" : {
+                                             "additionalProperties" : 0,
+                                             "properties" : {
+                                                "id" : {
+                                                   "description" : "Object ID.",
+                                                   "type" : "integer",
+                                                   "typetext" : "<integer>"
+                                                },
+                                                "ogroup" : {
+                                                   "description" : "Object Group ID.",
+                                                   "type" : "integer",
+                                                   "typetext" : "<integer>"
+                                                }
+                                             }
+                                          },
+                                          "permissions" : {
+                                             "check" : [
+                                                "admin"
+                                             ]
+                                          },
+                                          "protected" : 1,
+                                          "proxyto" : "master",
                                           "returns" : {
                                              "type" : "null"
                                           }
@@ -1066,6 +1820,12 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "proxyto" : "master",
                                     "returns" : {
                                        "items" : {
@@ -1616,6 +2376,97 @@ var pmgapi = [
                               "leaf" : 0,
                               "path" : "/config/ruledb/what/{ogroup}/filenamefilter",
                               "text" : "filenamefilter"
+                           },
+                           {
+                              "children" : [
+                                 {
+                                    "info" : {
+                                       "GET" : {
+                                          "description" : "Read 'Virus Filter' object settings.",
+                                          "method" : "GET",
+                                          "name" : "read_virusfilter",
+                                          "parameters" : {
+                                             "additionalProperties" : 0,
+                                             "properties" : {
+                                                "id" : {
+                                                   "description" : "Object ID.",
+                                                   "type" : "integer",
+                                                   "typetext" : "<integer>"
+                                                },
+                                                "ogroup" : {
+                                                   "description" : "Object Groups ID.",
+                                                   "type" : "integer",
+                                                   "typetext" : "<integer>"
+                                                }
+                                             }
+                                          },
+                                          "proxyto" : "master",
+                                          "returns" : {
+                                             "properties" : {
+                                                "id" : {
+                                                   "type" : "integer"
+                                                }
+                                             },
+                                             "type" : "object"
+                                          }
+                                       },
+                                       "PUT" : {
+                                          "description" : "Update 'Virus Filter' object.",
+                                          "method" : "PUT",
+                                          "name" : "update_virusfilter",
+                                          "parameters" : {
+                                             "additionalProperties" : 0,
+                                             "properties" : {
+                                                "id" : {
+                                                   "description" : "Object ID.",
+                                                   "type" : "integer",
+                                                   "typetext" : "<integer>"
+                                                },
+                                                "ogroup" : {
+                                                   "description" : "Object Groups ID.",
+                                                   "type" : "integer",
+                                                   "typetext" : "<integer>"
+                                                }
+                                             }
+                                          },
+                                          "protected" : 1,
+                                          "proxyto" : "master",
+                                          "returns" : {
+                                             "type" : "null"
+                                          }
+                                       }
+                                    },
+                                    "leaf" : 1,
+                                    "path" : "/config/ruledb/what/{ogroup}/virusfilter/{id}",
+                                    "text" : "{id}"
+                                 }
+                              ],
+                              "info" : {
+                                 "POST" : {
+                                    "description" : "Add 'Virus Filter' object.",
+                                    "method" : "POST",
+                                    "name" : "virusfilter",
+                                    "parameters" : {
+                                       "additionalProperties" : 0,
+                                       "properties" : {
+                                          "ogroup" : {
+                                             "description" : "Object Groups ID.",
+                                             "type" : "integer",
+                                             "typetext" : "<integer>"
+                                          }
+                                       }
+                                    },
+                                    "protected" : 1,
+                                    "proxyto" : "master",
+                                    "returns" : {
+                                       "description" : "The object ID.",
+                                       "type" : "integer"
+                                    }
+                                 }
+                              },
+                              "leaf" : 0,
+                              "path" : "/config/ruledb/what/{ogroup}/virusfilter",
+                              "text" : "virusfilter"
                            }
                         ],
                         "info" : {
@@ -1633,6 +2484,11 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin"
+                                 ]
+                              },
                               "protected" : 1,
                               "proxyto" : "master",
                               "returns" : {
@@ -1653,6 +2509,12 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin",
+                                    "audit"
+                                 ]
+                              },
                               "returns" : {
                                  "items" : {
                                     "properties" : {
@@ -1685,6 +2547,12 @@ var pmgapi = [
                         "parameters" : {
                            "additionalProperties" : 0
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "proxyto" : "master",
                         "returns" : {
                            "items" : {
@@ -1720,6 +2588,11 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin"
+                           ]
+                        },
                         "protected" : 1,
                         "proxyto" : "master",
                         "returns" : {
@@ -1751,6 +2624,12 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "proxyto" : "master",
                                     "returns" : {
                                        "properties" : {
@@ -1795,6 +2674,11 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "master",
                                     "returns" : {
@@ -1829,6 +2713,11 @@ var pmgapi = [
                                                 }
                                              }
                                           },
+                                          "permissions" : {
+                                             "check" : [
+                                                "admin"
+                                             ]
+                                          },
                                           "protected" : 1,
                                           "proxyto" : "master",
                                           "returns" : {
@@ -1856,6 +2745,12 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "proxyto" : "master",
                                     "returns" : {
                                        "items" : {
@@ -2007,6 +2902,11 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin"
+                                 ]
+                              },
                               "protected" : 1,
                               "proxyto" : "master",
                               "returns" : {
@@ -2027,6 +2927,12 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin",
+                                    "audit"
+                                 ]
+                              },
                               "returns" : {
                                  "items" : {
                                     "properties" : {
@@ -2059,6 +2965,12 @@ var pmgapi = [
                         "parameters" : {
                            "additionalProperties" : 0
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "proxyto" : "master",
                         "returns" : {
                            "items" : {
@@ -2094,6 +3006,11 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin"
+                           ]
+                        },
                         "protected" : 1,
                         "proxyto" : "master",
                         "returns" : {
@@ -2125,6 +3042,12 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "proxyto" : "master",
                                     "returns" : {
                                        "properties" : {
@@ -2169,6 +3092,11 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "master",
                                     "returns" : {
@@ -2203,6 +3131,11 @@ var pmgapi = [
                                                 }
                                              }
                                           },
+                                          "permissions" : {
+                                             "check" : [
+                                                "admin"
+                                             ]
+                                          },
                                           "protected" : 1,
                                           "proxyto" : "master",
                                           "returns" : {
@@ -2230,6 +3163,12 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "proxyto" : "master",
                                     "returns" : {
                                        "items" : {
@@ -3041,6 +3980,11 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin"
+                                 ]
+                              },
                               "protected" : 1,
                               "proxyto" : "master",
                               "returns" : {
@@ -3061,6 +4005,12 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin",
+                                    "audit"
+                                 ]
+                              },
                               "returns" : {
                                  "items" : {
                                     "properties" : {
@@ -3093,6 +4043,12 @@ var pmgapi = [
                         "parameters" : {
                            "additionalProperties" : 0
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "proxyto" : "master",
                         "returns" : {
                            "items" : {
@@ -3128,6 +4084,11 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin"
+                           ]
+                        },
                         "protected" : 1,
                         "proxyto" : "master",
                         "returns" : {
@@ -3148,6 +4109,12 @@ var pmgapi = [
                   "parameters" : {
                      "additionalProperties" : 0
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin",
+                        "audit"
+                     ]
+                  },
                   "returns" : {
                      "items" : {
                         "properties" : {},
@@ -3199,6 +4166,11 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin"
+                                 ]
+                              },
                               "proxyto" : "master",
                               "returns" : {
                                  "type" : "null"
@@ -3218,6 +4190,12 @@ var pmgapi = [
                         "parameters" : {
                            "additionalProperties" : 0
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "proxyto" : "master",
                         "returns" : {
                            "items" : {
@@ -3955,6 +4933,12 @@ var pmgapi = [
                   "parameters" : {
                      "additionalProperties" : 0
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin",
+                        "audit"
+                     ]
+                  },
                   "returns" : {
                      "items" : {
                         "properties" : {
@@ -4015,8 +4999,9 @@ var pmgapi = [
                                  "additionalProperties" : 0,
                                  "properties" : {
                                     "accountattr" : {
-                                       "default" : "sAMAccountName",
+                                       "default" : "sAMAccountName, uid",
                                        "description" : "Account attribute name name.",
+                                       "format" : "string-list",
                                        "optional" : 1,
                                        "pattern" : "[a-zA-Z0-9]+",
                                        "type" : "string"
@@ -4079,6 +5064,14 @@ var pmgapi = [
                                        "type" : "string",
                                        "typetext" : "<string>"
                                     },
+                                    "groupclass" : {
+                                       "default" : "group, univentionGroup, ipausergroup",
+                                       "description" : "List of objectclasses for groups.",
+                                       "format" : "string-list",
+                                       "optional" : 1,
+                                       "type" : "string",
+                                       "typetext" : "<string>"
+                                    },
                                     "mailattr" : {
                                        "default" : "mail, userPrincipalName, proxyAddresses, othermailbox",
                                        "description" : "List of mail attribute names.",
@@ -4270,6 +5263,12 @@ var pmgapi = [
                                     },
                                     "type" : "object"
                                  },
+                                 "links" : [
+                                    {
+                                       "href" : "{pmail}",
+                                       "rel" : "child"
+                                    }
+                                 ],
                                  "type" : "array"
                               }
                            }
@@ -4279,6 +5278,60 @@ var pmgapi = [
                         "text" : "users"
                      },
                      {
+                        "children" : [
+                           {
+                              "info" : {
+                                 "GET" : {
+                                    "description" : "List LDAP group members.",
+                                    "method" : "GET",
+                                    "name" : "profile_list_group_members",
+                                    "parameters" : {
+                                       "additionalProperties" : 0,
+                                       "properties" : {
+                                          "gid" : {
+                                             "description" : "Group ID",
+                                             "type" : "number",
+                                             "typetext" : "<number>"
+                                          },
+                                          "profile" : {
+                                             "description" : "Profile ID.",
+                                             "format" : "pve-configid",
+                                             "type" : "string",
+                                             "typetext" : "<string>"
+                                          }
+                                       }
+                                    },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
+                                    "protected" : 1,
+                                    "proxyto" : "master",
+                                    "returns" : {
+                                       "items" : {
+                                          "properties" : {
+                                             "account" : {
+                                                "type" : "string"
+                                             },
+                                             "dn" : {
+                                                "type" : "string"
+                                             },
+                                             "pmail" : {
+                                                "type" : "string"
+                                             }
+                                          },
+                                          "type" : "object"
+                                       },
+                                       "type" : "array"
+                                    }
+                                 }
+                              },
+                              "leaf" : 1,
+                              "path" : "/config/ldap/{profile}/groups/{gid}",
+                              "text" : "{gid}"
+                           }
+                        ],
                         "info" : {
                            "GET" : {
                               "description" : "List LDAP groups.",
@@ -4307,15 +5360,24 @@ var pmgapi = [
                                     "properties" : {
                                        "dn" : {
                                           "type" : "string"
+                                       },
+                                       "gid" : {
+                                          "type" : "number"
                                        }
                                     },
                                     "type" : "object"
                                  },
+                                 "links" : [
+                                    {
+                                       "href" : "{gid}",
+                                       "rel" : "child"
+                                    }
+                                 ],
                                  "type" : "array"
                               }
                            }
                         },
-                        "leaf" : 1,
+                        "leaf" : 0,
                         "path" : "/config/ldap/{profile}/groups",
                         "text" : "groups"
                      }
@@ -4458,8 +5520,9 @@ var pmgapi = [
                      "additionalProperties" : 0,
                      "properties" : {
                         "accountattr" : {
-                           "default" : "sAMAccountName",
+                           "default" : "sAMAccountName, uid",
                            "description" : "Account attribute name name.",
+                           "format" : "string-list",
                            "optional" : 1,
                            "pattern" : "[a-zA-Z0-9]+",
                            "type" : "string"
@@ -4507,6 +5570,14 @@ var pmgapi = [
                            "type" : "string",
                            "typetext" : "<string>"
                         },
+                        "groupclass" : {
+                           "default" : "group, univentionGroup, ipausergroup",
+                           "description" : "List of objectclasses for groups.",
+                           "format" : "string-list",
+                           "optional" : 1,
+                           "type" : "string",
+                           "typetext" : "<string>"
+                        },
                         "mailattr" : {
                            "default" : "mail, userPrincipalName, proxyAddresses, othermailbox",
                            "description" : "List of mail attribute names.",
@@ -4525,38 +5596,212 @@ var pmgapi = [
                            "optional" : 1,
                            "type" : "string"
                         },
-                        "port" : {
-                           "description" : "Specify the port to connect to.",
-                           "maximum" : 65535,
-                           "minimum" : 1,
-                           "optional" : 1,
-                           "type" : "integer",
-                           "typetext" : "<integer> (1 - 65535)"
+                        "port" : {
+                           "description" : "Specify the port to connect to.",
+                           "maximum" : 65535,
+                           "minimum" : 1,
+                           "optional" : 1,
+                           "type" : "integer",
+                           "typetext" : "<integer> (1 - 65535)"
+                        },
+                        "profile" : {
+                           "description" : "Profile ID.",
+                           "format" : "pve-configid",
+                           "type" : "string",
+                           "typetext" : "<string>"
+                        },
+                        "server1" : {
+                           "description" : "Server address.",
+                           "format" : "address",
+                           "maxLength" : 256,
+                           "optional" : 0,
+                           "type" : "string",
+                           "typetext" : "<string>"
+                        },
+                        "server2" : {
+                           "description" : "Fallback server address. Userd when the first server is not available.",
+                           "format" : "address",
+                           "maxLength" : 256,
+                           "optional" : 1,
+                           "type" : "string",
+                           "typetext" : "<string>"
+                        }
+                     },
+                     "type" : "object"
+                  },
+                  "permissions" : {
+                     "check" : [
+                        "admin"
+                     ]
+                  },
+                  "protected" : 1,
+                  "proxyto" : "master",
+                  "returns" : {
+                     "type" : "null"
+                  }
+               }
+            },
+            "leaf" : 0,
+            "path" : "/config/ldap",
+            "text" : "ldap"
+         },
+         {
+            "children" : [
+               {
+                  "info" : {
+                     "DELETE" : {
+                        "description" : "Delete a relay domain",
+                        "method" : "DELETE",
+                        "name" : "delete",
+                        "parameters" : {
+                           "additionalProperties" : 0,
+                           "properties" : {
+                              "domain" : {
+                                 "description" : "Domain name.",
+                                 "format" : "dns-name",
+                                 "type" : "string",
+                                 "typetext" : "<string>"
+                              }
+                           }
+                        },
+                        "permissions" : {
+                           "check" : [
+                              "admin"
+                           ]
+                        },
+                        "protected" : 1,
+                        "proxyto" : "master",
+                        "returns" : {
+                           "type" : "null"
+                        }
+                     },
+                     "GET" : {
+                        "description" : "Read Domain data (comment).",
+                        "method" : "GET",
+                        "name" : "read",
+                        "parameters" : {
+                           "additionalProperties" : 0,
+                           "properties" : {
+                              "domain" : {
+                                 "description" : "Domain name.",
+                                 "format" : "dns-name",
+                                 "type" : "string",
+                                 "typetext" : "<string>"
+                              }
+                           }
+                        },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
+                        "proxyto" : "master",
+                        "returns" : {
+                           "properties" : {
+                              "comment" : {
+                                 "type" : "string"
+                              },
+                              "domain" : {
+                                 "type" : "string"
+                              }
+                           },
+                           "type" : "object"
+                        }
+                     },
+                     "PUT" : {
+                        "description" : "Update relay domain data (comment).",
+                        "method" : "PUT",
+                        "name" : "write",
+                        "parameters" : {
+                           "additionalProperties" : 0,
+                           "properties" : {
+                              "comment" : {
+                                 "description" : "Comment.",
+                                 "type" : "string",
+                                 "typetext" : "<string>"
+                              },
+                              "domain" : {
+                                 "description" : "Domain name.",
+                                 "format" : "dns-name",
+                                 "type" : "string",
+                                 "typetext" : "<string>"
+                              }
+                           }
+                        },
+                        "permissions" : {
+                           "check" : [
+                              "admin"
+                           ]
                         },
-                        "profile" : {
-                           "description" : "Profile ID.",
-                           "format" : "pve-configid",
-                           "type" : "string",
-                           "typetext" : "<string>"
+                        "protected" : 1,
+                        "proxyto" : "master",
+                        "returns" : {
+                           "type" : "null"
+                        }
+                     }
+                  },
+                  "leaf" : 1,
+                  "path" : "/config/domains/{domain}",
+                  "text" : "{domain}"
+               }
+            ],
+            "info" : {
+               "GET" : {
+                  "description" : "List relay domains.",
+                  "method" : "GET",
+                  "name" : "index",
+                  "parameters" : {
+                     "additionalProperties" : 0
+                  },
+                  "permissions" : {
+                     "check" : [
+                        "admin",
+                        "audit"
+                     ]
+                  },
+                  "proxyto" : "master",
+                  "returns" : {
+                     "items" : {
+                        "properties" : {
+                           "comment" : {
+                              "type" : "string"
+                           },
+                           "domain" : {
+                              "type" : "string"
+                           }
                         },
-                        "server1" : {
-                           "description" : "Server address.",
-                           "format" : "address",
-                           "maxLength" : 256,
-                           "optional" : 0,
+                        "type" : "object"
+                     },
+                     "links" : [
+                        {
+                           "href" : "{domain}",
+                           "rel" : "child"
+                        }
+                     ],
+                     "type" : "array"
+                  }
+               },
+               "POST" : {
+                  "description" : "Add relay domain.",
+                  "method" : "POST",
+                  "name" : "create",
+                  "parameters" : {
+                     "additionalProperties" : 0,
+                     "properties" : {
+                        "comment" : {
+                           "description" : "Comment.",
+                           "optional" : 1,
                            "type" : "string",
                            "typetext" : "<string>"
                         },
-                        "server2" : {
-                           "description" : "Fallback server address. Userd when the first server is not available.",
-                           "format" : "address",
-                           "maxLength" : 256,
-                           "optional" : 1,
+                        "domain" : {
+                           "description" : "Domain name.",
+                           "format" : "dns-name",
                            "type" : "string",
                            "typetext" : "<string>"
                         }
-                     },
-                     "type" : "object"
+                     }
                   },
                   "permissions" : {
                      "check" : [
@@ -4571,28 +5816,33 @@ var pmgapi = [
                }
             },
             "leaf" : 0,
-            "path" : "/config/ldap",
-            "text" : "ldap"
+            "path" : "/config/domains",
+            "text" : "domains"
          },
          {
             "children" : [
                {
                   "info" : {
                      "DELETE" : {
-                        "description" : "Delete a relay domain",
+                        "description" : "Delete a fetchmail configuration entry.",
                         "method" : "DELETE",
                         "name" : "delete",
                         "parameters" : {
                            "additionalProperties" : 0,
                            "properties" : {
-                              "domain" : {
-                                 "description" : "Domain name.",
-                                 "format" : "dns-name",
-                                 "type" : "string",
-                                 "typetext" : "<string>"
+                              "id" : {
+                                 "description" : "Unique ID",
+                                 "maxLength" : 16,
+                                 "pattern" : "[A-Za-z0-9]+",
+                                 "type" : "string"
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin"
+                           ]
+                        },
                         "protected" : 1,
                         "proxyto" : "master",
                         "returns" : {
@@ -4600,27 +5850,102 @@ var pmgapi = [
                         }
                      },
                      "GET" : {
-                        "description" : "Read Domain data (comment).",
+                        "description" : "Read fetchmail user configuration.",
                         "method" : "GET",
                         "name" : "read",
                         "parameters" : {
                            "additionalProperties" : 0,
                            "properties" : {
-                              "domain" : {
-                                 "description" : "Domain name.",
-                                 "format" : "dns-name",
-                                 "type" : "string",
-                                 "typetext" : "<string>"
+                              "id" : {
+                                 "description" : "Unique ID",
+                                 "maxLength" : 16,
+                                 "pattern" : "[A-Za-z0-9]+",
+                                 "type" : "string"
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
+                        "protected" : 1,
                         "proxyto" : "master",
                         "returns" : {
                            "properties" : {
-                              "comment" : {
+                              "enable" : {
+                                 "default" : 0,
+                                 "description" : "Flag to enable or disable polling.",
+                                 "optional" : 1,
+                                 "type" : "boolean"
+                              },
+                              "id" : {
+                                 "description" : "Unique ID",
+                                 "maxLength" : 16,
+                                 "pattern" : "[A-Za-z0-9]+",
                                  "type" : "string"
                               },
-                              "domain" : {
+                              "interval" : {
+                                 "description" : "Only check this site every <interval> poll cycles. A poll cycle is 5 minutes.",
+                                 "maximum" : 2016,
+                                 "minimum" : 1,
+                                 "optional" : 1,
+                                 "type" : "integer"
+                              },
+                              "keep" : {
+                                 "default" : 0,
+                                 "description" : "Keep retrieved messages on the remote mailserver.",
+                                 "optional" : 1,
+                                 "type" : "boolean"
+                              },
+                              "pass" : {
+                                 "description" : "The password used tfor server login.",
+                                 "maxLength" : 64,
+                                 "optional" : 1,
+                                 "type" : "string"
+                              },
+                              "port" : {
+                                 "description" : "Port number.",
+                                 "maximum" : 65535,
+                                 "minimum" : 1,
+                                 "optional" : 1,
+                                 "type" : "integer"
+                              },
+                              "protocol" : {
+                                 "description" : "Specify  the  protocol to use when communicating with the remote mailserver",
+                                 "enum" : [
+                                    "pop3",
+                                    "imap"
+                                 ],
+                                 "optional" : 1,
+                                 "type" : "string"
+                              },
+                              "server" : {
+                                 "description" : "Server address (IP or DNS name).",
+                                 "format" : "address",
+                                 "optional" : 1,
+                                 "type" : "string"
+                              },
+                              "ssl" : {
+                                 "default" : 0,
+                                 "description" : "Use SSL.",
+                                 "optional" : 1,
+                                 "type" : "boolean"
+                              },
+                              "target" : {
+                                 "description" : "The target email address (where to deliver fetched mails).",
+                                 "maxLength" : 512,
+                                 "minLength" : 3,
+                                 "optional" : 1,
+                                 "pattern" : "(?:|[^\\s\\/\\@]+\\@[^\\s\\/\\@]+)",
+                                 "type" : "string"
+                              },
+                              "user" : {
+                                 "description" : "The user identification to be used when logging in to the server",
+                                 "maxLength" : 64,
+                                 "minLength" : 1,
+                                 "optional" : 1,
                                  "type" : "string"
                               }
                            },
@@ -4628,25 +5953,101 @@ var pmgapi = [
                         }
                      },
                      "PUT" : {
-                        "description" : "Update relay domain data (comment).",
+                        "description" : "Update fetchmail user configuration.",
                         "method" : "PUT",
                         "name" : "write",
                         "parameters" : {
                            "additionalProperties" : 0,
                            "properties" : {
-                              "comment" : {
-                                 "description" : "Comment.",
+                              "enable" : {
+                                 "default" : 0,
+                                 "description" : "Flag to enable or disable polling.",
+                                 "optional" : 1,
+                                 "type" : "boolean",
+                                 "typetext" : "<boolean>"
+                              },
+                              "id" : {
+                                 "description" : "Unique ID",
+                                 "maxLength" : 16,
+                                 "pattern" : "[A-Za-z0-9]+",
+                                 "type" : "string"
+                              },
+                              "interval" : {
+                                 "description" : "Only check this site every <interval> poll cycles. A poll cycle is 5 minutes.",
+                                 "maximum" : 2016,
+                                 "minimum" : 1,
+                                 "optional" : 1,
+                                 "type" : "integer",
+                                 "typetext" : "<integer> (1 - 2016)"
+                              },
+                              "keep" : {
+                                 "default" : 0,
+                                 "description" : "Keep retrieved messages on the remote mailserver.",
+                                 "optional" : 1,
+                                 "type" : "boolean",
+                                 "typetext" : "<boolean>"
+                              },
+                              "pass" : {
+                                 "description" : "The password used tfor server login.",
+                                 "maxLength" : 64,
+                                 "optional" : 1,
                                  "type" : "string",
                                  "typetext" : "<string>"
                               },
-                              "domain" : {
-                                 "description" : "Domain name.",
-                                 "format" : "dns-name",
+                              "port" : {
+                                 "description" : "Port number.",
+                                 "maximum" : 65535,
+                                 "minimum" : 1,
+                                 "optional" : 1,
+                                 "type" : "integer",
+                                 "typetext" : "<integer> (1 - 65535)"
+                              },
+                              "protocol" : {
+                                 "description" : "Specify  the  protocol to use when communicating with the remote mailserver",
+                                 "enum" : [
+                                    "pop3",
+                                    "imap"
+                                 ],
+                                 "optional" : 1,
+                                 "type" : "string"
+                              },
+                              "server" : {
+                                 "description" : "Server address (IP or DNS name).",
+                                 "format" : "address",
+                                 "optional" : 1,
+                                 "type" : "string",
+                                 "typetext" : "<string>"
+                              },
+                              "ssl" : {
+                                 "default" : 0,
+                                 "description" : "Use SSL.",
+                                 "optional" : 1,
+                                 "type" : "boolean",
+                                 "typetext" : "<boolean>"
+                              },
+                              "target" : {
+                                 "description" : "The target email address (where to deliver fetched mails).",
+                                 "maxLength" : 512,
+                                 "minLength" : 3,
+                                 "optional" : 1,
+                                 "pattern" : "(?:|[^\\s\\/\\@]+\\@[^\\s\\/\\@]+)",
+                                 "type" : "string"
+                              },
+                              "user" : {
+                                 "description" : "The user identification to be used when logging in to the server",
+                                 "maxLength" : 64,
+                                 "minLength" : 1,
+                                 "optional" : 1,
                                  "type" : "string",
                                  "typetext" : "<string>"
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin"
+                           ]
+                        },
                         "protected" : 1,
                         "proxyto" : "master",
                         "returns" : {
@@ -4655,26 +6056,101 @@ var pmgapi = [
                      }
                   },
                   "leaf" : 1,
-                  "path" : "/config/domains/{domain}",
-                  "text" : "{domain}"
+                  "path" : "/config/fetchmail/{id}",
+                  "text" : "{id}"
                }
             ],
             "info" : {
                "GET" : {
-                  "description" : "List relay domains.",
+                  "description" : "List fetchmail users.",
                   "method" : "GET",
                   "name" : "index",
                   "parameters" : {
                      "additionalProperties" : 0
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin",
+                        "audit"
+                     ]
+                  },
+                  "protected" : 1,
                   "proxyto" : "master",
                   "returns" : {
                      "items" : {
                         "properties" : {
-                           "comment" : {
+                           "enable" : {
+                              "default" : 0,
+                              "description" : "Flag to enable or disable polling.",
+                              "optional" : 1,
+                              "type" : "boolean"
+                           },
+                           "id" : {
+                              "description" : "Unique ID",
+                              "maxLength" : 16,
+                              "pattern" : "[A-Za-z0-9]+",
+                              "type" : "string"
+                           },
+                           "interval" : {
+                              "description" : "Only check this site every <interval> poll cycles. A poll cycle is 5 minutes.",
+                              "maximum" : 2016,
+                              "minimum" : 1,
+                              "optional" : 1,
+                              "type" : "integer"
+                           },
+                           "keep" : {
+                              "default" : 0,
+                              "description" : "Keep retrieved messages on the remote mailserver.",
+                              "optional" : 1,
+                              "type" : "boolean"
+                           },
+                           "pass" : {
+                              "description" : "The password used tfor server login.",
+                              "maxLength" : 64,
+                              "optional" : 1,
                               "type" : "string"
                            },
-                           "domain" : {
+                           "port" : {
+                              "description" : "Port number.",
+                              "maximum" : 65535,
+                              "minimum" : 1,
+                              "optional" : 1,
+                              "type" : "integer"
+                           },
+                           "protocol" : {
+                              "description" : "Specify  the  protocol to use when communicating with the remote mailserver",
+                              "enum" : [
+                                 "pop3",
+                                 "imap"
+                              ],
+                              "optional" : 1,
+                              "type" : "string"
+                           },
+                           "server" : {
+                              "description" : "Server address (IP or DNS name).",
+                              "format" : "address",
+                              "optional" : 1,
+                              "type" : "string"
+                           },
+                           "ssl" : {
+                              "default" : 0,
+                              "description" : "Use SSL.",
+                              "optional" : 1,
+                              "type" : "boolean"
+                           },
+                           "target" : {
+                              "description" : "The target email address (where to deliver fetched mails).",
+                              "maxLength" : 512,
+                              "minLength" : 3,
+                              "optional" : 1,
+                              "pattern" : "(?:|[^\\s\\/\\@]+\\@[^\\s\\/\\@]+)",
+                              "type" : "string"
+                           },
+                           "user" : {
+                              "description" : "The user identification to be used when logging in to the server",
+                              "maxLength" : 64,
+                              "minLength" : 1,
+                              "optional" : 1,
                               "type" : "string"
                            }
                         },
@@ -4682,7 +6158,7 @@ var pmgapi = [
                      },
                      "links" : [
                         {
-                           "href" : "{domain}",
+                           "href" : "{id}",
                            "rel" : "child"
                         }
                      ],
@@ -4690,36 +6166,103 @@ var pmgapi = [
                   }
                },
                "POST" : {
-                  "description" : "Add relay domain.",
+                  "description" : "Create fetchmail user configuration.",
                   "method" : "POST",
                   "name" : "create",
                   "parameters" : {
                      "additionalProperties" : 0,
                      "properties" : {
-                        "comment" : {
-                           "description" : "Comment.",
+                        "enable" : {
+                           "default" : 0,
+                           "description" : "Flag to enable or disable polling.",
                            "optional" : 1,
+                           "type" : "boolean",
+                           "typetext" : "<boolean>"
+                        },
+                        "interval" : {
+                           "description" : "Only check this site every <interval> poll cycles. A poll cycle is 5 minutes.",
+                           "maximum" : 2016,
+                           "minimum" : 1,
+                           "optional" : 1,
+                           "type" : "integer",
+                           "typetext" : "<integer> (1 - 2016)"
+                        },
+                        "keep" : {
+                           "default" : 0,
+                           "description" : "Keep retrieved messages on the remote mailserver.",
+                           "optional" : 1,
+                           "type" : "boolean",
+                           "typetext" : "<boolean>"
+                        },
+                        "pass" : {
+                           "description" : "The password used tfor server login.",
+                           "maxLength" : 64,
                            "type" : "string",
                            "typetext" : "<string>"
                         },
-                        "domain" : {
-                           "description" : "Domain name.",
-                           "format" : "dns-name",
+                        "port" : {
+                           "description" : "Port number.",
+                           "maximum" : 65535,
+                           "minimum" : 1,
+                           "optional" : 1,
+                           "type" : "integer",
+                           "typetext" : "<integer> (1 - 65535)"
+                        },
+                        "protocol" : {
+                           "description" : "Specify  the  protocol to use when communicating with the remote mailserver",
+                           "enum" : [
+                              "pop3",
+                              "imap"
+                           ],
+                           "type" : "string"
+                        },
+                        "server" : {
+                           "description" : "Server address (IP or DNS name).",
+                           "format" : "address",
+                           "type" : "string",
+                           "typetext" : "<string>"
+                        },
+                        "ssl" : {
+                           "default" : 0,
+                           "description" : "Use SSL.",
+                           "optional" : 1,
+                           "type" : "boolean",
+                           "typetext" : "<boolean>"
+                        },
+                        "target" : {
+                           "description" : "The target email address (where to deliver fetched mails).",
+                           "maxLength" : 512,
+                           "minLength" : 3,
+                           "pattern" : "(?:|[^\\s\\/\\@]+\\@[^\\s\\/\\@]+)",
+                           "type" : "string"
+                        },
+                        "user" : {
+                           "description" : "The user identification to be used when logging in to the server",
+                           "maxLength" : 64,
+                           "minLength" : 1,
                            "type" : "string",
                            "typetext" : "<string>"
                         }
                      }
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin"
+                     ]
+                  },
                   "protected" : 1,
                   "proxyto" : "master",
                   "returns" : {
-                     "type" : "null"
+                     "description" : "Unique ID",
+                     "maxLength" : 16,
+                     "pattern" : "[A-Za-z0-9]+",
+                     "type" : "string"
                   }
                }
             },
             "leaf" : 0,
-            "path" : "/config/domains",
-            "text" : "domains"
+            "path" : "/config/fetchmail",
+            "text" : "fetchmail"
          },
          {
             "children" : [
@@ -4740,6 +6283,11 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin"
+                           ]
+                        },
                         "protected" : 1,
                         "proxyto" : "master",
                         "returns" : {
@@ -4761,6 +6309,12 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "proxyto" : "master",
                         "returns" : {
                            "properties" : {
@@ -4825,6 +6379,11 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin"
+                           ]
+                        },
                         "protected" : 1,
                         "proxyto" : "master",
                         "returns" : {
@@ -4845,6 +6404,12 @@ var pmgapi = [
                   "parameters" : {
                      "additionalProperties" : 0
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin",
+                        "audit"
+                     ]
+                  },
                   "proxyto" : "master",
                   "returns" : {
                      "items" : {
@@ -4919,6 +6484,11 @@ var pmgapi = [
                         }
                      }
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin"
+                     ]
+                  },
                   "protected" : 1,
                   "proxyto" : "master",
                   "returns" : {
@@ -4949,6 +6519,11 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin"
+                           ]
+                        },
                         "protected" : 1,
                         "proxyto" : "master",
                         "returns" : {
@@ -4970,6 +6545,12 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "proxyto" : "master",
                         "returns" : {
                            "properties" : {
@@ -5002,6 +6583,11 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin"
+                           ]
+                        },
                         "protected" : 1,
                         "proxyto" : "master",
                         "returns" : {
@@ -5022,6 +6608,12 @@ var pmgapi = [
                   "parameters" : {
                      "additionalProperties" : 0
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin",
+                        "audit"
+                     ]
+                  },
                   "proxyto" : "master",
                   "returns" : {
                      "items" : {
@@ -5062,6 +6654,11 @@ var pmgapi = [
                         }
                      }
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin"
+                     ]
+                  },
                   "protected" : 1,
                   "proxyto" : "master",
                   "returns" : {
@@ -5375,6 +6972,12 @@ var pmgapi = [
                   "parameters" : {
                      "additionalProperties" : 0
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin",
+                        "audit"
+                     ]
+                  },
                   "proxyto" : "master",
                   "returns" : {
                      "type" : "object"
@@ -5448,6 +7051,11 @@ var pmgapi = [
                      },
                      "type" : "object"
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin"
+                     ]
+                  },
                   "protected" : 1,
                   "proxyto" : "master",
                   "returns" : {
@@ -5468,6 +7076,12 @@ var pmgapi = [
                   "parameters" : {
                      "additionalProperties" : 0
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin",
+                        "audit"
+                     ]
+                  },
                   "proxyto" : "master",
                   "returns" : {
                      "type" : "object"
@@ -5559,6 +7173,11 @@ var pmgapi = [
                      },
                      "type" : "object"
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin"
+                     ]
+                  },
                   "protected" : 1,
                   "proxyto" : "master",
                   "returns" : {
@@ -5579,6 +7198,12 @@ var pmgapi = [
                   "parameters" : {
                      "additionalProperties" : 0
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin",
+                        "audit"
+                     ]
+                  },
                   "proxyto" : "master",
                   "returns" : {
                      "type" : "object"
@@ -5826,6 +7451,11 @@ var pmgapi = [
                      },
                      "type" : "object"
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin"
+                     ]
+                  },
                   "protected" : 1,
                   "proxyto" : "master",
                   "returns" : {
@@ -5846,6 +7476,12 @@ var pmgapi = [
                   "parameters" : {
                      "additionalProperties" : 0
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin",
+                        "audit"
+                     ]
+                  },
                   "proxyto" : "master",
                   "returns" : {
                      "type" : "object"
@@ -5934,6 +7570,11 @@ var pmgapi = [
                      },
                      "type" : "object"
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin"
+                     ]
+                  },
                   "protected" : 1,
                   "proxyto" : "master",
                   "returns" : {
@@ -5954,6 +7595,12 @@ var pmgapi = [
                   "parameters" : {
                      "additionalProperties" : 0
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin",
+                        "audit"
+                     ]
+                  },
                   "proxyto" : "master",
                   "returns" : {
                      "type" : "object"
@@ -6042,6 +7689,11 @@ var pmgapi = [
                      },
                      "type" : "object"
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin"
+                     ]
+                  },
                   "protected" : 1,
                   "proxyto" : "master",
                   "returns" : {
@@ -6062,6 +7714,12 @@ var pmgapi = [
                   "parameters" : {
                      "additionalProperties" : 0
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin",
+                        "audit"
+                     ]
+                  },
                   "proxyto" : "master",
                   "returns" : {
                      "type" : "object"
@@ -6114,6 +7772,11 @@ var pmgapi = [
                      },
                      "type" : "object"
                   },
+                  "permissions" : {
+                     "check" : [
+                        "admin"
+                     ]
+                  },
                   "protected" : 1,
                   "proxyto" : "master",
                   "returns" : {
@@ -6234,7 +7897,8 @@ var pmgapi = [
                               },
                               "permissions" : {
                                  "check" : [
-                                    "admin"
+                                    "admin",
+                                    "audit"
                                  ]
                               },
                               "protected" : 1,
@@ -6490,7 +8154,8 @@ var pmgapi = [
                                     },
                                     "permissions" : {
                                        "check" : [
-                                          "admin"
+                                          "admin",
+                                          "audit"
                                        ]
                                     },
                                     "protected" : 1,
@@ -6844,6 +8509,12 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin",
+                                    "audit"
+                                 ]
+                              },
                               "proxyto" : "node",
                               "returns" : {
                                  "properties" : {
@@ -7117,6 +8788,12 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "proxyto" : "node",
                         "returns" : {
                            "items" : {
@@ -7367,6 +9044,12 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "node",
                                     "returns" : {
@@ -7412,6 +9095,12 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "node",
                                     "returns" : {
@@ -7456,6 +9145,11 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin"
+                                 ]
+                              },
                               "protected" : 1,
                               "proxyto" : "node",
                               "returns" : {
@@ -7481,6 +9175,12 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin",
+                                    "audit"
+                                 ]
+                              },
                               "returns" : {
                                  "items" : {
                                     "properties" : {},
@@ -7539,6 +9239,12 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "proxyto" : "node",
                         "returns" : {
                            "items" : {
@@ -7587,6 +9293,7 @@ var pmgapi = [
                                              "enum" : [
                                                 "clamav-daemon",
                                                 "clamav-freshclam",
+                                                "fetchmail",
                                                 "pmgproxy",
                                                 "pmgdaemon",
                                                 "pmgpolicy",
@@ -7607,6 +9314,12 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin",
+                                          "audit"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "node",
                                     "returns" : {
@@ -7639,6 +9352,7 @@ var pmgapi = [
                                              "enum" : [
                                                 "clamav-daemon",
                                                 "clamav-freshclam",
+                                                "fetchmail",
                                                 "pmgproxy",
                                                 "pmgdaemon",
                                                 "pmgpolicy",
@@ -7659,6 +9373,11 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "node",
                                     "returns" : {
@@ -7690,6 +9409,7 @@ var pmgapi = [
                                              "enum" : [
                                                 "clamav-daemon",
                                                 "clamav-freshclam",
+                                                "fetchmail",
                                                 "pmgproxy",
                                                 "pmgdaemon",
                                                 "pmgpolicy",
@@ -7710,6 +9430,11 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "node",
                                     "returns" : {
@@ -7741,6 +9466,7 @@ var pmgapi = [
                                              "enum" : [
                                                 "clamav-daemon",
                                                 "clamav-freshclam",
+                                                "fetchmail",
                                                 "pmgproxy",
                                                 "pmgdaemon",
                                                 "pmgpolicy",
@@ -7761,6 +9487,11 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "node",
                                     "returns" : {
@@ -7792,6 +9523,7 @@ var pmgapi = [
                                              "enum" : [
                                                 "clamav-daemon",
                                                 "clamav-freshclam",
+                                                "fetchmail",
                                                 "pmgproxy",
                                                 "pmgdaemon",
                                                 "pmgpolicy",
@@ -7812,6 +9544,11 @@ var pmgapi = [
                                           }
                                        }
                                     },
+                                    "permissions" : {
+                                       "check" : [
+                                          "admin"
+                                       ]
+                                    },
                                     "protected" : 1,
                                     "proxyto" : "node",
                                     "returns" : {
@@ -7843,6 +9580,7 @@ var pmgapi = [
                                        "enum" : [
                                           "clamav-daemon",
                                           "clamav-freshclam",
+                                          "fetchmail",
                                           "pmgproxy",
                                           "pmgdaemon",
                                           "pmgpolicy",
@@ -7863,6 +9601,12 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin",
+                                    "audit"
+                                 ]
+                              },
                               "returns" : {
                                  "items" : {
                                     "properties" : {
@@ -7903,6 +9647,12 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "protected" : 1,
                         "proxyto" : "node",
                         "returns" : {
@@ -7953,6 +9703,66 @@ var pmgapi = [
                         "returns" : {
                            "type" : "object"
                         }
+                     },
+                     "POST" : {
+                        "description" : "Update subscription info.",
+                        "method" : "POST",
+                        "name" : "update",
+                        "parameters" : {
+                           "additionalProperties" : 0,
+                           "properties" : {
+                              "force" : {
+                                 "default" : 0,
+                                 "description" : "Always connect to server, even if we have up to date info inside local cache.",
+                                 "optional" : 1,
+                                 "type" : "boolean",
+                                 "typetext" : "<boolean>"
+                              },
+                              "node" : {
+                                 "description" : "The cluster node name.",
+                                 "format" : "pve-node",
+                                 "type" : "string",
+                                 "typetext" : "<string>"
+                              }
+                           }
+                        },
+                        "permissions" : {
+                           "check" : [
+                              "admin"
+                           ]
+                        },
+                        "protected" : 1,
+                        "proxyto" : "node",
+                        "returns" : {
+                           "type" : "null"
+                        }
+                     },
+                     "PUT" : {
+                        "description" : "Set subscription key.",
+                        "method" : "PUT",
+                        "name" : "set",
+                        "parameters" : {
+                           "additionalProperties" : 0,
+                           "properties" : {
+                              "key" : {
+                                 "description" : "Proxmox Mail Gateway subscription key",
+                                 "maxLength" : 32,
+                                 "pattern" : "pmg([cbsp])-[0-9a-f]{10}",
+                                 "type" : "string"
+                              },
+                              "node" : {
+                                 "description" : "The cluster node name.",
+                                 "format" : "pve-node",
+                                 "type" : "string",
+                                 "typetext" : "<string>"
+                              }
+                           }
+                        },
+                        "protected" : 1,
+                        "proxyto" : "node",
+                        "returns" : {
+                           "type" : "null"
+                        }
                      }
                   },
                   "leaf" : 1,
@@ -7978,6 +9788,12 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin",
+                                    "audit"
+                                 ]
+                              },
                               "protected" : 1,
                               "proxyto" : "node",
                               "returns" : {
@@ -8017,6 +9833,11 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin"
+                                 ]
+                              },
                               "protected" : 1,
                               "proxyto" : "node",
                               "returns" : {
@@ -8056,6 +9877,12 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin",
+                                    "audit"
+                                 ]
+                              },
                               "proxyto" : "node",
                               "returns" : {
                                  "type" : "string"
@@ -8085,11 +9912,8 @@ var pmgapi = [
                               },
                               "permissions" : {
                                  "check" : [
-                                    "perm",
-                                    "/nodes/{node}",
-                                    [
-                                       "Sys.Audit"
-                                    ]
+                                    "admin",
+                                    "audit"
                                  ]
                               },
                               "proxyto" : "node",
@@ -8189,6 +10013,12 @@ var pmgapi = [
                                     }
                                  }
                               },
+                              "permissions" : {
+                                 "check" : [
+                                    "admin",
+                                    "audit"
+                                 ]
+                              },
                               "protected" : 1,
                               "proxyto" : "node",
                               "returns" : {
@@ -8331,6 +10161,12 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "protected" : 1,
                         "proxyto" : "node",
                         "returns" : {
@@ -8444,6 +10280,12 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "protected" : 1,
                         "proxyto" : "node",
                         "returns" : {
@@ -8507,6 +10349,12 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "protected" : 1,
                         "proxyto" : "node",
                         "returns" : {
@@ -8647,6 +10495,12 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "proxyto" : "node",
                         "returns" : {
                            "additionalProperties" : 0,
@@ -8744,6 +10598,12 @@ var pmgapi = [
                               }
                            }
                         },
+                        "permissions" : {
+                           "check" : [
+                              "admin",
+                              "audit"
+                           ]
+                        },
                         "proxyto" : "node",
                         "returns" : {
                            "additionalProperties" : 0,
@@ -9256,11 +11116,14 @@ var pmgapi = [
                         },
                         "realm" : {
                            "description" : "You can optionally pass the realm using this parameter. Normally the realm is simply added to the username <username>@<relam>.",
-                           "format" : "pmg-realm",
+                           "enum" : [
+                              "pam",
+                              "pmg",
+                              "quarantine"
+                           ],
                            "maxLength" : 32,
                            "optional" : 1,
-                           "type" : "string",
-                           "typetext" : "<string>"
+                           "type" : "string"
                         },
                         "username" : {
                            "description" : "User name",
@@ -11048,6 +12911,166 @@ var pmgapi = [
             "path" : "/statistics/mail",
             "text" : "mail"
          },
+         {
+            "info" : {
+               "GET" : {
+                  "description" : "Mail Count Statistics.",
+                  "method" : "GET",
+                  "name" : "recent",
+                  "parameters" : {
+                     "additionalProperties" : 0,
+                     "properties" : {
+                        "hours" : {
+                           "default" : 12,
+                           "description" : "How many hours you want to get",
+                           "maximum" : 24,
+                           "minimum" : 1,
+                           "optional" : 1,
+                           "type" : "integer",
+                           "typetext" : "<integer> (1 - 24)"
+                        },
+                        "timespan" : {
+                           "default" : 1800,
+                           "description" : "The Timespan for one datapoint (in seconds)",
+                           "maximum" : 1800,
+                           "minimum" : 1,
+                           "optional" : 1,
+                           "type" : "integer",
+                           "typetext" : "<integer> (1 - 1800)"
+                        }
+                     }
+                  },
+                  "permissions" : {
+                     "check" : [
+                        "admin",
+                        "qmanager",
+                        "audit"
+                     ]
+                  },
+                  "returns" : {
+                     "items" : {
+                        "properties" : {
+                           "bytes_in" : {
+                              "description" : "Number of incoming bytes mails.",
+                              "type" : "number"
+                           },
+                           "bytes_out" : {
+                              "description" : "Number of outgoing bytes mails.",
+                              "type" : "number"
+                           },
+                           "count" : {
+                              "description" : "Overall mail count (in and out).",
+                              "type" : "number"
+                           },
+                           "count_in" : {
+                              "description" : "Incoming mail count.",
+                              "type" : "number"
+                           },
+                           "count_out" : {
+                              "description" : "Outgoing mail count.",
+                              "type" : "number"
+                           },
+                           "index" : {
+                              "description" : "Time index.",
+                              "type" : "integer"
+                           },
+                           "spam" : {
+                              "description" : "Overall spam mail count (in and out).",
+                              "type" : "number"
+                           },
+                           "spam_in" : {
+                              "description" : "Incoming spam mails (spamcount_in + glcount + spfcount).",
+                              "type" : "number"
+                           },
+                           "spam_out" : {
+                              "description" : "Outgoing spam mails.",
+                              "type" : "number"
+                           },
+                           "time" : {
+                              "description" : "Time (Unix epoch).",
+                              "type" : "integer"
+                           },
+                           "timespan" : {
+                              "description" : "Timespan in seconds for one data point",
+                              "type" : "number"
+                           },
+                           "virus_in" : {
+                              "description" : "Number of incoming virus mails.",
+                              "type" : "number"
+                           },
+                           "virus_out" : {
+                              "description" : "Number of outgoing virus mails.",
+                              "type" : "number"
+                           }
+                        },
+                        "type" : "object"
+                     },
+                     "type" : "array"
+                  }
+               }
+            },
+            "leaf" : 1,
+            "path" : "/statistics/recent",
+            "text" : "recent"
+         },
+         {
+            "info" : {
+               "GET" : {
+                  "description" : "Top recent Mail Receivers (including spam)",
+                  "method" : "GET",
+                  "name" : "recentreceivers",
+                  "parameters" : {
+                     "additionalProperties" : 0,
+                     "properties" : {
+                        "hours" : {
+                           "default" : 12,
+                           "description" : "How many hours you want to get",
+                           "maximum" : 24,
+                           "minimum" : 1,
+                           "optional" : 1,
+                           "type" : "integer",
+                           "typetext" : "<integer> (1 - 24)"
+                        },
+                        "limit" : {
+                           "default" : 5,
+                           "description" : "The maximum number of receivers to return.",
+                           "maximum" : 50,
+                           "minimum" : 1,
+                           "optional" : 1,
+                           "type" : "integer",
+                           "typetext" : "<integer> (1 - 50)"
+                        }
+                     }
+                  },
+                  "permissions" : {
+                     "check" : [
+                        "admin",
+                        "qmanager",
+                        "audit"
+                     ]
+                  },
+                  "returns" : {
+                     "items" : {
+                        "properties" : {
+                           "count" : {
+                              "description" : "The count of incoming not blocked E-Mails",
+                              "type" : "integer"
+                           },
+                           "receiver" : {
+                              "description" : "The receiver",
+                              "type" : "string"
+                           }
+                        },
+                        "type" : "object"
+                     },
+                     "type" : "array"
+                  }
+               }
+            },
+            "leaf" : 1,
+            "path" : "/statistics/recentreceivers",
+            "text" : "recentreceivers"
+         },
          {
             "info" : {
                "GET" : {