bluesky

package
v0.0.0-...-0a55d2d Latest Latest
Warning

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

Go to latest
Published: Nov 6, 2024 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Handle

func Handle(text string) ([]telego.InputMedia, []string)

Types

type AspectRatio

type AspectRatio struct {
	Height int `json:"height"`
	Width  int `json:"width"`
}

type Author

type Author struct {
	Handle      string `json:"handle"`
	DisplayName string `json:"displayName"`
}

type BlueskyData

type BlueskyData *struct {
	Thread Thread `json:"thread"`
}

type Embed

type Embed struct {
	Type        string      `json:"$type"`
	Media       Media       `json:"media"`
	Images      []Image     `json:"images"`
	Playlist    *string     `json:"playlist"`
	Thumbnail   *string     `json:"thumbnail"`
	AspectRatio AspectRatio `json:"aspectRatio"`
}

type Image

type Image struct {
	Thumb       string      `json:"thumb"`
	Fullsize    string      `json:"fullsize"`
	Alt         string      `json:"alt"`
	AspectRatio AspectRatio `json:"aspectRatio"`
}

type InputMedia

type InputMedia struct {
	File      *os.File
	Thumbnail *os.File
}

type Media

type Media struct {
	Type      string  `json:"$type"`
	Images    []Image `json:"images"`
	Playlist  string  `json:"playlist"`
	Thumbnail string  `json:"thumbnail"`
}

type Post

type Post struct {
	URI    string `json:"uri"`
	Cid    string `json:"cid"`
	Author Author `json:"author"`
	Record Record `json:"record"`
	Embed  Embed  `json:"embed"`
}

type Record

type Record struct {
	Text string `json:"text"`
}

type Thread

type Thread struct {
	Post Post `json:"post"`
}

Jump to

Keyboard shortcuts

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