Help us shape the future of Go! Take the 2026 Go Developer Survey

generated

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Aug 29, 2026 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package generated provides primitives to interact with the openapi HTTP API.

Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.5.1 DO NOT EDIT.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EdgeHistory

type EdgeHistory struct {
	BucketDurationMs int64     `json:"bucketDurationMs"`
	EdgeId           string    `json:"edgeId"`
	From             time.Time `json:"from"`

	// LastTrafficAt Exact server-received time of the last traffic in the selected window. Omitted when the window is empty.
	LastTrafficAt       *time.Time           `json:"lastTrafficAt,omitempty"`
	PathAnchor          *PathEvent           `json:"pathAnchor,omitempty"`
	PathEvents          []PathEvent          `json:"pathEvents"`
	PathEventsTruncated bool                 `json:"pathEventsTruncated"`
	Source              HistoryNodeReference `json:"source"`
	Target              HistoryNodeReference `json:"target"`
	To                  time.Time            `json:"to"`
	Traffic             []TrafficBucket      `json:"traffic"`
	TrafficTruncated    bool                 `json:"trafficTruncated"`
}

EdgeHistory defines model for EdgeHistory.

type GetEdgeHistoryParams

type GetEdgeHistoryParams struct {
	Window HistoryWindow `form:"window" json:"window"`
}

GetEdgeHistoryParams defines parameters for GetEdgeHistory.

type GetHistoryNodesParams

type GetHistoryNodesParams struct {
	Window HistoryWindow `form:"window" json:"window"`
}

GetHistoryNodesParams defines parameters for GetHistoryNodes.

type HistoryEdgePage

type HistoryEdgePage struct {
	Edges      []HistoryEdgeSummary `json:"edges"`
	NextCursor *string              `json:"nextCursor,omitempty"`
}

HistoryEdgePage defines model for HistoryEdgePage.

type HistoryEdgeSummary

type HistoryEdgeSummary struct {
	AToBBytes     int64                `json:"aToBBytes"`
	BToABytes     int64                `json:"bToABytes"`
	EdgeId        string               `json:"edgeId"`
	LastTrafficAt time.Time            `json:"lastTrafficAt"`
	Paths         []PathKind           `json:"paths"`
	Source        HistoryNodeReference `json:"source"`
	Target        HistoryNodeReference `json:"target"`
}

HistoryEdgeSummary defines model for HistoryEdgeSummary.

type HistoryNodeReference

type HistoryNodeReference struct {
	DnsName        *string         `json:"dnsName,omitempty"`
	Hostname       *string         `json:"hostname,omitempty"`
	Id             string          `json:"id"`
	IdentityStatus *IdentityStatus `json:"identityStatus,omitempty"`
	Label          string          `json:"label"`
	Os             *string         `json:"os,omitempty"`
}

HistoryNodeReference defines model for HistoryNodeReference.

type HistoryNodes

type HistoryNodes struct {
	Nodes []HistoryNodeReference `json:"nodes"`
}

HistoryNodes defines model for HistoryNodes.

type HistoryWindow

type HistoryWindow string

HistoryWindow defines model for HistoryWindow.

const (
	N15m HistoryWindow = "15m"
	N1h  HistoryWindow = "1h"
	N24h HistoryWindow = "24h"
	N6h  HistoryWindow = "6h"
	N7d  HistoryWindow = "7d"
)

Defines values for HistoryWindow.

type IdentityStatus added in v0.4.0

type IdentityStatus string

IdentityStatus defines model for IdentityStatus.

const (
	Anonymous IdentityStatus = "anonymous"
	Conflict  IdentityStatus = "conflict"
	Partial   IdentityStatus = "partial"
	Resolved  IdentityStatus = "resolved"
)

Defines values for IdentityStatus.

type ListHistoryEdgesParams

type ListHistoryEdgesParams struct {
	Window HistoryWindow `form:"window" json:"window"`
	NodeId *string       `form:"nodeId,omitempty" json:"nodeId,omitempty"`

	// Path Match when the path appeared at any point in the window.
	Path   *PathKind `form:"path,omitempty" json:"path,omitempty"`
	Cursor *string   `form:"cursor,omitempty" json:"cursor,omitempty"`
	Limit  *int      `form:"limit,omitempty" json:"limit,omitempty"`
}

