api

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Sep 29, 2025 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	MsgNotFound    = "Not found"
	MsgInavlidUUID = "Invalid uuid"
)

Functions

func ValidateRequest added in v0.8.0

func ValidateRequest(r *http.Request, defaults map[string]interface{}, target entities.Schema) error

Types

type API

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

func NewAPI

func NewAPI(opts Options) *API

func (*API) CreateEndpoint

func (api *API) CreateEndpoint(w http.ResponseWriter, r *http.Request)

func (*API) CreateEvent

func (api *API) CreateEvent(w http.ResponseWriter, r *http.Request)

func (*API) CreatePlugin added in v0.2.0

func (api *API) CreatePlugin(w http.ResponseWriter, r *http.Request)

func (*API) CreateSource

func (api *API) CreateSource(w http.ResponseWriter, r *http.Request)

func (*API) CreateWorkspace

func (api *API) CreateWorkspace(w http.ResponseWriter, r *http.Request)

func (*API) DeleteEndpoint

func (api *API) DeleteEndpoint(w http.ResponseWriter, r *http.Request)

func (*API) DeletePlugin added in v0.2.0

func (api *API) DeletePlugin(w http.ResponseWriter, r *http.Request)

func (*API) DeleteSource

func (api *API) DeleteSource(w http.ResponseWriter, r *http.Request)

func (*API) DeleteWorkspace

func (api *API) DeleteWorkspace(w http.ResponseWriter, r *http.Request)

func (*API) Dump added in v0.4.0

func (api *API) Dump(w http.ResponseWriter, r *http.Request)

func (*API) GetAttempt

func (api *API) GetAttempt(w http.ResponseWriter, r *http.Request)

func (*API) GetEndpoint

func (api *API) GetEndpoint(w http.ResponseWriter, r *http.Request)

func (*API) GetEvent

func (api *API) GetEvent(w http.ResponseWriter, r *http.Request)

func (*API) GetPlugin added in v0.2.0

func (api *API) GetPlugin(w http.ResponseWriter, r *http.Request)

func (*API) GetSource

func (api *API) GetSource(w http.ResponseWriter, r *http.Request)

func (*API) GetWorkspace

func (api *API) GetWorkspace(w http.ResponseWriter, r *http.Request)

func (*API) Handler

func (api *API) Handler() http.Handler

Handler returns a http.Handler

func (*API) Index

func (api *API) Index(w http.ResponseWriter, r *http.Request)

func (*API) PageAttempt

func (api *API) PageAttempt(w http.ResponseWriter, r *http.Request)

func (*API) PageEndpoint

func (api *API) PageEndpoint(w http.ResponseWriter, r *http.Request)

func (*API) PageEvent

func (api *API) PageEvent(w http.ResponseWriter, r *http.Request)

func (*API) PagePlugin added in v0.2.0

func (api *API) PagePlugin(w http.ResponseWriter, r *http.Request)

func (*API) PageSource

func (api *API) PageSource(w http.ResponseWriter, r *http.Request)

func (*API) PageWorkspace

func (api *API) PageWorkspace(w http.ResponseWriter, r *http.Request)

func (*API) RetryEvent added in v0.2.0

func (api *API) RetryEvent(w http.ResponseWriter, r *http.Request)

func (*API) Sync added in v0.4.0

func (api *API) Sync(w http.ResponseWriter, r *http.Request)

func (*API) UpdateEndpoint

func (api *API) UpdateEndpoint(w http.ResponseWriter, r *http.Request)

func (*API) UpdatePlugin added in v0.2.0

func (api *API) UpdatePlugin(w http.ResponseWriter, r *http.Request)

func (*API) UpdateSource

func (api *API) UpdateSource(w http.ResponseWriter, r *http.Request)

func (*API) UpdateWorkspace

func (api *API) UpdateWorkspace(w http.ResponseWriter, r *http.Request)

type IndexResponse added in v0.8.0

type IndexResponse struct {
	Version       string         `json:"version"`
	Message       string         `json:"message"`
	Configuration *config.Config `json:"configuration"`
}

type Options added in v0.8.0

type Options struct {
	Config      *config.Config
	DB          *db.DB
	Dispatcher  *dispatcher.Dispatcher
	Middlewares []mux.MiddlewareFunc
	EventBus    eventbus.Bus
}

type Pagination

type Pagination[T any] struct {
	Total int64 `json:"total"`
	Data  []T   `json:"data"`
}

func NewPagination

func NewPagination[T any](total int64, data []T) *Pagination[T]

Jump to

Keyboard shortcuts

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