step2 : basic functions for handling nodetags and nodegroups - still highly volatile
[plcapi.git] / PLC / Methods / GetNodeGroups.py
index 38d0618..5711217 100644 (file)
@@ -14,19 +14,17 @@ class GetNodeGroups(Method):
     is specified, only the specified details will be returned.
     """
 
-    roles = ['admin', 'pi', 'user', 'tech']
+    roles = ['admin', 'pi', 'user', 'tech', 'node', 'anonymous']
 
     accepts = [
         Auth(),
         Mixed([Mixed(NodeGroup.fields['nodegroup_id'],
-                     NodeGroup.fields['name'])],
+                     NodeGroup.fields['groupname'])],
               Filter(NodeGroup.fields)),
         Parameter([str], "List of fields to return", nullok = True)
         ]
 
     returns = [NodeGroup.fields]
-    event_type = 'Get'
-    object_type = 'NodeGroup'
   
     def call(self, auth, nodegroup_filter = None, return_fields = None):
        return NodeGroups(self.api, nodegroup_filter, return_fields)