ListHistoryEdgesParams defines parameters for ListHistoryEdges.

type NodeIdentity

type NodeIdentity struct {
	DiscoKey *string `json:"discoKey,omitempty"`
	DnsName  *string `json:"dnsName,omitempty"`
	Hostname *string `json:"hostname,omitempty"`
	NodeId   *string `json:"nodeId,omitempty"`
	NodeKey  *string `json:"nodeKey,omitempty"`

	// Os Reported operating system for display only; never identity evidence.
	Os           *string   `json:"os,omitempty"`
	StableNodeId *string   `json:"stableNodeId,omitempty"`
	TailscaleIps *[]string `json:"tailscaleIps,omitempty"`
}

NodeIdentity At least one stableNodeId, nodeId, nodeKey, discoKey, or Tailscale IP is required. Names are display fields and never merge nodes.

type ObservationProvenance

type ObservationProvenance struct {
	ClockSkewed bool            `json:"clockSkewed"`
	CollectedAt time.Time       `json:"collectedAt"`
	ObserverId  string          `json:"observerId"`
	Path        PathObservation `json:"path"`
	ReceivedAt  time.Time       `json:"receivedAt"`

	// RelaySession Sanitized third-party provenance; underlay endpoints are never exposed.
	RelaySession *RelaySessionProvenance `json:"relaySession,omitempty"`
}

ObservationProvenance defines model for ObservationProvenance.

type ObserverReport

type ObserverReport struct {
	CollectedAt         *time.Time `json:"collectedAt,omitempty"`
	InventoryGeneration string     `json:"inventoryGeneration"`

	// Observer At least one stableNodeId, nodeId, nodeKey, discoKey, or Tailscale IP is required. Names are display fields and never merge nodes.
	Observer NodeIdentity       `json:"observer"`
	Peers    *[]PeerObservation `json:"peers,omitempty"`
}

ObserverReport For hello and inventory_update, peers is the observer's complete current runtime peer view. For traffic_sample it is sparse and contains only peers with business byte deltas. observer_withdrawal forbids peers. collectedAt is the time for this observer inside a multi-observer envelope; legacy reports may omit it and use the envelope timestamp.

type ObserverState

type ObserverState struct {
	ClockSkewMs     int64     `json:"clockSkewMs"`
	ClockSkewed     bool      `json:"clockSkewed"`
	Hostname        string    `json:"hostname"`
	Id              string    `json:"id"`
	LastCollectedAt time.Time `json:"lastCollectedAt"`
	LastSeen        time.Time `json:"lastSeen"`
	Online          bool      `json:"online"`
}

ObserverState defines model for ObserverState.

type PathEvent

type PathEvent struct {
	Observations []ObservationProvenance `json:"observations"`
	ObservedAt   time.Time               `json:"observedAt"`
	Path         PathObservation         `json:"path"`
}

PathEvent defines model for PathEvent.

type PathKind

type PathKind string

PathKind defines model for PathKind.

const (
	Derp      PathKind = "derp"
	Direct    PathKind = "direct"
	PeerRelay PathKind = "peer_relay"
	Unknown   PathKind = "unknown"
)

Defines values for PathKind.

type PathObservation

type PathObservation struct {
	DerpRegion            *string  `json:"derpRegion,omitempty"`
	DirectEndpoint        *string  `json:"directEndpoint,omitempty"`
	Kind                  PathKind `json:"kind"`
	PeerRelayStableNodeId *string  `json:"peerRelayStableNodeId,omitempty"`
	PeerRelayVni          *int64   `json:"peerRelayVni,omitempty"`
}

PathObservation defines model for PathObservation.

type PeerObservation

