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

apns

package
v2.12.0 Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2026 License: BSD-3-Clause Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Device

type Device struct {
	ID             string          `json:"id"`
	Label          string          `json:"label"`
	Events         map[string]bool `json:"events"`
	EnvironmentIDs []string        `json:"environmentIds"`
	CreatedAt      time.Time       `json:"createdAt"`
	LastSeenAt     *time.Time      `json:"lastSeenAt,omitempty"`
}

type Envelope

type Envelope struct {
	Version         int       `json:"v"`
	EventID         string    `json:"eventId"`
	OccurredAt      time.Time `json:"occurredAt"`
	Type            string    `json:"type"`
	Severity        string    `json:"severity"`
	EnvironmentID   string    `json:"environmentId"`
	EnvironmentName string    `json:"environmentName"`
	Resource        *Resource `json:"resource,omitempty"`
	Title           string    `json:"title"`
	Body            string    `json:"body"`
	Route           Route     `json:"route"`
	ChannelID       string    `json:"channelId"`
	RecipientIDs    []string  `json:"recipientIds"`
}

type PairingToken

type PairingToken struct {
	Token     string    `json:"token"`
	ChannelID string    `json:"channelId"`
	ExpiresAt time.Time `json:"expiresAt"`
}

type RegisterDeviceRequest

type RegisterDeviceRequest struct {
	RecipientID    string          `json:"recipientId" minLength:"1" maxLength:"128"`
	Label          string          `json:"label" maxLength:"100" unorm:"nfc" trim:"true"`
	Events         map[string]bool `json:"events,omitzero"`
	EnvironmentIDs []string        `json:"environmentIds,omitzero"`
}

type Resource

type Resource struct {
	Kind string `json:"kind"`
	ID   string `json:"id"`
	Name string `json:"name,omitempty"`
}

type Route

type Route struct {
	Kind          string `json:"kind"`
	Tab           string `json:"tab,omitempty"`
	EnvironmentID string `json:"environmentId,omitempty"`
	ID            string `json:"id,omitempty"`
}

type Status

type Status struct {
	Enabled   bool     `json:"enabled"`
	ChannelID string   `json:"channelId,omitempty"`
	RelayURL  string   `json:"relayUrl"`
	Devices   []Device `json:"devices"`
}

type UpdateDeviceRequest

type UpdateDeviceRequest struct {
	Label          *string          `json:"label,omitzero" maxLength:"100" unorm:"nfc" trim:"true"`
	Events         *map[string]bool `json:"events,omitzero"`
	EnvironmentIDs *[]string        `json:"environmentIds,omitzero"`
}

Jump to

Keyboard shortcuts

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