api

package
v16.16.0 Latest Latest
Warning

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

Go to latest
Published: Jun 7, 2024 License: Apache-2.0 Imports: 28 Imported by: 0

Documentation

Overview

Package api implements various handlers for the API routes

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Swagger

func Swagger(c echo.Context) error

Swagger returns swagger UI for this API @Summary Swagger UI for this API @Description Swagger UI for this API @ID swagger @Produce text/html @Success 200 {string} string "" @Router /api/swagger [get]

Types

type AboutHandler

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

The AboutHandler type provides handler functions for retrieving details about the API version and build infos.

func NewAbout

func NewAbout(restream restream.Restreamer, auths []string) *AboutHandler

NewAbout returns a new About type

func (*AboutHandler) About

func (p *AboutHandler) About(c echo.Context) error

About returns API version and build infos @Summary API version and build infos @Description API version and build infos in case auth is valid or not required. If auth is required, just the name field is populated. @ID about @Produce json @Success 200 {object} api.About @Security ApiKeyAuth @Router /api [get]

type ConfigHandler

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

The ConfigHandler type provides handler functions for reading and manipulating the current config.

func NewConfig

func NewConfig(store cfgstore.Store) *ConfigHandler

NewConfig return a new Config type. You have to provide a valid config store.

func (*ConfigHandler) Get

func (p *ConfigHandler) Get(c echo.Context) error

Get returns the currently active Restreamer configuration @Summary Retrieve the currently active Restreamer configuration @Description Retrieve the currently active Restreamer configuration @Tags v16.7.2 @ID config-3-get @Produce json @Success 200 {object} api.Config @Security ApiKeyAuth @Router /api/v3/config [get]

func (*ConfigHandler) Reload

func (p *ConfigHandler) Reload(c echo.Context) error

Reload will reload the currently active configuration @Summary Reload the currently active configuration @Description Reload the currently active configuration. This will trigger a restart of the Core. @Tags v16.7.2 @ID config-3-reload @Produce json @Success 200 {string} string @Security ApiKeyAuth @Router /api/v3/config/reload [get]

func (*ConfigHandler) Set

func (p *ConfigHandler) Set(c echo.Context) error

Set will set the given configuration as new active configuration @Summary Update the current Restreamer configuration @Description Update the current Restreamer configuration by providing a complete or partial configuration. Fields that are not provided will not be changed. @Tags v16.7.2 @ID config-3-set @Accept json @Produce json @Param config body api.SetConfig true "Restreamer configuration" @Success 200 {string} string @Failure 400 {object} api.Error @Failure 409 {object} api.ConfigError @Security ApiKeyAuth @Router /api/v3/config [put]

type FSConfig added in v16.12.0

type FSConfig struct {
	Type       string
	Mountpoint string
	Handler    *handler.FSHandler
}

type FSHandler added in v16.12.0

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

The FSHandler type provides handlers for manipulating a filesystem

func NewFS added in v16.12.0

func NewFS(filesystems map[string]FSConfig) *FSHandler

NewFS return a new FSHanlder type. You have to provide a filesystem to act on.

func (*FSHandler) DeleteFile added in v16.12.0

func (h *FSHandler) DeleteFile(c echo.Context) error

DeleteFileAPI removes a file from a filesystem @Summary Remove a file from a filesystem @Description Remove a file from a filesystem @Tags v16.7.2 @ID filesystem-3-delete-file @Produce text/plain @Param storage path string true "Name of the filesystem" @Param filepath path string true "Path to file" @Success 200 {string} string @Failure 404 {object} api.Error @Security ApiKeyAuth @Router /api/v3/fs/{storage}/{filepath} [delete]

func (*FSHandler) GetFile added in v16.12.0

func (h *FSHandler) GetFile(c echo.Context) error

GetFileAPI returns the file at the given path @Summary Fetch a file from a filesystem @Description Fetch a file from a filesystem @Tags v16.7.2 @ID filesystem-3-get-file @Produce application/data @Produce json @Param storage path string true "Name of the filesystem" @Param filepath path string true "Path to file" @Success 200 {file} byte @Success 301 {string} string @Failure 404 {object} api.Error @Security ApiKeyAuth @Router /api/v3/fs/{storage}/{filepath} [get]

