Groups API for Identity-Federated Workspaces

Following are changes to the Groups API for Identity-Federated Workspaces:

Add member (NOT SUPPORTED)

Method

POST

Endpoint

{workspace_domain}/api/2.0/groups/add-member

Request example

{

   "user_name": "someone@example.com",

   "parent_name": "group-name"

}

Response example

400:

{

   "error_code": "MALFORMED_REQUEST",

   "message": "Group membership cannot be updated as group-name can only be managed in account."

}

Create

Method

POST

Endpoint

{workspace_domain}/api/2.0/groups/create

Request example

{

   "group_name": "account-group"

}

Response example

200:

{

   "group_name": "account-group"

}

404:

{

   "error_code": "RESOURCE_DOES_NOT_EXIST",

   "message": "Account group with name 'new-group' does not exist"

}

List members

Method

GET

Endpoint

{workspace_domain}/api/2.0/groups/list-members

Request example

{

   "group_name": "group-name"

}

Response example

200:

{

   "members": [

       {

           "user_name": "user1@databricks.com"

       },

       {

           "user_name": "user2@databricks.com"

       },

       {

           "group_name": "group-name"

       }

   ]

}

List groups

Method

GET

Endpoint

{workspace_domain}/api/2.0/groups/list

Request example

Response example

200:

{

   "group_names": [

       "group-name-1",

       "group-name-2",

       "admins"

   ]

}

List parents

Method

POST

Endpoint

{workspace_domain}/api/2.0/groups/list-parents

Request example

{

   "user_name": "someone@example.com",

}

Response example

200:

{

   "group_names": [

       "group-name-1",

       "group-name-2",

       "admins"

   ]

}

Remove member (NOT SUPPORTED)

Method

POST

Endpoint

{workspace_domain}/api/2.0/groups/remove-member

Request example

{

   "user_name": "someone@example.com",

   "parent_name": "groupName"

}

Response example

400:

{

   "error_code": "MALFORMED_REQUEST",

   "message": "Group membership cannot be updated as 'groupName' can only be managed in account."

}

Delete

Method

POST

Endpoint

{workspace_domain}/api/2.0/groups/delete

Request example

{

   "group_name": "groupName"

}

Response example

200:

{}