type PeerObservation struct {
	LastActive time.Time       `json:"lastActive"`
	Path       PathObservation `json:"path"`

	// Peer At least one stableNodeId, nodeId, nodeKey, discoKey, or Tailscale IP is required. Names are display fields and never merge nodes.
	Peer    NodeIdentity `json:"peer"`
	RxBytes int64        `json:"rxBytes"`
	RxDelta int64        `json:"rxDelta"`

	// SampleDurationMs Zero for hello/inventory baselines; positive for traffic samples.
	SampleDurationMs int64 `json:"sampleDurationMs"`
	TxBytes          int64 `json:"txBytes"`
	TxDelta          int64 `json:"txDelta"`
}

PeerObservation defines model for PeerObservation.

type Problem

type Problem struct {
	Detail *string `json:"detail,omitempty"`
	Status int     `json:"status"`
	Title  string  `json:"title"`
}

Problem defines model for Problem.

type RelaySessionClient added in v0.4.0

type RelaySessionClient struct {
	DiscoShort *string `json:"discoShort,omitempty"`

	// Endpoint Current underlay endpoint; accepted only as volatile provenance.
	Endpoint *string `json:"endpoint,omitempty"`

	// Identity At least one stableNodeId, nodeId, nodeKey, discoKey, or Tailscale IP is required. Names are display fields and never merge nodes.
	Identity        *NodeIdentity `json:"identity,omitempty"`
	SessionClientId string        `json:"sessionClientId"`
}

RelaySessionClient One endpoint of a relay session. sessionClientId, discoShort, and endpoint are scoped hints and never global canonical identity aliases.

type RelaySessionObservation

type RelaySessionObservation struct {
	LastActive time.Time `json:"lastActive"`

	// Relay At least one stableNodeId, nodeId, nodeKey, discoKey, or Tailscale IP is required. Names are display fields and never merge nodes.
	Relay            NodeIdentity `json:"relay"`
	SampleDurationMs int64        `json:"sampleDurationMs"`
	SessionId        string       `json:"sessionId"`

	// Source One endpoint of a relay session. sessionClientId, discoShort, and endpoint are scoped hints and never global canonical identity aliases.
	Source              RelaySessionClient `json:"source"`
	SourceToTargetBytes int64              `json:"sourceToTargetBytes"`
	SourceToTargetDelta int64              `json:"sourceToTargetDelta"`

	// Target One endpoint of a relay session. sessionClientId, discoShort, and endpoint are scoped hints and never global canonical identity aliases.
	Target              RelaySessionClient `json:"target"`
	TargetToSourceBytes int64              `json:"targetToSourceBytes"`
	TargetToSourceDelta int64              `json:"targetToSourceDelta"`
	Vni                 int64              `json:"vni"`
}

RelaySessionObservation A Peer Relay observer's view of traffic between two Tailnet nodes. The logical edge is source-target while relay supplies third-party provenance.

type RelaySessionProvenance added in v0.4.0

type RelaySessionProvenance struct {
	SessionId            string         `json:"sessionId"`
	SourceIdentityStatus IdentityStatus `json:"sourceIdentityStatus"`
	TargetIdentityStatus IdentityStatus `json:"targetIdentityStatus"`
	Vni                  int64          `json:"vni"`
}

RelaySessionProvenance Sanitized third-party provenance; underlay endpoints are never exposed.

type ReportEnvelope

type ReportEnvelope struct {
	CollectedAt        time.Time                  `json:"collectedAt"`
	Kind               ReportKind                 `json:"kind"`
	Observers          *[]ObserverReport          `json:"observers,omitempty"`
	RelaySessions      *[]RelaySessionObservation `json:"relaySessions,omitempty"`
	ReportId           openapi_types.UUID         `json:"reportId"`
	ReporterInstanceId openapi_types.UUID         `json:"reporterInstanceId"`
	Sequence           int64                      `json:"sequence"`
	Version            int                        `json:"version"`
}

ReportEnvelope Normal observer messages contain observers. observer_withdrawal contains observer identities without peers. relay_session_update contains relaySessions instead; the server rejects envelopes that mix the forms.

type ReportKind

type ReportKind string

ReportKind defines model for ReportKind.

