Skip to content
  • Auto
  • Light
  • Dark
Get Started

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
Hide ParametersShow Parameters
Rolefield
optional
param.Field[IDstringCreatedAtTimeDeletedAtTimeDisplayNamestringNamestringPermissionsarrayServiceRolesarraySystemAPIOnlyboolSystemBuiltinboolUpdatedAtTimeRole]

Role is a role that can be assigned to a user in ConductorOne.

UpdateMaskfield
optional
param.Field[string]
Returns
IAMRoleUpdateResponsestruct

UpdateRolesResponse is the response message containing the updated role.

Hide ParametersShow Parameters
RoleIDstringCreatedAtTimeDeletedAtTimeDisplayNamestringNamestringPermissionsarrayServiceRolesarraySystemAPIOnlyboolSystemBuiltinboolUpdatedAtTimeRole
optional

Role is a role that can be assigned to a user in ConductorOne.

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"
    ]
  }
}