Supplying multiple roles when creating an User
This is related to issue #32.
When creating a User you must provide a role too: admin or user for instance. As specified in http://docs.splunk.com/Documentation/Splunk/latest/RESTAPI/RESTaccess#authentication.2Fusers under the header "POST authentication/users" which describes creation of a user, you can also specify a list of roles:
"... To assign multiple roles, send them in separate roles parameters."
that means writing something like -d roles=admin -d roles=user. This obviously will not work in our python implementation seeing as we are using a dict. I tried experimenting with different ways of supplying both the roles in one -d roles=-option using & , ; and {}. [] but couldn't figure it out. So I assume you must supply separate roles options.
Do you guys have any idea of how to fix/work around this?
You should be able to pass an array. So services.users.create(..., roles=['admin', 'power'])
The answer was more obvious than I first believed, thank you Itay!