const (
	InventoryUpdate    ReportKind = "inventory_update"
	ObserverHeartbeat  ReportKind = "observer_heartbeat"
	ObserverHello      ReportKind = "observer_hello"
	ObserverWithdrawal ReportKind = "observer_withdrawal"
	RelaySessionUpdate ReportKind = "relay_session_update"
	TrafficSample      ReportKind = "traffic_sample"
)

Defines values for ReportKind.

type ReportReceipt

type ReportReceipt struct {
	Accepted             bool     `json:"accepted"`
	ControlStableNodeIds []string `json:"controlStableNodeIds"`
	HeartbeatIntervalMs  int64    `json:"heartbeatIntervalMs"`
	ResyncRequired       bool     `json:"resyncRequired"`
}

ReportReceipt defines model for ReportReceipt.

type ServerCapabilities added in v0.4.0

type ServerCapabilities struct {
	Features                 []string `json:"features"`
	ObserverProtocolVersions []int    `json:"observerProtocolVersions"`
}

ServerCapabilities defines model for ServerCapabilities.

type SubmitReportJSONRequestBody

type SubmitReportJSONRequestBody = ReportEnvelope

SubmitReportJSONRequestBody defines body for SubmitReport for application/json ContentType.

type Topology

type Topology struct {
	Edges       []TopologyEdge `json:"edges"`
	GeneratedAt time.Time      `json:"generatedAt"`

	// NextChangeAt Earliest known lifecycle deadline that can change this snapshot.
	NextChangeAt *time.Time      `json:"nextChangeAt,omitempty"`
	Nodes        []TopologyNode  `json:"nodes"`
	Observers    []ObserverState `json:"observers"`
}

Topology defines model for Topology.

type TopologyEdge

type TopologyEdge struct {
	AToBBytesPerSecond float64                 `json:"aToBBytesPerSecond"`
	BToABytesPerSecond float64                 `json:"bToABytesPerSecond"`
	Conflicts          *[]PathObservation      `json:"conflicts,omitempty"`
	Id                 string                  `json:"id"`
	LastActive         time.Time               `json:"lastActive"`
	Observations       []ObservationProvenance `json:"observations"`
	Path               PathObservation         `json:"path"`
	Source             string                  `json:"source"`
	State              TopologyEdgeState       `json:"state"`

	// SystemTelemetry True when either endpoint is the dedicated Tailpath control identity.
	SystemTelemetry bool   `json:"systemTelemetry"`
	Target          string `json:"target"`
}

TopologyEdge defines model for TopologyEdge.

type TopologyEdgeState

type TopologyEdgeState string

TopologyEdgeState defines model for TopologyEdge.State.

const (
	Active TopologyEdgeState = "active"
	Recent TopologyEdgeState = "recent"
)

Defines values for TopologyEdgeState.

type TopologyNode

type TopologyNode struct {
	ClockSkewed    bool            `json:"clockSkewed"`
	DiscoKey       *string         `json:"discoKey,omitempty"`
	DnsName        *string         `json:"dnsName,omitempty"`
	Hostname       *string         `json:"hostname,omitempty"`
	Id             string          `json:"id"`
	IdentityStatus *IdentityStatus `json:"identityStatus,omitempty"`
	LastEvidenceAt time.Time       `json:"lastEvidenceAt"`
	NodeId         *string         `json:"nodeId,omitempty"`
	NodeKey        *string         `json:"nodeKey,omitempty"`
	Observable     bool            `json:"observable"`
	Online         bool            `json:"online"`

	// Os Reported operating system for display only; never identity evidence.
	Os           *string   `json:"os,omitempty"`
	StableNodeId *string   `json:"stableNodeId,omitempty"`
	TailscaleIps *[]string `json:"tailscaleIps,omitempty"`
}

TopologyNode defines model for TopologyNode.

type TrafficBucket

type TrafficBucket struct {
	AToBBytes   int64     `json:"aToBBytes"`
	BToABytes   int64     `json:"bToABytes"`
	BucketStart time.Time `json:"bucketStart"`
}

TrafficBucket defines model for TrafficBucket.

Jump to

Keyboard shortcuts

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