Revoke role from group
Revoke role from group
client.Zones.Groups.Roles.Remove(ctx, roleID, params) error
DELETE/zones/{zoneId}/groups/{groupId}/roles/{roleId}
Revokes a role from the group. Provide the same (scope_type, scope_id) pair the grant was created with, or omit both to revoke the unscoped grant.
Parameters
roleID string
Revoke role from group
package main
import (
"context"
"github.com/keycardai/keycard-go"
"github.com/keycardai/keycard-go/option"
)
func main() {
client := keycard.NewClient(
option.WithAPIKey("My API Key"),
)
err := client.Zones.Groups.Roles.Remove(
context.TODO(),
"roleId",
keycard.ZoneGroupRoleRemoveParams{
ZoneID: "zoneId",
GroupID: "groupId",
},
)
if err != nil {
panic(err.Error())
}
}