# RoleBinding

> **Package : spaceone.api.identity.v2**

\
\


## RoleBinding

**RoleBinding Methods:**

| Method                                                                                                                            | Request                                                                                                                                                | Response                                                                                                                               |
| --------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------ | -------------------------------------------------------------------------------------------------------------------------------------- |
| [**create**](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#create)            | [CreateRoleBindingRequest](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#createrolebindingrequest) | [RoleBindingInfo](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#rolebindinginfo)   |
| [**update\_role**](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#update_role) | [UpdateRoleBindingRequest](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#updaterolebindingrequest) | [RoleBindingInfo](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#rolebindinginfo)   |
| [**delete**](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#delete)            | [RoleBindingRequest](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#rolebindingrequest)             | [Empty](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#empty)                       |
| [**get**](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#get)                  | [RoleBindingRequest](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#rolebindingrequest)             | [RoleBindingInfo](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#rolebindinginfo)   |
| [**list**](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#list)                | [RoleBindingSearchQuery](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#rolebindingsearchquery)     | [RoleBindingsInfo](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#rolebindingsinfo) |
| [**stat**](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#stat)                | [RoleBindingStatQuery](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#rolebindingstatquery)         | [Struct](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#struct)                     |

\


### create

> **POST** /identity/v1/role-binding/create

\{{< tabs " create " >\}}

\{{< tab "Request Example" >\}}

[CreateRoleBindingRequest](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#createrolebindingrequest)

* **user\_id** (string) `Required`
* **role\_id** (string) `Required`
* **resource\_group** (ResourceGroup) `Required`
* **workspace\_id** (string)

\{{< highlight json >\}} { "user\_id": "wonny@cloudforet.io", "role\_id": "managed-workspace-owner", "resource\_group": "WORKSPACE", "workspace\_id": "workspace-a1b2c3d4e5f6" } \{{< /highlight >\}} \{{< /tab >\}}

\{{< tab "Response Example" >\}}

[RoleBindingInfo](#ROLEBINDINGINFO)

* **role\_binding\_id** (string) `Required`
* **role\_type** (RoleType) `Required`
* **resource\_group** (ResourceGroup) `Required`
* **domain\_id** (string) `Required`
* **workspace\_group\_id** (string) `Required`
* **workspace\_id** (string) `Required`
* **role\_id** (string) `Required`
* **user\_id** (string) `Required`
* **created\_at** (string) `Required`

\{{< highlight json >\}} { "created\_at": "2024-11-18T04:23:18.121Z", "domain\_id": "domain-a1b2c3d4e5f6", "resource\_group": "WORKSPACE", "role\_binding\_id": "rb-a1b2c3d4e5f6", "role\_id": "managed-workspace-owner", "role\_type": "WORKSPACE\_OWNER", "user\_id": "wonny@cloudforet.io", "workspace\_id": "workspace-a1b2c3d4e5f6" } \{{< /highlight >\}} \{{< /tab >\}}

\{{< /tabs >\}}

\


### update\_role

> **POST** /identity/v1/role-binding/update-role

\{{< tabs " update\_role " >\}}

\{{< tab "Request Example" >\}}

[UpdateRoleBindingRequest](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#updaterolebindingrequest)

* **role\_binding\_id** (string) `Required`
* **role\_id** (string) `Required`

\{{< highlight json >\}} { "roleBindingId": "rb-a1b2c3d4e5f6", "roleId": "managed-workspace-owner" } \{{< /highlight >\}} \{{< /tab >\}}

\{{< tab "Response Example" >\}}

[RoleBindingInfo](#ROLEBINDINGINFO)

* **role\_binding\_id** (string) `Required`
* **role\_type** (RoleType) `Required`
* **resource\_group** (ResourceGroup) `Required`
* **domain\_id** (string) `Required`
* **workspace\_group\_id** (string) `Required`
* **workspace\_id** (string) `Required`
* **role\_id** (string) `Required`
* **user\_id** (string) `Required`
* **created\_at** (string) `Required`

\{{< highlight json >\}} { "created\_at": "2024-11-18T04:23:18.121Z", "domain\_id": "domain-a1b2c3d4e5f6", "resource\_group": "WORKSPACE", "role\_binding\_id": "rb-a1b2c3d4e5f6", "role\_id": "managed-workspace-owner", "role\_type": "WORKSPACE\_OWNER", "user\_id": "wonny@cloudforet.io", "workspace\_id": "workspace-a1b2c3d4e5f6" } \{{< /highlight >\}} \{{< /tab >\}}

\{{< /tabs >\}}

\


### delete

> **POST** /identity/v1/role-binding/delete

\{{< tabs " delete " >\}}

\{{< tab "Request Example" >\}}

[RoleBindingRequest](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#rolebindingrequest)

* **role\_binding\_id** (string) `Required`

\{{< highlight json >\}} { "roleBindingId": "rb-a1b2c3d4e5f6", } \{{< /highlight >\}} \{{< /tab >\}}

\{{< /tabs >\}}

\


### get

> **POST** /identity/v1/role-binding/get

\{{< tabs " get " >\}}

\{{< tab "Request Example" >\}}

[RoleBindingRequest](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#rolebindingrequest)

* **role\_binding\_id** (string) `Required`

\{{< highlight json >\}} { "roleBindingId": "rb-a1b2c3d4e5f6", } \{{< /highlight >\}} \{{< /tab >\}}

\{{< tab "Response Example" >\}}

[RoleBindingInfo](#ROLEBINDINGINFO)

* **role\_binding\_id** (string) `Required`
* **role\_type** (RoleType) `Required`
* **resource\_group** (ResourceGroup) `Required`
* **domain\_id** (string) `Required`
* **workspace\_group\_id** (string) `Required`
* **workspace\_id** (string) `Required`
* **role\_id** (string) `Required`
* **user\_id** (string) `Required`
* **created\_at** (string) `Required`

\{{< highlight json >\}} { "created\_at": "2024-11-18T04:23:18.121Z", "domain\_id": "domain-a1b2c3d4e5f6", "resource\_group": "WORKSPACE", "role\_binding\_id": "rb-a1b2c3d4e5f6", "role\_id": "managed-workspace-owner", "role\_type": "WORKSPACE\_OWNER", "user\_id": "wonny@cloudforet.io", "workspace\_id": "workspace-a1b2c3d4e5f6" } \{{< /highlight >\}} \{{< /tab >\}}

\{{< /tabs >\}}

\


### list

> **POST** /identity/v1/role-binding/list

\{{< tabs " list " >\}}

\{{< tab "Request Example" >\}}

[RoleBindingSearchQuery](https://github.com/cloudforet-io/api-doc/blob/master/content/en/identity/v2/RoleBinding/README.md#rolebindingsearchquery)

* **query** (Query)
* **role\_binding\_id** (string)
* **role\_type** (RoleType)
* **workspace\_id** (string)
* **role\_id** (string)
* **user\_id** (string)

\{{< highlight json >\}} { "roleType": "WORKSPACE\_MEMBER", "query": { "page": { "start": 1, "limit": 10 }, "sort": \[ { "key": "created\_at", "desc": true } ] } } \{{< /highlight >\}} \{{< /tab >\}}

\{{< tab "Response Example" >\}}

[RoleBindingsInfo](#ROLEBINDINGSINFO)

* **results** (RoleBindingInfo) `Repeated` `Required`
* **total\_count** (int32) `Required`

\{{< highlight json >\}} { "results": \[ { "created\_at": "2024-11-18T05:00:52.870Z", "domain\_id": "domain-a1b2c3d4e5f6", "resource\_group": "WORKSPACE", "role\_binding\_id": "rb-a1b2c3d4e5f6", "role\_id": "managed-workspace-member", "role\_type": "WORKSPACE\_MEMBER", "user\_id": "wonny@cloudforet.io", "workspace\_id": "workspace-a1b2c3d4e5f6" }, { "created\_at": "2024-11-18T04:42:33.285Z", "domain\_id": "domain-a1b2c3d4e5f6", "resource\_group": "WORKSPACE", "role\_binding\_id": "rb-g7h8i9j1k2l3", "role\_id": "managed-workspace-owner", "role\_type": "WORKSPACE\_OWNER", "user\_id": "wonny@cloudforet.io", "workspace\_id": "workspace-a1b2c3d4e5f6" } ], "total\_count": 2 } \{{< /highlight >\}} \{{< /tab >\}}

\{{< /tabs >\}}

\


### stat

> **POST** /identity/v1/role-binding/stat

\
\


## Message

### CreateRoleBindingRequest

* **user\_id** (string) `Required`
* **role\_id** (string) `Required`
* **resource\_group** (ResourceGroup) `Required`
*   **workspace\_id** (string)

    \


### RoleBindingInfo

* **role\_binding\_id** (string) `Required`
* **role\_type** (RoleType) `Required`
* **resource\_group** (ResourceGroup) `Required`
* **domain\_id** (string) `Required`
* **workspace\_group\_id** (string) `Required`
* **workspace\_id** (string) `Required`
* **role\_id** (string) `Required`
* **user\_id** (string) `Required`
*   **created\_at** (string) `Required`

    \


### RoleBindingRequest

*   **role\_binding\_id** (string) `Required`

    \


### RoleBindingSearchQuery

* **query** (Query)
* **role\_binding\_id** (string)
* **role\_type** (RoleType)
* **workspace\_id** (string)
* **role\_id** (string)
*   **user\_id** (string)

    \


### RoleBindingStatQuery

*   **query** (StatisticsQuery) `Required`

    \


### RoleBindingsInfo

* **results** (RoleBindingInfo) `Repeated` `Required`
*   **total\_count** (int32) `Required`

    \


### UpdateRoleBindingRequest

* **role\_binding\_id** (string) `Required`
*   **role\_id** (string) `Required`

    \