func (*FSHandler) List added in v16.12.0

func (h *FSHandler) List(c echo.Context) error

List lists all registered filesystems @Summary List all registered filesystems @Description Listall registered filesystems @Tags v16.12.0 @ID filesystem-3-list @Produce json @Success 200 {array} api.FilesystemInfo @Security ApiKeyAuth @Router /api/v3/fs [get]

func (*FSHandler) ListFiles added in v16.12.0

func (h *FSHandler) ListFiles(c echo.Context) error

ListFiles lists all files on a filesystem @Summary List all files on a filesystem @Description List all files on a filesystem. The listing can be ordered by name, size, or date of last modification in ascending or descending order. @Tags v16.7.2 @ID filesystem-3-list-files @Produce json @Param storage path string true "Name of the filesystem" @Param glob query string false "glob pattern for file names" @Param sort query string false "none, name, size, lastmod" @Param order query string false "asc, desc" @Success 200 {array} api.FileInfo @Security ApiKeyAuth @Router /api/v3/fs/{storage} [get]

func (*FSHandler) PutFile added in v16.12.0

func (h *FSHandler) PutFile(c echo.Context) error

PutFileAPI adds or overwrites a file at the given path @Summary Add a file to a filesystem @Description Writes or overwrites a file on a filesystem @Tags v16.7.2 @ID filesystem-3-put-file @Accept application/data @Produce text/plain @Produce json @Param storage path string true "Name of the filesystem" @Param filepath path string true "Path to file" @Param data body []byte true "File data" @Success 201 {string} string @Success 204 {string} string @Failure 507 {object} api.Error @Security ApiKeyAuth @Router /api/v3/fs/{storage}/{filepath} [put]

type GraphHandler

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

func NewGraph

func NewGraph(resolver resolver.Resolver, path string) *GraphHandler

NewRestream return a new Restream type. You have to provide a valid Restreamer instance.

func (*GraphHandler) Playground

func (g *GraphHandler) Playground(c echo.Context) error

Load GraphQL playground @Summary Load GraphQL playground @Description Load GraphQL playground @ID graph-playground @Produce html @Success 200 @Security ApiKeyAuth @Router /api/graph [get]

func (*GraphHandler) Query

func (g *GraphHandler) Query(c echo.Context) error

Query the GraphAPI @Summary Query the GraphAPI @Description Query the GraphAPI @ID graph-query @Accept json @Produce json @Param query body api.GraphQuery true "GraphQL Query" @Success 200 {object} api.GraphResponse @Failure 400 {object} api.GraphResponse @Security ApiKeyAuth @Router /api/graph/query [post]

type LogHandler

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

The LogHandler type provides handler functions for reading the application log

func NewLog

func NewLog(buffer log.BufferWriter) *LogHandler

NewLog return a new Log type. You have to provide log buffer.

func (*LogHandler) Log

func (p *LogHandler) Log(c echo.Context) error

Log returns the last log lines of the Restreamer application @Summary Application log @Description Get the last log lines of the Restreamer application @Tags v16.7.2 @ID log-3 @Param format query string false "Format of the list of log events (*console, raw)" @Produce json @Success 200 {array} api.LogEvent "application log" @Success 200 {array} string "application log" @Security ApiKeyAuth @Router /api/v3/log [get]

type MetricsConfig

type MetricsConfig struct {
	Metrics monitor.HistoryReader
}

type MetricsHandler

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

The MetricsHandler type provides handlers for the widget API

func NewMetrics

func NewMetrics(config MetricsConfig) *MetricsHandler

NewWidget return a new Widget type

func (*MetricsHandler) Describe added in v16.10.0

func (r *MetricsHandler) Describe(c echo.Context) error

Describe the known metrics @Summary List all known metrics with their description and labels @Description List all known metrics with their description and labels @Tags v16.10.0 @ID metrics-3-describe @Produce json @Success 200 {array} api.MetricsDescription @Security ApiKeyAuth @Router /api/v3/metrics [get]

