api

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2026 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type A2AApi

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

func NewA2AApi

func NewA2AApi(a2aService services.IA2AService, authService services.IAuthService, config descriptors.ChannelsConfig) *A2AApi

func (*A2AApi) HandleA2A

func (a *A2AApi) HandleA2A(next http.Handler) http.HandlerFunc

func (*A2AApi) Register

func (a *A2AApi) Register(r chi.Router)

type A2UIApi

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

func NewA2UIApi

func NewA2UIApi(a2uiService services.IA2UIService, authApi *AuthApi) *A2UIApi

func (*A2UIApi) Action

func (a *A2UIApi) Action(w http.ResponseWriter, r *http.Request)

func (*A2UIApi) Register

func (a *A2UIApi) Register(r chi.Router)

func (*A2UIApi) Stream

func (a *A2UIApi) Stream(w http.ResponseWriter, r *http.Request)

type AssetApi

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

func NewAssetApi

func NewAssetApi(assetService *services.AssetService) *AssetApi

func (*AssetApi) CommitChunks

func (a *AssetApi) CommitChunks(w http.ResponseWriter, r *http.Request)

func (*AssetApi) GetChunkStatus

func (a *AssetApi) GetChunkStatus(w http.ResponseWriter, r *http.Request)

func (*AssetApi) Register

func (a *AssetApi) Register(r chi.Router)

func (*AssetApi) UploadChunk

func (a *AssetApi) UploadChunk(w http.ResponseWriter, r *http.Request)

type AuditApi

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

func NewAuditApi

func NewAuditApi(auditService services.IAuditService, authApi *AuthApi) *AuditApi

func (*AuditApi) AdminOnlyMiddleware

func (a *AuditApi) AdminOnlyMiddleware(next http.Handler) http.Handler

func (*AuditApi) Get

func (a *AuditApi) Get(w http.ResponseWriter, r *http.Request)

func (*AuditApi) List

func (a *AuditApi) List(w http.ResponseWriter, r *http.Request)

func (*AuditApi) Register

func (a *AuditApi) Register(r chi.Router)

type AuthApi

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

func NewAuthApi

func NewAuthApi(authService services.IAuthService, permissionService services.IPermissionService) *AuthApi

func (*AuthApi) DoLogin

func (a *AuthApi) DoLogin(w http.ResponseWriter, r *http.Request)

func (*AuthApi) DoLoginByChannel

func (a *AuthApi) DoLoginByChannel(w http.ResponseWriter, r *http.Request)

func (*AuthApi) DoLogout

func (a *AuthApi) DoLogout(w http.ResponseWriter, r *http.Request)

func (*AuthApi) DoRegister

func (a *AuthApi) DoRegister(w http.ResponseWriter, r *http.Request)

func (*AuthApi) GetMe

func (a *AuthApi) GetMe(w http.ResponseWriter, r *http.Request)

func (*AuthApi) JWTMiddleware

func (a *AuthApi) JWTMiddleware(next http.Handler) http.Handler

func (*AuthApi) RBACMiddleware

func (a *AuthApi) RBACMiddleware(action string, explicitResource ...string) func(http.Handler) http.Handler

func (*AuthApi) Register

func (a *AuthApi) Register(r chi.Router)

type ChannelApi

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

func NewChannelApi

func NewChannelApi(channelService services.IChannelService, authApi *AuthApi) *ChannelApi

func (*ChannelApi) GetMyAuthLogs

func (a *ChannelApi) GetMyAuthLogs(w http.ResponseWriter, r *http.Request)

func (*ChannelApi) GetMyChannels

func (a *ChannelApi) GetMyChannels(w http.ResponseWriter, r *http.Request)

func (*ChannelApi) HandleWebhook

func (a *ChannelApi) HandleWebhook(w http.ResponseWriter, r *http.Request)

func (*ChannelApi) Register

func (a *ChannelApi) Register(r chi.Router)

func (*ChannelApi) RegisterChannel

func (a *ChannelApi) RegisterChannel(w http.ResponseWriter, r *http.Request)

func (*ChannelApi) VerifyChannel

func (a *ChannelApi) VerifyChannel(w http.ResponseWriter, r *http.Request)

