event

package
v0.1.25 Latest Latest
Warning

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

Go to latest
Published: Mar 17, 2022 License: AGPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Envelope added in v0.1.24

type Envelope struct {
	EventProtocol   string           `json:"eventProtocol"`
	EventSchema     *string          `json:"eventSchema"`
	Source          string           `json:"source"`
	Tstamp          time.Time        `json:"tstamp"`
	Ip              string           `json:"ip"`
	IsValid         *bool            `json:"isValid"`
	IsRelayed       *bool            `json:"isRelayed"`
	ValidationError *ValidationError `json:"validationErrors"`
	Payload         Event            `json:"payload"`
}

type Event added in v0.1.24

type Event interface {
	Schema() *string
	Protocol() string
	PayloadAsByte() ([]byte, error)
	AsByte() ([]byte, error)
	AsMap() (map[string]interface{}, error)
}

type PayloadValidationError added in v0.1.24

type PayloadValidationError struct {
	Field       string `json:"field"`
	Description string `json:"description"`
	ErrorType   string `json:"errorType"`
}

type SelfDescribingContext

type SelfDescribingContext SelfDescribingPayload

type SelfDescribingEvent added in v0.1.24

type SelfDescribingEvent struct {
	Contexts []SelfDescribingContext `json:"contexts"`
	Payload  SelfDescribingPayload   `json:"payload"`
}

type SelfDescribingPayload

type SelfDescribingPayload struct {
	Schema string                 `json:"schema"`
	Data   map[string]interface{} `json:"data"`
}

type ValidationError added in v0.1.24

type ValidationError struct {
	ErrorType       *string                  `json:"errorType"`
	ErrorResolution *string                  `json:"errorResolution"`
	Errors          []PayloadValidationError `json:"payloadValidationErrors"`
}

Jump to

Keyboard shortcuts

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