nifi-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Matt Gilman <matt.c.gil...@gmail.com>
Subject Re: Updating users through Rest API
Date Fri, 04 Aug 2017 16:31:04 GMT
Karthik,

Group membership is managed through the group. So you would need to update
the group by adding the user identifier to the users list and 'PUT' that.
To see these requests in action, I would suggest opening the Developer
Tools of your browser as the UI uses the REST API exclusively.

Please let me know if you have any follow-up questions.

Thanks

Matt

On Fri, Aug 4, 2017 at 11:50 AM, Karthik Kothareddy (karthikk) [CONT - Type
2] <karthikk@micron.com> wrote:

> Hello All,
>
> I am trying to add/update users through REST API, I am using InvokeHTTP to
> do that, I tried simple addition of user with the below Json and it worked
> perfectly.
>
> {
>   "revision" : {
>     "version" : 0
>   },
>   "permissions" : {
>     "canRead" : true,
>     "canWrite" : false
>   },
>   "component" : {
>     "identity" : "testuser"
>   }
> }
>
> However, once the user is added I am trying to add him to the user groups
> that I have for my instance. I'm using the json that I got by querying a
> different user by (/tenants/users/{id}). I have updated all the UID in the
> returned json to match the other user and use this PUT /tenants/users/{id}
> for the update. It doesn't seem to have any effect on the "testuser", it
> still says he does not belong any group. Can anyone help me with some
> examples on how to effectively add/update users.
>
> Thanks for your time,
>
> -Karthik
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message