Associating a Delphix User to the newly created VDB

  • 0
  • 1
  • Question
  • Updated 3 years ago
  • Answered
I am creating a Delphix via REST API. Once the VDB Created i need to associated the existing Delphix Users to the created vDB. Do we have any API Calls to associate the users to the newly created VDB. Thanks in Advance.
Photo of Ramesh

Ramesh

  • 518 Points 500 badge 2x thumb

Posted 3 years ago

  • 0
  • 1
Photo of Jatinder Luthra

Jatinder Luthra, Employee

  • 3,058 Points 3k badge 2x thumb
Official Response
Hello Ramesh,
                      Could you please provide clarity on what you mean by associate the Delphix Users to created VDB?

Are you looking forward to create new database users in newly created VDB?
Photo of Ramesh

Ramesh

  • 518 Points 500 badge 2x thumb
I am referring to User account where one can login to the Delphix GUI Portal.
(POST /resources/json/delphix/user). Assume that i created 10 users and after that i have created VDB, how to give permission to those 10 users on the newly created vdb to do jestream operation. 
How this is possible via API

Photo of Jatinder Luthra

Jatinder Luthra, Employee

  • 3,058 Points 3k badge 2x thumb
Hello Ramesh,
                      You can use below API to assign JetStream Role to specific user.

POST /resources/json/delphix/authorization

{

    "type": "Authorization",

    "role": "<JetStream_role_reference_number>",

    "target": "<user_reference_number>",

    "user": "<user_reference_number>"

}


To find JetStream_role_reference_number, login into Delphix CLI and run below command:

delphixEngine> role ls

Check for Role reference for Name, "Jet Stream User". Example: ROLE-3.


To find user_reference_number to which you want to assign Jet Stream Role,login into Delphix CLI and run below command:

delphixEngine> user list display=name,reference

Check for user reference for Name. Example: USER-72.


In my case, api call looks like below:

POST /resources/json/delphix/authorization

{

    "type": "Authorization",

    "role": "ROLE-3",

    "target": "USER-72",

    "user": "USER-72"

}

Hope this helps.
Photo of Jatinder Luthra

Jatinder Luthra, Employee

  • 3,058 Points 3k badge 2x thumb
Adding to last comment, on how to assign user to jet stream container, below api call will work:

POST /resources/json/delphix/jetstream/container/<JS_CONTAINER_REFERENCE>/addOwner

{

    "type": "JSDataContainerModifyOwnerParameters",

    "owner": "<USER_REFERENCE>"

}