diff options
author | 2025-02-04 16:52:42 +0100 | |
---|---|---|
committer | 2025-02-04 16:52:42 +0100 | |
commit | 07d27709957248008c61d6b8d553e3d2eb14d154 (patch) | |
tree | d054e92729708e275886100492a458d633fbaa59 /internal/api/model | |
parent | adds support for build specifically without wasm ffmpeg (#3732) (diff) | |
download | gotosocial-07d27709957248008c61d6b8d553e3d2eb14d154.tar.xz |
[feature] Change `instance-stats-randomize` to `instance-stats-mode` with multiple options; implement nodeinfo 2.1 (#3734)
* [feature] Change `instance-stats-randomize` to `instance-stats-mode` with multiple options; implement nodeinfo 2.1
* swaggalaggadingdong
Diffstat (limited to 'internal/api/model')
-rw-r--r-- | internal/api/model/well-known.go | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/internal/api/model/well-known.go b/internal/api/model/well-known.go index 54d9912c8..d9948f951 100644 --- a/internal/api/model/well-known.go +++ b/internal/api/model/well-known.go @@ -70,6 +70,12 @@ type NodeInfoSoftware struct { Name string `json:"name"` // example: 0.1.2 1234567 Version string `json:"version"` + // Repository for the software. Omitted in version 2.0. + // example: https://codeberg.org/superseriousbusiness/gotosocial + Repository string `json:"repository,omitempty"` + // Homepage for the software. Omitted in version 2.0. + // example: https://docs.gotosocial.org + Homepage string `json:"homepage,omitempty"` } // NodeInfoServices represents inbound and outbound services that this node offers connections to. @@ -80,13 +86,16 @@ type NodeInfoServices struct { // NodeInfoUsage represents usage information about this server, such as number of users. type NodeInfoUsage struct { - Users NodeInfoUsers `json:"users"` - LocalPosts int `json:"localPosts"` + Users NodeInfoUsers `json:"users"` + LocalPosts int `json:"localPosts,omitempty"` + LocalComments int `json:"localComments,omitempty"` } // NodeInfoUsers represents aggregate information about the users on the server. type NodeInfoUsers struct { - Total int `json:"total"` + Total int `json:"total"` + ActiveHalfYear int `json:"activeHalfYear,omitempty"` + ActiveMonth int `json:"activeMonth,omitempty"` } // HostMeta represents a hostmeta document. |