func (*MetricsHandler) Metrics

func (r *MetricsHandler) Metrics(c echo.Context) error

Query the collected metrics @Summary Query the collected metrics @Description Query the collected metrics @Tags v16.7.2 @ID metrics-3-metrics @Accept json @Produce json @Param config body api.MetricsQuery true "Metrics query" @Success 200 {object} api.MetricsResponse @Failure 400 {object} api.Error @Security ApiKeyAuth @Router /api/v3/metrics [post]

type PlayoutHandler

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

The PlayoutHandler type provides handlers for accessing the playout API of a process

func NewPlayout

func NewPlayout(restream restream.Restreamer) *PlayoutHandler

NewPlayout returns a new Playout type. You have to provide a Restreamer instance.

func (*PlayoutHandler) EncodeErrorframe

func (h *PlayoutHandler) EncodeErrorframe(c echo.Context) error

EncodeErrorframe encodes the errorframe @Summary Encode the errorframe @Description Immediately encode the errorframe (if available and looping) @Tags v16.7.2 @ID process-3-playout-errorframencode @Produce text/plain @Produce json @Param id path string true "Process ID" @Param inputid path string true "Process Input ID" @Success 204 {string} string @Failure 404 {object} api.Error @Failure 500 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process/{id}/playout/{inputid}/errorframe/encode [get]

func (*PlayoutHandler) Keyframe

func (h *PlayoutHandler) Keyframe(c echo.Context) error

Keyframe returns the last keyframe @Summary Get the last keyframe @Description Get the last keyframe of an input of a process. The extension of the name determines the return type. @Tags v16.7.2 @ID process-3-playout-keyframe @Produce image/jpeg @Produce image/png @Produce json @Param id path string true "Process ID" @Param inputid path string true "Process Input ID" @Param name path string true "Any filename with an extension of .jpg or .png" @Success 200 {file} byte @Failure 404 {object} api.Error @Failure 500 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process/{id}/playout/{inputid}/keyframe/{name} [get]

func (*PlayoutHandler) ReopenInput

func (h *PlayoutHandler) ReopenInput(c echo.Context) error

ReopenInput closes the current input stream @Summary Close the current input stream @Description Close the current input stream such that it will be automatically re-opened @Tags v16.7.2 @ID process-3-playout-reopen-input @Produce plain @Param id path string true "Process ID" @Param inputid path string true "Process Input ID" @Success 200 {string} string @Failure 404 {object} api.Error @Failure 500 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process/{id}/playout/{inputid}/reopen [get]

func (*PlayoutHandler) SetErrorframe

func (h *PlayoutHandler) SetErrorframe(c echo.Context) error

SetErrorframe sets an errorframe @Summary Upload an error frame @Description Upload an error frame which will be encoded immediately @Tags v16.7.2 @ID process-3-playout-errorframe @Produce text/plain @Produce json @Accept application/octet-stream @Param id path string true "Process ID" @Param inputid path string true "Process Input ID" @Param name path string true "Any filename with a suitable extension" @Param image body []byte true "Image to be used a error frame" @Success 204 {string} string @Failure 404 {object} api.Error @Failure 500 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process/{id}/playout/{inputid}/errorframe/{name} [post]

func (*PlayoutHandler) SetStream

func (h *PlayoutHandler) SetStream(c echo.Context) error

SetStream replaces the current stream @Summary Switch to a new stream @Description Replace the current stream with the one from the given URL. The switch will only happen if the stream parameters match. @Tags v16.7.2 @ID process-3-playout-stream @Produce text/plain @Produce json @Accept text/plain @Param id path string true "Process ID" @Param inputid path string true "Process Input ID" @Param url body string true "URL of the new stream" @Success 204 {string} string @Failure 404 {object} api.Error @Failure 500 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process/{id}/playout/{inputid}/stream [put]

func (*PlayoutHandler) Status

func (h *PlayoutHandler) Status(c echo.Context) error

