Update
Update
client.IAM.Roles.Update(ctx, roleID, body) (*RoleRoleIAMRoleUpdateResponse, error)
post/api/v1/iam/roles/{role_id}
Update a role by passing a Role object.
Parameters
roleIDstring
The id of the role.
bodyRolefieldUpdateMaskfieldIAMRoleUpdateParams
Returns
IAMRoleUpdateResponsestruct
UpdateRolesResponse is the response message containing the updated role.
Request example Go
package main
import (
"context"
"fmt"
"github.com/stainless-sdks/-go"
"github.com/stainless-sdks/-go/option"
)
func main() {
client := conductoronesdk.NewClient(
option.WithAPIKey("My API Key"),
)
role, err := client.IAM.Roles.Update(
context.TODO(),
"role_id",
conductoronesdk.IAMRoleUpdateParams{
},
)
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", role.Role)
}
200 Example
{
"role": {
"displayName": "displayName",
"permissions": [
"string"
],
"serviceRoles": [
"string"
]
}
}