activitypub

package
v1.1.3 Latest Latest
Warning

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

Go to latest
Published: Nov 6, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Attachment

type Attachment struct {
	Type      string `json:"type"`
	URL       string `json:"url"`
	MediaType string `json:"mediaType"`
}

Attachment represents an attachment to an ActivityPub object.

type Note

type Note struct {
	ID        string   `json:"id"`
	Type      string   `json:"type"`
	Content   string   `json:"content"`
	Published string   `json:"published,omitempty"`
	To        []string `json:"to,omitempty"`
	CC        []string `json:"cc,omitempty"`
	Tag       []Tag    `json:"tag,omitempty"`
}

Note represents a note object in ActivityPub.

type Object

type Object struct {
	Context    interface{}            `json:"@context,omitempty"`
	ID         string                 `json:"id"`
	Type       string                 `json:"type"`
	Actor      string                 `json:"actor,omitempty"`
	Object     interface{}            `json:"object,omitempty"`
	Target     interface{}            `json:"target,omitempty"`
	Result     interface{}            `json:"result,omitempty"`
	Origin     interface{}            `json:"origin,omitempty"`
	Instrument interface{}            `json:"instrument,omitempty"`
	Published  string                 `json:"published,omitempty"`
	To         []string               `json:"to,omitempty"`
	CC         []string               `json:"cc,omitempty"`
	Bto        []string               `json:"bto,omitempty"`
	Bcc        []string               `json:"bcc,omitempty"`
	Attachment interface{}            `json:"attachment,omitempty"`
	Tag        interface{}            `json:"tag,omitempty"`
	Attributes map[string]interface{} `json:"attributes,omitempty"`
}

Object represents a general ActivityPub object or activity.

type StatusResponse

type StatusResponse struct {
	Object struct {
		Published  time.Time    `json:"published"`
		Content    string       `json:"content"`
		Attachment []Attachment `json:"attachment"`
		Tag        []Tag        `json:"tag"`
	} `json:"object"`
}

StatusResponse represents a status response from an ActivityPub server.

type StatusResult

type StatusResult struct {
	Content     string
	Timestamp   string
	Attachments []Attachment
	Tags        []Tag
}

StatusResult represents the result of a status request.

type Tag

type Tag struct {
	Type string `json:"type"`
	Name string `json:"name"`
	Href string `json:"href"`
}

Tag represents a tag in an ActivityPub object.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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