Status return the current playout status @Summary Get the current playout status @Description Get the current playout status of an input of a process @Tags v16.7.2 @ID process-3-playout-status @Produce json @Param id path string true "Process ID" @Param inputid path string true "Process Input ID" @Success 200 {object} api.PlayoutStatus @Failure 404 {object} api.Error @Failure 500 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process/{id}/playout/{inputid}/status [get]

type RTMPHandler

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

The RTMPHandler type provides a handler for retrieving details from the RTMPHandler server

func NewRTMP

func NewRTMP(rtmp rtmp.Server) *RTMPHandler

NewRTMP returns a new RTMP type. You have to provide a RTMP server instance.

func (*RTMPHandler) ListChannels

func (rtmph *RTMPHandler) ListChannels(c echo.Context) error

ListChannels lists all currently publishing RTMP streams @Summary List all publishing RTMP streams @Description List all currently publishing RTMP streams. @Tags v16.7.2 @ID rtmp-3-list-channels @Produce json @Success 200 {array} api.RTMPChannel @Security ApiKeyAuth @Router /api/v3/rtmp [get]

type RestreamHandler

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

The RestreamHandler type provides functions to interact with a Restreamer instance

func NewRestream

func NewRestream(restream restream.Restreamer) *RestreamHandler

NewRestream return a new Restream type. You have to provide a valid Restreamer instance.

func (*RestreamHandler) Add

func (h *RestreamHandler) Add(c echo.Context) error

Add adds a new process @Summary Add a new process @Description Add a new FFmpeg process @Tags v16.7.2 @ID process-3-add @Accept json @Produce json @Param config body api.ProcessConfig true "Process config" @Success 200 {object} api.ProcessConfig @Failure 400 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process [post]

func (*RestreamHandler) Command

func (h *RestreamHandler) Command(c echo.Context) error

Command issues a command to a process @Summary Issue a command to a process @Description Issue a command to a process: start, stop, reload, restart @Tags v16.7.2 @ID process-3-command @Accept json @Produce json @Param id path string true "Process ID" @Param command body api.Command true "Process command" @Success 200 {string} string @Failure 400 {object} api.Error @Failure 404 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process/{id}/command [put]

func (*RestreamHandler) Delete

func (h *RestreamHandler) Delete(c echo.Context) error

Delete deletes the process with the given ID @Summary Delete a process by its ID @Description Delete a process by its ID @Tags v16.7.2 @ID process-3-delete @Produce json @Param id path string true "Process ID" @Success 200 {string} string @Failure 404 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process/{id} [delete]

func (*RestreamHandler) Get

func (h *RestreamHandler) Get(c echo.Context) error

Get returns the process with the given ID @Summary List a process by its ID @Description List a process by its ID. Use the filter parameter to specifiy the level of detail of the output. @Tags v16.7.2 @ID process-3-get @Produce json @Param id path string true "Process ID" @Param filter query string false "Comma separated list of fields (config, state, report, metadata) to be part of the output. If empty, all fields will be part of the output" @Success 200 {object} api.Process @Failure 404 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process/{id} [get]

func (*RestreamHandler) GetAll

func (h *RestreamHandler) GetAll(c echo.Context) error

GetAll returns all known processes @Summary List all known processes @Description List all known processes. Use the query parameter to filter the listed processes. @Tags v16.7.2 @ID process-3-get-all @Produce json @Param filter query string false "Comma separated list of fields (config, state, report, metadata) that will be part of the output. If empty, all fields will be part of the output." @Param reference query string false "Return only these process that have this reference value. If empty, the reference will be ignored." @Param id query string false "Comma separated list of process ids to list. Overrides the reference. If empty all IDs will be returned." @Param idpattern query string false "Glob pattern for process IDs. If empty all IDs will be returned. Intersected with results from refpattern." @Param refpattern query string false "Glob pattern for process references. If empty all IDs will be returned. Intersected with results from idpattern." @Success 200 {array} api.Process @Security ApiKeyAuth @Router /api/v3/process [get]

func (*RestreamHandler) GetConfig

func (h *RestreamHandler) GetConfig(c echo.Context) error