type ChatApi

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

func NewChatApi

func NewChatApi(chatService *services.ChatService, authApi *AuthApi) *ChatApi

func (*ChatApi) Message

func (a *ChatApi) Message(w http.ResponseWriter, r *http.Request)

func (*ChatApi) Register

func (a *ChatApi) Register(r chi.Router)

type ChatRequest

type ChatRequest struct {
	Message string `json:"message"`
}

type ChatResponse

type ChatResponse struct {
	Response string `json:"response"`
	Error    string `json:"error,omitempty"`
}

type CommentApi

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

func NewCommentApi

func NewCommentApi(commentService services.ICommentService, authApi *AuthApi) *CommentApi

func (*CommentApi) Delete

func (a *CommentApi) Delete(w http.ResponseWriter, r *http.Request)

func (*CommentApi) List

func (a *CommentApi) List(w http.ResponseWriter, r *http.Request)

func (*CommentApi) Register

func (a *CommentApi) Register(r chi.Router)

func (*CommentApi) Save

func (a *CommentApi) Save(w http.ResponseWriter, r *http.Request)

type EngagementApi

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

func NewEngagementApi

func NewEngagementApi(engagementService services.IEngagementService, authApi *AuthApi) *EngagementApi

func (*EngagementApi) Register

func (a *EngagementApi) Register(r chi.Router)

func (*EngagementApi) Track

func (a *EngagementApi) Track(w http.ResponseWriter, r *http.Request)

type EntityApi

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

func NewEntityApi

func NewEntityApi(entityService services.IEntityService, authApi *AuthApi) *EntityApi

func (*EntityApi) CollectionInsert

func (a *EntityApi) CollectionInsert(w http.ResponseWriter, r *http.Request)

func (*EntityApi) CollectionList

func (a *EntityApi) CollectionList(w http.ResponseWriter, r *http.Request)

func (*EntityApi) Create

func (a *EntityApi) Create(w http.ResponseWriter, r *http.Request)

func (*EntityApi) Delete

func (a *EntityApi) Delete(w http.ResponseWriter, r *http.Request)

func (*EntityApi) Get

func (a *EntityApi) Get(w http.ResponseWriter, r *http.Request)

func (*EntityApi) JunctionDelete

func (a *EntityApi) JunctionDelete(w http.ResponseWriter, r *http.Request)

func (*EntityApi) JunctionList

func (a *EntityApi) JunctionList(w http.ResponseWriter, r *http.Request)

func (*EntityApi) JunctionSave

func (a *EntityApi) JunctionSave(w http.ResponseWriter, r *http.Request)

func (*EntityApi) List

func (a *EntityApi) List(w http.ResponseWriter, r *http.Request)

func (*EntityApi) Register

func (a *EntityApi) Register(r chi.Router)

func (*EntityApi) Update

func (a *EntityApi) Update(w http.ResponseWriter, r *http.Request)

type GraphQLApi

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

func NewGraphQLApi

func NewGraphQLApi(graphqlService services.IGraphQLService, authApi *AuthApi) *GraphQLApi

func (*GraphQLApi) Query

func (a *GraphQLApi) Query(w http.ResponseWriter, r *http.Request)

func (*GraphQLApi) Register

func (a *GraphQLApi) Register(r chi.Router)

type MCPApi

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

func NewMCPApi

func NewMCPApi(mcpService services.IMCPService) *MCPApi

func (*MCPApi) Authenticate

func (a *MCPApi) Authenticate(next http.Handler) http.Handler

func (*MCPApi) Register

func (a *MCPApi) Register(r chi.Router)

type NotificationApi

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

func NewNotificationApi

func NewNotificationApi(notificationService services.INotificationService, authApi *AuthApi) *NotificationApi

func (*NotificationApi) List

func (*NotificationApi) MarkAllAsRead

func (a *NotificationApi) MarkAllAsRead(w http.ResponseWriter, r *http.Request)

func (*NotificationApi) MarkAsRead

func (a *NotificationApi) MarkAsRead(w http.ResponseWriter, r *http.Request)

func (*NotificationApi) Register

func (a *NotificationApi) Register(r chi.Router)

