http

package
v0.7.1 Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2025 License: Apache-2.0 Imports: 46 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AuthorizeWithPolicyForTest added in v0.1.0

func AuthorizeWithPolicyForTest(policy interfaces.PolicyClient, noAuthorization bool) func(http.Handler) http.Handler

AuthorizeWithPolicyForTest is exported for testing purposes

Types

type AsyncAlertHookConfig added in v0.3.0

type AsyncAlertHookConfig struct {
	Raw    bool
	PubSub bool
	SNS    bool
}

AsyncAlertHookConfig represents configuration for asynchronous alert hooks

type AuthUseCase

type AuthUseCase = usecase.AuthUseCaseInterface

type Options

type Options func(*Server)

func WithAsyncAlertHook added in v0.3.0

func WithAsyncAlertHook(cfg *AsyncAlertHookConfig) Options

func WithAuthUseCase

func WithAuthUseCase(authUC AuthUseCase) Options

func WithGraphQLRepo

func WithGraphQLRepo(repo interfaces.Repository) Options

func WithGraphiQL

func WithGraphiQL(enabled bool) Options

func WithNoAuthorization added in v0.1.0

func WithNoAuthorization(disabled bool) Options

func WithPolicy

func WithPolicy(policy interfaces.PolicyClient) Options

func WithSlackService

func WithSlackService(slackService *slack.Service) Options

func WithSlackVerifier

func WithSlackVerifier(verifier slack_model.PayloadVerifier) Options

func WithWebSocketHandler added in v0.1.0

func WithWebSocketHandler(handler *websocket_controller.Handler) Options

type SNSMessage

type SNSMessage struct {
	Type             string    `json:"Type"`
	MessageId        string    `json:"MessageId"`
	Token            string    `json:"Token"`
	TopicArn         string    `json:"TopicArn"`
	Message          string    `json:"Message"`
	Timestamp        time.Time `json:"Timestamp"`
	SignatureVersion string    `json:"SignatureVersion"`
	Signature        string    `json:"Signature"`
	SigningCertURL   string    `json:"SigningCertURL"`
	SubscribeURL     string    `json:"SubscribeURL"`
}

type Server

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

func New

func New(uc UseCase, opts ...Options) *Server

func (*Server) ServeHTTP

func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request)

type UserProfile

type UserProfile struct {
	Name string `json:"name"`
}

Jump to

Keyboard shortcuts

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