Documentation ¶
Index ¶
- type AttrVars
- type Auth
- type BaseResponse
- type BasicAuth
- type Client
- func (c *Client) CreateOrUpdateWorkspaceMember(ctx context.Context, workspaceId string, principalId string) (*v2.RateLimitDescription, error)
- func (c *Client) FindGroupDisplayName(ctx context.Context, workspaceId, groupID string) (string, *v2.RateLimitDescription, error)
- func (c *Client) FindGroupID(ctx context.Context, workspaceId string, displayName string) (string, *v2.RateLimitDescription, error)
- func (c *Client) FindServicePrincipalAppID(ctx context.Context, workspaceId string, servicePrincipalID string) (string, *v2.RateLimitDescription, error)
- func (c *Client) FindServicePrincipalID(ctx context.Context, workspaceId string, appID string) (string, *v2.RateLimitDescription, error)
- func (c *Client) FindUserID(ctx context.Context, workspaceId string, username string) (string, *v2.RateLimitDescription, error)
- func (c *Client) FindUsername(ctx context.Context, workspaceId string, userID string) (string, *v2.RateLimitDescription, error)
- func (c *Client) Get(ctx context.Context, urlAddress *url.URL, response interface{}, params ...Vars) (*v2.RateLimitDescription, error)
- func (c *Client) GetAccountId() string
- func (c *Client) GetGroup(ctx context.Context, workspaceId, groupId string) (*Group, *v2.RateLimitDescription, error)
- func (c *Client) GetServicePrincipal(ctx context.Context, workspaceId string, servicePrincipalID string) (*ServicePrincipal, *v2.RateLimitDescription, error)
- func (c *Client) GetUser(ctx context.Context, workspaceId string, userId string) (*User, *v2.RateLimitDescription, error)
- func (c *Client) IsAccountAPIAvailable() bool
- func (c *Client) IsTokenAuth() bool
- func (c *Client) IsWorkspaceAPIAvailable() bool
- func (c *Client) ListGroups(ctx context.Context, workspaceId string, vars ...Vars) ([]Group, uint, *v2.RateLimitDescription, error)
- func (c *Client) ListRoles(ctx context.Context, workspaceId string, resourceType string, ...) ([]Role, *v2.RateLimitDescription, error)
- func (c *Client) ListRuleSets(ctx context.Context, workspaceId string, resourceType string, ...) ([]RuleSet, *v2.RateLimitDescription, error)
- func (c *Client) ListServicePrincipals(ctx context.Context, workspaceId string, vars ...Vars) ([]ServicePrincipal, uint, *v2.RateLimitDescription, error)
- func (c *Client) ListUsers(ctx context.Context, workspaceId string, vars ...Vars) ([]User, uint, *v2.RateLimitDescription, error)
- func (c *Client) ListWorkspaceMembers(ctx context.Context, workspaceId string) ([]WorkspaceAssignment, *v2.RateLimitDescription, error)
- func (c *Client) ListWorkspaces(ctx context.Context) ([]Workspace, *v2.RateLimitDescription, error)
- func (c *Client) Put(ctx context.Context, urlAddress *url.URL, body interface{}, ...) (*v2.RateLimitDescription, error)
- func (c *Client) RemoveWorkspaceMember(ctx context.Context, workspaceId string, principalId string) (*v2.RateLimitDescription, error)
- func (c *Client) UpdateAvailability(accAPI, wsAPI bool)
- func (c *Client) UpdateEtag(etag string)
- func (c *Client) UpdateGroup(ctx context.Context, workspaceId string, group *Group) (*v2.RateLimitDescription, error)
- func (c *Client) UpdateRuleSets(ctx context.Context, workspaceId, resourceType, resourceId string, ...) (*v2.RateLimitDescription, error)
- func (c *Client) UpdateServicePrincipal(ctx context.Context, workspaceId string, servicePrincipal *ServicePrincipal) (*v2.RateLimitDescription, error)
- func (c *Client) UpdateUser(ctx context.Context, workspaceId string, user *User) (*v2.RateLimitDescription, error)
- type FilterVars
- type Group
- type ListResponse
- type Member
- type NameVars
- type NoAuth
- type OAuth2
- type PaginationVars
- type PermissionValue
- type Permissions
- type ResourceVars
- type Role
- type RuleSet
- type ServicePrincipal
- type TokenAuth
- type User
- type Vars
- type Workspace
- type WorkspaceAssignment
- type WorkspacePrincipal
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AttrVars ¶
type AttrVars struct {
Attrs []string `json:"attributes"`
}
Attribute vars are used to specify which attributes to return from the API.
func NewGroupAttrVars ¶
func NewGroupAttrVars() *AttrVars
func NewGroupRolesAttrVars ¶
func NewGroupRolesAttrVars() *AttrVars
func NewServicePrincipalAttrVars ¶
func NewServicePrincipalAttrVars() *AttrVars
func NewServicePrincipalRolesAttrVars ¶
func NewServicePrincipalRolesAttrVars() *AttrVars
func NewUserAttrVars ¶
func NewUserAttrVars() *AttrVars
func NewUserRolesAttrVars ¶
func NewUserRolesAttrVars() *AttrVars
type BaseResponse ¶
type BaseResponse struct {
ID string `json:"id"`
}
type BasicAuth ¶
func NewBasicAuth ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) CreateOrUpdateWorkspaceMember ¶
func (*Client) FindGroupDisplayName ¶
func (*Client) FindGroupID ¶
func (*Client) FindServicePrincipalAppID ¶
func (*Client) FindServicePrincipalID ¶
func (*Client) FindUserID ¶
func (*Client) FindUsername ¶
func (*Client) GetAccountId ¶
func (*Client) GetServicePrincipal ¶
func (c *Client) GetServicePrincipal( ctx context.Context, workspaceId string, servicePrincipalID string, ) ( *ServicePrincipal, *v2.RateLimitDescription, error, )
func (*Client) IsAccountAPIAvailable ¶
func (*Client) IsTokenAuth ¶
func (*Client) IsWorkspaceAPIAvailable ¶
func (*Client) ListGroups ¶
func (*Client) ListRuleSets ¶
func (*Client) ListServicePrincipals ¶
func (c *Client) ListServicePrincipals( ctx context.Context, workspaceId string, vars ...Vars, ) ( []ServicePrincipal, uint, *v2.RateLimitDescription, error, )
func (*Client) ListWorkspaceMembers ¶
func (c *Client) ListWorkspaceMembers( ctx context.Context, workspaceId string, ) ( []WorkspaceAssignment, *v2.RateLimitDescription, error, )
func (*Client) ListWorkspaces ¶
func (*Client) RemoveWorkspaceMember ¶
func (*Client) UpdateAvailability ¶
func (*Client) UpdateEtag ¶
func (*Client) UpdateGroup ¶
func (*Client) UpdateRuleSets ¶
func (*Client) UpdateServicePrincipal ¶
func (c *Client) UpdateServicePrincipal( ctx context.Context, workspaceId string, servicePrincipal *ServicePrincipal, ) ( *v2.RateLimitDescription, error, )
func (*Client) UpdateUser ¶
type FilterVars ¶
type FilterVars struct {
Filter string `json:"filter"`
}
Filter vars are used for filtering results from the API.
func NewFilterVars ¶
func NewFilterVars(filter string) *FilterVars
func (*FilterVars) Apply ¶
func (f *FilterVars) Apply(params *url.Values)
type Group ¶
type Group struct { BaseResponse Permissions DisplayName string `json:"displayName"` Members []Member `json:"members,omitempty"` Meta struct { Type string `json:"resourceType"` } `json:"meta,omitempty"` Schemas []string `json:"schemas,omitempty"` }
func (Group) HaveEntitlement ¶
func (Group) IsAccountGroup ¶
type ListResponse ¶
type NameVars ¶
func NewNameVars ¶
type PaginationVars ¶
Pagination vars are used for paginating results from the API.
func NewPaginationVars ¶
func NewPaginationVars(start uint, count uint) *PaginationVars
func (*PaginationVars) Apply ¶
func (p *PaginationVars) Apply(params *url.Values)
type PermissionValue ¶
type PermissionValue struct {
Value string `json:"value"`
}
type Permissions ¶
type Permissions struct { Roles []PermissionValue `json:"roles,omitempty"` Entitlements []PermissionValue `json:"entitlements,omitempty"` }
type ResourceVars ¶
type ResourceVars struct {
Payload string `json:"resource"`
}
func NewResourceVars ¶
func NewResourceVars(resource string) *ResourceVars
func (*ResourceVars) Apply ¶
func (r *ResourceVars) Apply(params *url.Values)
type ServicePrincipal ¶
type ServicePrincipal struct { BaseResponse Permissions DisplayName string `json:"displayName"` Active bool `json:"active"` ApplicationID string `json:"applicationId"` }
func (ServicePrincipal) HaveEntitlement ¶
func (s ServicePrincipal) HaveEntitlement(entitlement string) bool
func (ServicePrincipal) HaveRole ¶
func (s ServicePrincipal) HaveRole(role string) bool
type User ¶
type User struct { BaseResponse Permissions Emails []struct { Primary bool `json:"primary"` Value string `json:"value"` } `json:"emails"` UserName string `json:"userName"` DisplayName string `json:"displayName"` Active bool `json:"active,omitempty"` }
func (User) HaveEntitlement ¶
type WorkspaceAssignment ¶
type WorkspaceAssignment struct {
Principal *WorkspacePrincipal `json:"principal"`
}
Click to show internal directories.
Click to hide internal directories.