Documentation
¶
Index ¶
- Variables
- type API
- func (*API) Descriptor() ([]byte, []int)deprecated
- func (x *API) GetAudience() string
- func (x *API) GetEnforceRbac() bool
- func (x *API) GetHeader() *header.Header
- func (x *API) GetName() string
- func (x *API) GetTokenType() TokenType
- func (*API) ProtoMessage()
- func (x *API) ProtoReflect() protoreflect.Message
- func (x *API) Reset()
- func (x *API) String() string
- type PermissionScope
- func (*PermissionScope) Descriptor() ([]byte, []int)deprecated
- func (x *PermissionScope) GetAssociatedApi() string
- func (x *PermissionScope) GetHeader() *header.Header
- func (x *PermissionScope) GetKey() string
- func (x *PermissionScope) GetValue() string
- func (*PermissionScope) ProtoMessage()
- func (x *PermissionScope) ProtoReflect() protoreflect.Message
- func (x *PermissionScope) Reset()
- func (x *PermissionScope) String() string
- type Role
- func (*Role) Descriptor() ([]byte, []int)deprecated
- func (x *Role) GetDescription() string
- func (x *Role) GetHeader() *header.Header
- func (x *Role) GetName() string
- func (x *Role) GetScopes() map[string]string
- func (*Role) ProtoMessage()
- func (x *Role) ProtoReflect() protoreflect.Message
- func (x *Role) Reset()
- func (x *Role) String() string
- type TokenType
Constants ¶
This section is empty.
Variables ¶
View Source
var ( TokenType_name = map[int32]string{ 0: "HS256", 1: "RS256", } TokenType_value = map[string]int32{ "HS256": 0, "RS256": 1, } )
Enum value maps for TokenType.
View Source
var File_proto_api_api_proto protoreflect.FileDescriptor
View Source
var File_proto_api_role_proto protoreflect.FileDescriptor
View Source
var File_proto_api_scope_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type API ¶
type API struct {
Header *header.Header `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty" bson:"header"` // @gotags: bson:"header"
// domain - A arbitrary domain used in the audience of issues tokens. Does not need to resolve to anything
Audience string `protobuf:"bytes,2,opt,name=audience,proto3" json:"audience,omitempty" bson:"audience"` // @gotags: bson:"audience"
// name - The name of the API as defined by the user
Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty" bson:"name"` // @gotags: bson:"name"
// token_type - The type of tokens the API should issue
TokenType TokenType `` // @gotags: bson:"token_type"
/* 126-byte string literal not displayed */
// enforce_rbac - Enforce permissions and roles for this API
EnforceRbac bool `protobuf:"varint,5,opt,name=enforce_rbac,json=enforceRbac,proto3" json:"enforce_rbac,omitempty" bson:"enforce_rbac"` // @gotags: bson:"enforce_rbac"
// contains filtered or unexported fields
}
API - Represents an integrators API. Primarily contains RBAC information and determines the token type
func (*API) Descriptor
deprecated
func (*API) GetAudience ¶
func (*API) GetEnforceRbac ¶
func (*API) GetTokenType ¶
func (*API) ProtoMessage ¶
func (*API) ProtoMessage()
func (*API) ProtoReflect ¶
func (x *API) ProtoReflect() protoreflect.Message
type PermissionScope ¶
type PermissionScope struct {
// header - Shared data values used across all objects
Header *header.Header `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty" bson:"header"` // @gotags: bson:"header"
// associated_api - The API this permission scope is assigned to
AssociatedApi string `protobuf:"bytes,2,opt,name=associated_api,json=associatedApi,proto3" json:"associated_api,omitempty" bson:"associated_api"` // @gotags: bson:"associated_api"
// key - A key for the permission scope
Key string `protobuf:"bytes,3,opt,name=key,proto3" json:"key,omitempty" bson:"key"` // @gotags: bson:"key"
// value - A value for the permission scope
Value string `protobuf:"bytes,4,opt,name=value,proto3" json:"value,omitempty" bson:"value"` // @gotags: bson:"value"
// contains filtered or unexported fields
}
PermissionScope - A structure representing a unit of permissions that can be evaluated by the API. When marshaled and returned to the user, key and value are appended together in the following format:
`key:value`
func (*PermissionScope) Descriptor
deprecated
func (*PermissionScope) Descriptor() ([]byte, []int)
Deprecated: Use PermissionScope.ProtoReflect.Descriptor instead.
func (*PermissionScope) GetAssociatedApi ¶
func (x *PermissionScope) GetAssociatedApi() string
func (*PermissionScope) GetHeader ¶
func (x *PermissionScope) GetHeader() *header.Header
func (*PermissionScope) GetKey ¶
func (x *PermissionScope) GetKey() string
func (*PermissionScope) GetValue ¶
func (x *PermissionScope) GetValue() string
func (*PermissionScope) ProtoMessage ¶
func (*PermissionScope) ProtoMessage()
func (*PermissionScope) ProtoReflect ¶
func (x *PermissionScope) ProtoReflect() protoreflect.Message
func (*PermissionScope) Reset ¶
func (x *PermissionScope) Reset()
func (*PermissionScope) String ¶
func (x *PermissionScope) String() string
type Role ¶
type Role struct {
// header - Shared data values used across all objects
Header *header.Header `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty" bson:"header"` // @gotags: bson:"header"
// name - The name of the role as defined by the user
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty" bson:"name"` // @gotags: bson:"name"
// description - The description of the role as defined by the user
Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty" bson:"description"` // @gotags: bson:"description"
// scopes - A map representing the scopes assigned to this role. Key is the API id, and value is the ID of the scope
Scopes map[string]string `` // @gotags: bson:"scopes"
/* 153-byte string literal not displayed */
// contains filtered or unexported fields
}
Role - A container for permission scopes that can be assigned to users
func (*Role) Descriptor
deprecated
func (*Role) GetDescription ¶
func (*Role) ProtoMessage ¶
func (*Role) ProtoMessage()
func (*Role) ProtoReflect ¶
func (x *Role) ProtoReflect() protoreflect.Message
type TokenType ¶
type TokenType int32
TokenType - The type of tokens the API should issue
func (TokenType) Descriptor ¶
func (TokenType) Descriptor() protoreflect.EnumDescriptor
func (TokenType) EnumDescriptor
deprecated
func (TokenType) Number ¶
func (x TokenType) Number() protoreflect.EnumNumber
func (TokenType) Type ¶
func (TokenType) Type() protoreflect.EnumType
Click to show internal directories.
Click to hide internal directories.