type PageApi

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

func NewPageApi

func NewPageApi(pageService services.IPageService, authService services.IAuthService, authApi *AuthApi) *PageApi

func (*PageApi) Register

func (a *PageApi) Register(r chi.Router)

func (*PageApi) Render

func (a *PageApi) Render(w http.ResponseWriter, r *http.Request)

type QueryApi

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

func NewQueryApi

func NewQueryApi(graphqlService services.IGraphQLService, authApi *AuthApi) *QueryApi

func (*QueryApi) Execute

func (a *QueryApi) Execute(w http.ResponseWriter, r *http.Request)

func (*QueryApi) ExecuteWithBody

func (a *QueryApi) ExecuteWithBody(w http.ResponseWriter, r *http.Request)

func (*QueryApi) Register

func (a *QueryApi) Register(r chi.Router)

type RBACApi

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

func NewRBACApi

func NewRBACApi(entityService services.IEntityService, authApi *AuthApi) *RBACApi

func (*RBACApi) AdminOnlyMiddleware

func (a *RBACApi) AdminOnlyMiddleware(next http.Handler) http.Handler

func (*RBACApi) DeletePermission

func (a *RBACApi) DeletePermission(w http.ResponseWriter, r *http.Request)

func (*RBACApi) DeleteRole

func (a *RBACApi) DeleteRole(w http.ResponseWriter, r *http.Request)

func (*RBACApi) DeleteUserPermission

func (a *RBACApi) DeleteUserPermission(w http.ResponseWriter, r *http.Request)

func (*RBACApi) DeleteUserRole

func (a *RBACApi) DeleteUserRole(w http.ResponseWriter, r *http.Request)

func (*RBACApi) ListPermissions

func (a *RBACApi) ListPermissions(w http.ResponseWriter, r *http.Request)

func (*RBACApi) ListRoles

func (a *RBACApi) ListRoles(w http.ResponseWriter, r *http.Request)

func (*RBACApi) ListUserPermissions

func (a *RBACApi) ListUserPermissions(w http.ResponseWriter, r *http.Request)

func (*RBACApi) ListUserRoles

func (a *RBACApi) ListUserRoles(w http.ResponseWriter, r *http.Request)

func (*RBACApi) Register

func (a *RBACApi) Register(r chi.Router)

func (*RBACApi) SavePermission

func (a *RBACApi) SavePermission(w http.ResponseWriter, r *http.Request)

func (*RBACApi) SaveRole

func (a *RBACApi) SaveRole(w http.ResponseWriter, r *http.Request)

func (*RBACApi) SaveUserPermission

func (a *RBACApi) SaveUserPermission(w http.ResponseWriter, r *http.Request)

func (*RBACApi) SaveUserRole

func (a *RBACApi) SaveUserRole(w http.ResponseWriter, r *http.Request)

type SchemaApi

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

func NewSchemaApi

func NewSchemaApi(schemaService services.ISchemaService, authApi *AuthApi) *SchemaApi

func (*SchemaApi) AdminOnlyMiddleware

func (a *SchemaApi) AdminOnlyMiddleware(next http.Handler) http.Handler

func (*SchemaApi) Delete

func (a *SchemaApi) Delete(w http.ResponseWriter, r *http.Request)

func (*SchemaApi) GetAll

func (a *SchemaApi) GetAll(w http.ResponseWriter, r *http.Request)

func (*SchemaApi) GetBySchemaId

func (a *SchemaApi) GetBySchemaId(w http.ResponseWriter, r *http.Request)

func (*SchemaApi) Register

func (a *SchemaApi) Register(r chi.Router)

func (*SchemaApi) Save

func (a *SchemaApi) Save(w http.ResponseWriter, r *http.Request)

type StaticApi

type StaticApi struct{}

func NewStaticApi

func NewStaticApi() *StaticApi

func (*StaticApi) Register

func (a *StaticApi) Register(r chi.Router)

type UserAction

type UserAction struct {
	ComponentID string                 `json:"componentId"`
	ActionType  string                 `json:"actionType"`
	Data        map[string]interface{} `json:"data"`
}

Jump to

Keyboard shortcuts

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