MCPcopy Create free account
hub / github.com/Mnexa-AI/e2a / handleGetWebhook

Method handleGetWebhook

internal/httpapi/webhooks.go:530–540  ·  view source on GitHub ↗
(ctx context.Context, in *WebhookIDParam)

Source from the content-addressed store, hash-verified

528}
529
530func (s *Server) handleGetWebhook(ctx context.Context, in *WebhookIDParam) (*webhookOutput, error) {
531 user, err := s.requireAccountUser(ctx)
532 if err != nil {
533 return nil, err
534 }
535 wh, err := s.deps.GetWebhook(ctx, in.ID, user.ID)
536 if err != nil || wh == nil {
537 return nil, NewError(http.StatusNotFound, "not_found", "webhook not found")
538 }
539 return &webhookOutput{Body: webhookView(wh)}, nil
540}
541
542type deleteWebhookOutput struct{}
543

Callers

nothing calls this directly

Calls 3

requireAccountUserMethod · 0.95
NewErrorFunction · 0.85
webhookViewFunction · 0.85

Tested by

no test coverage detected