GetConfig returns the configuration of a process @Summary Get the configuration of a process @Description Get the configuration of a process. This is the configuration as provided by Add or Update. @Tags v16.7.2 @ID process-3-get-config @Produce json @Param id path string true "Process ID" @Success 200 {object} api.ProcessConfig @Failure 404 {object} api.Error @Failure 400 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process/{id}/config [get]

func (*RestreamHandler) GetMetadata

func (h *RestreamHandler) GetMetadata(c echo.Context) error

GetMetadata returns the metadata stored with the Restreamer @Summary Retrieve JSON metadata from a key @Description Retrieve the previously stored JSON metadata under the given key. If the key is empty, all metadata will be returned. @Tags v16.7.2 @ID metadata-3-get @Produce json @Param key path string true "Key for data store" @Success 200 {object} api.Metadata @Failure 404 {object} api.Error @Failure 400 {object} api.Error @Security ApiKeyAuth @Router /api/v3/metadata/{key} [get]

func (*RestreamHandler) GetProcessMetadata

func (h *RestreamHandler) GetProcessMetadata(c echo.Context) error

GetProcessMetadata returns the metadata stored with a process @Summary Retrieve JSON metadata stored with a process under a key @Description Retrieve the previously stored JSON metadata under the given key. If the key is empty, all metadata will be returned. @Tags v16.7.2 @ID process-3-get-process-metadata @Produce json @Param id path string true "Process ID" @Param key path string true "Key for data store" @Success 200 {object} api.Metadata @Failure 404 {object} api.Error @Failure 400 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process/{id}/metadata/{key} [get]

func (*RestreamHandler) GetReport

func (h *RestreamHandler) GetReport(c echo.Context) error

GetReport return the current log and the log history of a process @Summary Get the logs of a process @Description Get the logs and the log history of a process. @Tags v16.7.2 @ID process-3-get-report @Produce json @Param id path string true "Process ID" @Success 200 {object} api.ProcessReport @Failure 404 {object} api.Error @Failure 400 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process/{id}/report [get]

func (*RestreamHandler) GetState

func (h *RestreamHandler) GetState(c echo.Context) error

GetState returns the current state of a process @Summary Get the state of a process @Description Get the state and progress data of a process. @Tags v16.7.2 @ID process-3-get-state @Produce json @Param id path string true "Process ID" @Success 200 {object} api.ProcessState @Failure 404 {object} api.Error @Failure 400 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process/{id}/state [get]

func (*RestreamHandler) Probe

func (h *RestreamHandler) Probe(c echo.Context) error

Probe probes a process @Summary Probe a process @Description Probe an existing process to get a detailed stream information on the inputs. @Tags v16.7.2 @ID process-3-probe @Produce json @Param id path string true "Process ID" @Success 200 {object} api.Probe @Security ApiKeyAuth @Router /api/v3/process/{id}/probe [get]

func (*RestreamHandler) ReloadSkills

func (h *RestreamHandler) ReloadSkills(c echo.Context) error

ReloadSkills will refresh the FFmpeg capabilities @Summary Refresh FFmpeg capabilities @Description Refresh the available FFmpeg capabilities. @Tags v16.7.2 @ID skills-3-reload @Produce json @Success 200 {object} api.Skills @Security ApiKeyAuth @Router /api/v3/skills/reload [get]

func (*RestreamHandler) SetMetadata

func (h *RestreamHandler) SetMetadata(c echo.Context) error

SetMetadata stores metadata with the Restreamer @Summary Add JSON metadata under the given key @Description Add arbitrary JSON metadata under the given key. If the key exists, all already stored metadata with this key will be overwritten. If the key doesn't exist, it will be created. @Tags v16.7.2 @ID metadata-3-set @Produce json @Param key path string true "Key for data store" @Param data body api.Metadata true "Arbitrary JSON data" @Success 200 {object} api.Metadata @Failure 400 {object} api.Error @Security ApiKeyAuth @Router /api/v3/metadata/{key} [put]

func (*RestreamHandler) SetProcessMetadata

func (h *RestreamHandler) SetProcessMetadata(c echo.Context) error

