Documentation
¶
Index ¶
- type APIResponse
- type APIRouter
- func (router *APIRouter) HandleAssignTicket(c *gin.Context)
- func (router *APIRouter) HandleCloseTicket(c *gin.Context)
- func (router *APIRouter) HandleCreateTicket(c *gin.Context)
- func (router *APIRouter) HandleDeleteTicket(c *gin.Context)
- func (router *APIRouter) HandleListTickets(c *gin.Context)
- func (router *APIRouter) HandleReopenTicket(c *gin.Context)
- func (router *APIRouter) HandleUpdateTicket(c *gin.Context)
- func (router *APIRouter) SetupTicketArticleRoutes(r *gin.Engine)
- func (router *APIRouter) SetupV1Routes(r *gin.Engine)
- type IncidentHandlers
- type LDAPHandler
- func (h *LDAPHandler) AuthenticateUser(c *gin.Context)
- func (h *LDAPHandler) ConfigureLDAP(c *gin.Context)
- func (h *LDAPHandler) DisableLDAP(c *gin.Context)
- func (h *LDAPHandler) GetAuthenticationLogs(c *gin.Context)
- func (h *LDAPHandler) GetConfiguration(c *gin.Context)
- func (h *LDAPHandler) GetGroupMappings(c *gin.Context)
- func (h *LDAPHandler) GetGroups(c *gin.Context)
- func (h *LDAPHandler) GetSyncStatus(c *gin.Context)
- func (h *LDAPHandler) GetUser(c *gin.Context)
- func (h *LDAPHandler) GetUserMappings(c *gin.Context)
- func (h *LDAPHandler) ImportUsers(c *gin.Context)
- func (h *LDAPHandler) RegisterRoutes(r *gin.RouterGroup)
- func (h *LDAPHandler) SearchUsers(c *gin.Context)
- func (h *LDAPHandler) SyncUsers(c *gin.Context)
- func (h *LDAPHandler) TestConnection(c *gin.Context)
- type PaginatedResponse
- type Pagination
- type WebhookHandlers
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIResponse ¶
type APIResponse struct {
Success bool `json:"success"`
Data interface{} `json:"data,omitempty"`
Error string `json:"error,omitempty"`
Message string `json:"message,omitempty"`
}
Response helper structures.
type APIRouter ¶
type APIRouter struct {
// contains filtered or unexported fields
}
APIRouter manages all v1 API routes.
func NewAPIRouter ¶
func NewAPIRouter(rbac *auth.RBAC, jwtManager *auth.JWTManager, ldapHandlers *ldap.LDAPHandlers) *APIRouter
NewAPIRouter creates a new API router instance.
func (*APIRouter) HandleAssignTicket ¶
HandleAssignTicket assigns a ticket to a user.
func (*APIRouter) HandleCloseTicket ¶
HandleCloseTicket closes a ticket.
func (*APIRouter) HandleCreateTicket ¶
HandleCreateTicket creates a new ticket.
func (*APIRouter) HandleDeleteTicket ¶
HandleDeleteTicket archives a ticket (OTRS doesn't hard delete tickets) - exported for YAML routing.
func (*APIRouter) HandleListTickets ¶
HandleListTickets returns a paginated list of tickets (exported for tests).
func (*APIRouter) HandleReopenTicket ¶
HandleReopenTicket reopens a closed ticket.
func (*APIRouter) HandleUpdateTicket ¶
HandleUpdateTicket updates a ticket (exported for tests).
func (*APIRouter) SetupTicketArticleRoutes ¶
SetupTicketArticleRoutes registers only ticket article routes (not in YAML).
func (*APIRouter) SetupV1Routes ¶
SetupV1Routes configures all v1 API routes.
type IncidentHandlers ¶
type IncidentHandlers struct {
}
IncidentHandlers handles incident-related HTTP requests.
func NewIncidentHandlers ¶
func NewIncidentHandlers() *IncidentHandlers
NewIncidentHandlers creates a new incident handlers instance.
func (*IncidentHandlers) RegisterRoutes ¶
func (h *IncidentHandlers) RegisterRoutes(router *gin.RouterGroup)
RegisterRoutes registers incident routes.
type LDAPHandler ¶
type LDAPHandler struct {
// contains filtered or unexported fields
}
LDAPHandler handles LDAP-related API endpoints.
func NewLDAPHandler ¶
func NewLDAPHandler(ldapService *service.LDAPService) *LDAPHandler
NewLDAPHandler creates a new LDAP handler.
func (*LDAPHandler) AuthenticateUser ¶
func (h *LDAPHandler) AuthenticateUser(c *gin.Context)
POST /api/v1/ldap/authenticate.
func (*LDAPHandler) ConfigureLDAP ¶
func (h *LDAPHandler) ConfigureLDAP(c *gin.Context)
POST /api/v1/ldap/configure.
func (*LDAPHandler) DisableLDAP ¶
func (h *LDAPHandler) DisableLDAP(c *gin.Context)
POST /api/v1/ldap/disable.
func (*LDAPHandler) GetAuthenticationLogs ¶
func (h *LDAPHandler) GetAuthenticationLogs(c *gin.Context)
GET /api/v1/ldap/logs/auth.
func (*LDAPHandler) GetConfiguration ¶
func (h *LDAPHandler) GetConfiguration(c *gin.Context)
GET /api/v1/ldap/config.
func (*LDAPHandler) GetGroupMappings ¶
func (h *LDAPHandler) GetGroupMappings(c *gin.Context)
GET /api/v1/ldap/mappings/groups.
func (*LDAPHandler) GetGroups ¶
func (h *LDAPHandler) GetGroups(c *gin.Context)
GET /api/v1/ldap/groups.
func (*LDAPHandler) GetSyncStatus ¶
func (h *LDAPHandler) GetSyncStatus(c *gin.Context)
GET /api/v1/ldap/sync/status.
func (*LDAPHandler) GetUser ¶
func (h *LDAPHandler) GetUser(c *gin.Context)
GET /api/v1/ldap/users/:username.
func (*LDAPHandler) GetUserMappings ¶
func (h *LDAPHandler) GetUserMappings(c *gin.Context)
GET /api/v1/ldap/mappings/users.
func (*LDAPHandler) ImportUsers ¶
func (h *LDAPHandler) ImportUsers(c *gin.Context)
POST /api/v1/ldap/import/users.
func (*LDAPHandler) RegisterRoutes ¶
func (h *LDAPHandler) RegisterRoutes(r *gin.RouterGroup)
RegisterRoutes registers LDAP routes.
func (*LDAPHandler) SearchUsers ¶
func (h *LDAPHandler) SearchUsers(c *gin.Context)
GET /api/v1/ldap/users/search.
func (*LDAPHandler) SyncUsers ¶
func (h *LDAPHandler) SyncUsers(c *gin.Context)
POST /api/v1/ldap/sync/users.
func (*LDAPHandler) TestConnection ¶
func (h *LDAPHandler) TestConnection(c *gin.Context)
POST /api/v1/ldap/test.
type PaginatedResponse ¶
type PaginatedResponse struct {
Success bool `json:"success"`
Data interface{} `json:"data"`
Pagination Pagination `json:"pagination"`
Error string `json:"error,omitempty"`
}
type Pagination ¶
type WebhookHandlers ¶
type WebhookHandlers struct {
// contains filtered or unexported fields
}
WebhookHandlers handles webhook-related API endpoints.
func NewWebhookHandlers ¶
func NewWebhookHandlers(webhookManager *webhook.Manager) *WebhookHandlers
NewWebhookHandlers creates a new webhook handlers instance.
func (*WebhookHandlers) SetupWebhookRoutes ¶
func (h *WebhookHandlers) SetupWebhookRoutes(router *APIRouter, adminRoutes *gin.RouterGroup)
SetupWebhookRoutes sets up webhook API routes.
Source Files
¶
- handlers_admin.go
- handlers_agent.go
- handlers_attachments.go
- handlers_core.go
- handlers_dashboard.go
- handlers_files.go
- handlers_history.go
- handlers_merge.go
- handlers_priorities.go
- handlers_queues.go
- handlers_search.go
- handlers_sla.go
- handlers_tickets.go
- handlers_users.go
- handlers_webhooks.go
- incident_handlers.go
- ldap.go
- router.go