X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=PLC%2FMethods%2FGetRoles.py;h=fb905e59774fa280ed1bbeb3f9a5042599a4e5dd;hb=bd0cbf4f7f2e4cf7ceda500bfa6f98c0a700018b;hp=1a2c19673c598fea490f716ad2031ee88129c292;hpb=a8e81964a7b22a0584667a0449604cccc895955a;p=plcapi.git diff --git a/PLC/Methods/GetRoles.py b/PLC/Methods/GetRoles.py index 1a2c196..fb905e5 100644 --- a/PLC/Methods/GetRoles.py +++ b/PLC/Methods/GetRoles.py @@ -2,20 +2,20 @@ from PLC.Faults import * from PLC.Method import Method from PLC.Parameter import Parameter, Mixed from PLC.Roles import Role, Roles -from PLC.Auth import PasswordAuth +from PLC.Auth import Auth class GetRoles(Method): """ Get an array of structs containing details about all roles. """ - roles = ['admin', 'pi', 'user', 'tech'] + roles = ['admin', 'pi', 'user', 'tech', 'node'] accepts = [ - PasswordAuth() + Auth() ] returns = [Role.fields] def call(self, auth): - return Roles(self.api).values() + return Roles(self.api)