dto

package
v1.12.0 Latest Latest
Warning

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

Go to latest
Published: Mar 5, 2026 License: AGPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ArtworkEventItem

type ArtworkEventItem struct {
	// [TODO] other media types
	CreatedAt      time.Time          `json:"created_at"`
	UpdatedAt      time.Time          `json:"updated_at"`
	Title          string             `json:"title"`
	Description    string             `json:"description"`
	SourceType     shared.SourceType  `json:"source_type"`
	SourceURL      string             `json:"source_url"`
	ArtistName     string             `json:"artist_name"`
	ArtistUsername string             `json:"artist_username"`
	ArtistUID      string             `json:"artist_uid"`
	Tags           []string           `json:"tags"`
	Pictures       []PictureEventItem `json:"pictures"`
	ID             ouid.OUID          `json:"id"`
	ArtistID       ouid.OUID          `json:"artist_id"`
	R18            bool               `json:"r18"`
}

type ArtworkSearchDocument

type ArtworkSearchDocument struct {
	ID          string   `json:"id"`
	Title       string   `json:"title"`
	Artist      string   `json:"artist"`
	Description string   `json:"description"`
	Tags        []string `json:"tags"`
	R18         bool     `json:"r18"`
}

type ArtworkSearchResult

type ArtworkSearchResult struct {
	IDs []ouid.OUID `json:"ids"`
}

type FetchedArtist

type FetchedArtist struct {
	Name     string            `json:"name"`
	Type     shared.SourceType `json:"type"`
	UID      string            `json:"uid"`
	Username string            `json:"username"`
}

type FetchedArtwork

type FetchedArtwork struct {
	Artist      *FetchedArtist       `json:"artist"`
	Title       string               `json:"title"`
	Description string               `json:"description"`
	SourceType  shared.SourceType    `json:"source_type"`
	SourceURL   string               `json:"source_url"`
	Tags        []string             `json:"tags"`
	Pictures    []*FetchedPicture    `json:"pictures"`
	UgoiraMetas []*FetchedUgoiraMeta `json:"ugoira_metas,omitempty"`
	Videos      []*FetchedVideo      `json:"videos,omitempty"`
	R18         bool                 `json:"r18"`
}

type FetchedPicture

type FetchedPicture struct {
	Thumbnail string `json:"thumbnail"`
	Original  string `json:"original"`

	Index uint `json:"index"`

	Width  uint `json:"width"`
	Height uint `json:"height"`
}

type FetchedUgoiraMeta

type FetchedUgoiraMeta struct {
	Data  shared.UgoiraMetaData `json:"data"`
	Index uint                  `json:"index"`
}

type FetchedVideo added in v1.5.0

type FetchedVideo struct {
	URL      string `json:"url"`
	Poster   string `json:"poster"`
	MimeType string `json:"mime_type"`
	Index    uint   `json:"index"`
	Width    uint   `json:"width"`
	Height   uint   `json:"height"`
	Duration uint   `json:"duration"` // in milliseconds
}

type PictureEventItem

type PictureEventItem struct {
	CreatedAt  time.Time `json:"created_at"`
	UpdatedAt  time.Time `json:"updated_at"`
	Thumbnail  string    `json:"thumbnail"`
	Original   string    `json:"original"`
	Phash      string    `json:"phash"`      // phash
	ThumbHash  string    `json:"thumb_hash"` // thumbhash
	OrderIndex uint      `json:"index"`
	Width      uint      `json:"width"`
	Height     uint      `json:"height"`
	ID         ouid.OUID `json:"id"`
	ArtworkID  ouid.OUID `json:"artwork_id"`
}

Jump to

Keyboard shortcuts

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