Documentation
¶
Overview ¶
Package wire is the public representation of what Arnakoff answers: a report and the list of sources, as the contract api/openapi.yaml describes them. The HTTP API and the MCP server share it, so that both answer with the same fields and the same wording.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InvalidInput ¶
InvalidInput returns why an input of kind k, KindAuto when it was detected, is refused.
Types ¶
type Report ¶
type Report struct {
Input string `json:"input"`
Type string `json:"type"`
CheckedAt string `json:"checked_at"`
Summary *string `json:"summary"`
Signals []Signal `json:"signals"`
Sources []SourceState `json:"sources"`
}
Report is a report as the contract's Report schema describes it.
type Signal ¶
type Signal struct {
Code string `json:"code"`
Level string `json:"level"`
Message string `json:"message"`
Advice string `json:"advice,omitempty"`
Source string `json:"source"`
SourceURL string `json:"source_url"`
ObservedAt string `json:"observed_at"`
}
Signal is a signal as the contract's Signal schema describes it.
type Source ¶
type Source struct {
Name string `json:"name"`
Publisher string `json:"publisher"`
Licence string `json:"licence"`
URL string `json:"url"`
Status string `json:"status"`
UpdatedAt *string `json:"updated_at"`
Entries *int `json:"entries"`
}
Source is a source as the contract's Source schema describes it. UpdatedAt and Entries are null for a source that is not synced.
type SourceList ¶
type SourceList struct {
Sources []Source `json:"sources"`
}
SourceList is the list of sources, the contract's SourceList.
func SourcesOf ¶
func SourcesOf(listed []app.ListedSource) SourceList
SourcesOf returns the list of the sources listed, in their order.
type SourceState ¶
SourceState is a source state as the contract's SourceState schema describes it.