SetProcessMetadata stores metadata with a process @Summary Add JSON metadata with a process under the given key @Description Add arbitrary JSON metadata under the given key. If the key exists, all already stored metadata with this key will be overwritten. If the key doesn't exist, it will be created. @Tags v16.7.2 @ID process-3-set-process-metadata @Produce json @Param id path string true "Process ID" @Param key path string true "Key for data store" @Param data body api.Metadata true "Arbitrary JSON data. The null value will remove the key and its contents" @Success 200 {object} api.Metadata @Failure 404 {object} api.Error @Failure 400 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process/{id}/metadata/{key} [put]

func (*RestreamHandler) Skills

func (h *RestreamHandler) Skills(c echo.Context) error

Skills returns the detected FFmpeg capabilities @Summary FFmpeg capabilities @Description List all detected FFmpeg capabilities. @Tags v16.7.2 @ID skills-3 @Produce json @Success 200 {object} api.Skills @Security ApiKeyAuth @Router /api/v3/skills [get]

func (*RestreamHandler) Update

func (h *RestreamHandler) Update(c echo.Context) error

Update replaces an existing process @Summary Replace an existing process @Description Replace an existing process. @Tags v16.7.2 @ID process-3-update @Accept json @Produce json @Param id path string true "Process ID" @Param config body api.ProcessConfig true "Process config" @Success 200 {object} api.ProcessConfig @Failure 400 {object} api.Error @Failure 404 {object} api.Error @Security ApiKeyAuth @Router /api/v3/process/{id} [put]

type SRTHandler

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

The SRTHandler type provides a handler for retrieving details from the SRTHandler server

func NewSRT

func NewSRT(srt srt.Server) *SRTHandler

NewSRT returns a new SRT type. You have to provide a SRT server instance.

func (*SRTHandler) ListChannels

func (srth *SRTHandler) ListChannels(c echo.Context) error

ListChannels lists all currently publishing SRT streams @Summary List all publishing SRT treams @Description List all currently publishing SRT streams. This endpoint is EXPERIMENTAL and may change in future. @Tags v16.9.0 @ID srt-3-list-channels @Produce json @Success 200 {array} api.SRTChannels @Security ApiKeyAuth @Router /api/v3/srt [get]

type SessionHandler

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

The SessionHandler type provides handlers to retrieve session information

func NewSession

func NewSession(registry session.RegistryReader) *SessionHandler

NewSession returns a new Session type. You have to provide a session registry.

func (*SessionHandler) Active

func (s *SessionHandler) Active(c echo.Context) error

Active returns a list of active sessions @Summary Get a minimal summary of all active sessions @Description Get a minimal summary of all active sessions (i.e. number of sessions, bandwidth). @Tags v16.7.2 @ID session-3-current @Produce json @Security ApiKeyAuth @Param collectors query string false "Comma separated list of collectors" @Success 200 {object} api.SessionsActive "Active sessions listing" @Router /api/v3/session/active [get]

func (*SessionHandler) Summary

func (s *SessionHandler) Summary(c echo.Context) error

Summary returns a summary of all active and past sessions @Summary Get a summary of all active and past sessions @Description Get a summary of all active and past sessions of the given collector. @Tags v16.7.2 @ID session-3-summary @Produce json @Security ApiKeyAuth @Param collectors query string false "Comma separated list of collectors" @Success 200 {object} api.SessionsSummary "Sessions summary" @Router /api/v3/session [get]

type WidgetConfig

type WidgetConfig struct {
	Restream restream.Restreamer
	Registry session.RegistryReader
}

type WidgetHandler

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

The WidgetHandler type provides handlers for the widget API

func NewWidget

func NewWidget(config WidgetConfig) *WidgetHandler

NewWidget return a new Widget type

func (*WidgetHandler) Get

func (w *WidgetHandler) Get(c echo.Context) error

Get returns minimal public statistics about a process @Summary Fetch minimal statistics about a process @Description Fetch minimal statistics about a process, which is not protected by any auth. @Tags v16.7.2 @ID widget-3-get @Produce json @Param id path string true "ID of a process" @Success 200 {object} api.WidgetProcess @Failure 404 {object} api.Error @Router /api/v3/widget/process/{id} [get]

Jump to

Keyboard shortcuts

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