role

package
v2.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 24, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssignRoleToUser

func AssignRoleToUser(roleId string, userId string) (*warrant.Role, error)

func Create

func Create(params *warrant.RoleParams) (*warrant.Role, error)

func Delete

func Delete(roleId string) error

func Get

func Get(roleId string) (*warrant.Role, error)

func ListRoles

func ListRoles(listParams *warrant.ListRoleParams) ([]warrant.Role, error)

func ListRolesForUser

func ListRolesForUser(userId string, listParams *warrant.ListRoleParams) ([]warrant.Role, error)

func RemoveRoleFromUser

func RemoveRoleFromUser(roleId string, userId string) error

func Update

func Update(roleId string, params *warrant.RoleParams) (*warrant.Role, error)

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

func NewClient

func NewClient(config config.ClientConfig) Client

func (Client) AssignRoleToUser

func (c Client) AssignRoleToUser(roleId string, userId string) (*warrant.Role, error)

func (Client) Create

func (c Client) Create(params *warrant.RoleParams) (*warrant.Role, error)

func (Client) Delete

func (c Client) Delete(roleId string) error

func (Client) Get

func (c Client) Get(roleId string) (*warrant.Role, error)

func (Client) ListRoles

func (c Client) ListRoles(listParams *warrant.ListRoleParams) ([]warrant.Role, error)

func (Client) ListRolesForUser

func (c Client) ListRolesForUser(userId string, listParams *warrant.ListRoleParams) ([]warrant.Role, error)

func (Client) RemoveRoleFromUser

func (c Client) RemoveRoleFromUser(roleId string, userId string) error

func (Client) Update

func (c Client) Update(roleId string, params *warrant.RoleParams) (*warrant.Role, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL