Documentation
¶
Index ¶
- func Register(router forge.Router, basePath string, h *handlers.AuthHandler, ...)
- func RegisterApp(router forge.Router, basePath string, h *handlers.AppHandler, ...)
- func RegisterAppRBAC(router forge.Router, h *handlers.AppHandler)
- func RegisterAudit(router forge.Router, basePath string, h *handlers.AuditHandler, ...)
- func RegisterJWT(router forge.Router, basePath string, h interface{})
- func RegisterWebhook(router forge.Router, basePath string, h *handlers.WebhookHandler)
- func RegisterWebhookRoutes(router forge.Router, handler *handlers.WebhookHandler)
- type AppResponse
- type AppsResponse
- type AuditEventsResponse
- type CookieConfigRequest
- type CookieConfigResponse
- type CookieConfigUpdateResponse
- type DevicesResponse
- type ErrorResponse
- type InvitationResponse
- type MemberResponse
- type MembersResponse
- type PoliciesResponse
- type PolicyResponse
- type RevokeDeviceRequest
- type RoleResponse
- type RolesResponse
- type SessionResponse
- type SignOutRequest
- type StatusResponse
- type TeamMembersResponse
- type TeamResponse
- type TeamsResponse
- type UpdateUserRequest
- type UserRolesResponse
- type WebhookDeleteResponse
- type WebhookErrorResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Register ¶
func Register(router forge.Router, basePath string, h *handlers.AuthHandler, authMiddleware forge.Middleware)
Register registers auth routes using forge.Router authMiddleware is applied to all routes to extract and validate API keys for app identification
func RegisterApp ¶
func RegisterApp(router forge.Router, basePath string, h *handlers.AppHandler, authMiddleware forge.Middleware)
RegisterApp registers app (platform tenant) routes under a base path This is used when multitenancy plugin is NOT enabled
func RegisterAppRBAC ¶
func RegisterAppRBAC(router forge.Router, h *handlers.AppHandler)
RegisterAppRBAC registers RBAC-related routes (policies, roles, user roles) This is used when multitenancy plugin IS enabled to supplement its routes Note: These routes don't apply middleware as they're nested under RegisterApp which already applies it
func RegisterAudit ¶
func RegisterAudit(router forge.Router, basePath string, h *handlers.AuditHandler, authMiddleware forge.Middleware)
RegisterAudit registers audit routes under a base path
func RegisterJWT ¶
RegisterJWT is DEPRECATED - JWT routes are now handled by the JWT plugin. The JWT plugin registers its own routes via plugin.RegisterRoutes(). Use: auth.RegisterPlugin(jwt.NewPlugin())
func RegisterWebhook ¶
func RegisterWebhook(router forge.Router, basePath string, h *handlers.WebhookHandler)
RegisterWebhook registers webhook routes under a base path
func RegisterWebhookRoutes ¶
func RegisterWebhookRoutes(router forge.Router, handler *handlers.WebhookHandler)
RegisterWebhookRoutes registers webhook-related routes
Types ¶
type AppResponse ¶
type AppResponse struct{}
App DTOs (placeholder types - actual implementations should be in handlers or core)
type AppsResponse ¶
type AppsResponse []interface{}
type AuditEventsResponse ¶
type AuditEventsResponse struct {
Data interface{} `json:"data"`
Total int `json:"total"`
Page int `json:"page"`
PageSize int `json:"page_size"`
TotalPages int `json:"total_pages"`
}
AuditEventsResponse represents a paginated list of audit events
type CookieConfigRequest ¶ added in v0.0.2
type CookieConfigRequest struct{}
type CookieConfigResponse ¶ added in v0.0.2
type CookieConfigResponse struct{}
type CookieConfigUpdateResponse ¶ added in v0.0.2
type CookieConfigUpdateResponse struct{}
type DevicesResponse ¶
DevicesResponse represents a list of devices
type ErrorResponse ¶
type ErrorResponse struct {
Error string `json:"error" example:"Error message"`
}
ErrorResponse represents an error response
type InvitationResponse ¶
type InvitationResponse struct{}
type MemberResponse ¶
type MemberResponse struct{}
type MembersResponse ¶
type MembersResponse []interface{}
type PoliciesResponse ¶
type PoliciesResponse []interface{}
type RevokeDeviceRequest ¶
type RevokeDeviceRequest struct {
Fingerprint string `json:"fingerprint" validate:"required" example:"device_fingerprint_here"`
}
RevokeDeviceRequest represents a device revocation request
type RoleResponse ¶
type RoleResponse struct{}
type RolesResponse ¶
type RolesResponse []interface{}
type SessionResponse ¶
type SessionResponse struct {
User *user.User `json:"user"`
Session map[string]interface{} `json:"session"`
}
SessionResponse represents session information
type SignOutRequest ¶
type SignOutRequest struct {
Token string `json:"token" validate:"required" example:"session_token_here"`
}
SignOutRequest represents a sign out request
type StatusResponse ¶
type StatusResponse struct {
Status string `json:"status" example:"success"`
}
StatusResponse represents a status response
type TeamMembersResponse ¶
type TeamMembersResponse []interface{}
type TeamResponse ¶
type TeamResponse struct{}
type TeamsResponse ¶
type TeamsResponse []interface{}
type UpdateUserRequest ¶
type UpdateUserRequest struct {
Name *string `json:"name,omitempty" example:"John Doe"`
Image *string `json:"image,omitempty" example:"https://example.com/avatar.jpg"`
Username *string `json:"username,omitempty" example:"johndoe"`
DisplayUsername *string `json:"display_username,omitempty" example:"John D."`
}
UpdateUserRequest represents a user update request
type UserRolesResponse ¶
type UserRolesResponse []interface{}
type WebhookDeleteResponse ¶
type WebhookDeleteResponse struct {
Message string `json:"message" example:"webhook deleted successfully"`
}
WebhookDeleteResponse represents a successful webhook deletion
type WebhookErrorResponse ¶
type WebhookErrorResponse struct {
Error string `json:"error" example:"Error message"`
}
WebhookErrorResponse represents an error response