summaryrefslogtreecommitdiff
path: root/internal/api/client.go
diff options
context:
space:
mode:
authorLibravatar nicole mikołajczyk <git@mkljczk.pl>2025-08-12 14:05:15 +0200
committerLibravatar kim <gruf@noreply.codeberg.org>2025-08-12 14:05:15 +0200
commit660cf2c94ce6a87ac33d704ab1f68b2d4a258d92 (patch)
tree03eeab55b2f3bc2f3fc7667d245ed3b561a4f1a4 /internal/api/client.go
parent[docs] Revamp trusted proxies warning a bit (#4365) (diff)
downloadgotosocial-660cf2c94ce6a87ac33d704ab1f68b2d4a258d92.tar.xz
[feature] scheduled statuses (#4274)
An implementation of [`scheduled_statuses`](https://docs.joinmastodon.org/methods/scheduled_statuses/). Will fix #1006. this is heavily WIP and I need to reorganize some of the code, working on this made me somehow familiar with the codebase and led to my other recent contributions i told some fops on fedi i'd work on this so i have no choice but to complete it 🤷‍♀️ btw iirc my avatar presents me working on this branch Signed-off-by: nicole mikołajczyk <git@mkljczk.pl> Reviewed-on: https://codeberg.org/superseriousbusiness/gotosocial/pulls/4274 Co-authored-by: nicole mikołajczyk <git@mkljczk.pl> Co-committed-by: nicole mikołajczyk <git@mkljczk.pl>
Diffstat (limited to 'internal/api/client.go')
-rw-r--r--internal/api/client.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/internal/api/client.go b/internal/api/client.go
index 0b977e59f..829c9326d 100644
--- a/internal/api/client.go
+++ b/internal/api/client.go
@@ -48,6 +48,7 @@ import (
"code.superseriousbusiness.org/gotosocial/internal/api/client/preferences"
"code.superseriousbusiness.org/gotosocial/internal/api/client/push"
"code.superseriousbusiness.org/gotosocial/internal/api/client/reports"
+ "code.superseriousbusiness.org/gotosocial/internal/api/client/scheduledstatuses"
"code.superseriousbusiness.org/gotosocial/internal/api/client/search"
"code.superseriousbusiness.org/gotosocial/internal/api/client/statuses"
"code.superseriousbusiness.org/gotosocial/internal/api/client/streaming"
@@ -95,6 +96,7 @@ type Client struct {
preferences *preferences.Module // api/v1/preferences
push *push.Module // api/v1/push
reports *reports.Module // api/v1/reports
+ scheduledStatuses *scheduledstatuses.Module // api/v1/scheduled_statuses
search *search.Module // api/v1/search, api/v2/search
statuses *statuses.Module // api/v1/statuses
streaming *streaming.Module // api/v1/streaming
@@ -149,6 +151,7 @@ func (c *Client) Route(r *router.Router, m ...gin.HandlerFunc) {
c.preferences.Route(h)
c.push.Route(h)
c.reports.Route(h)
+ c.scheduledStatuses.Route(h)
c.search.Route(h)
c.statuses.Route(h)
c.streaming.Route(h)
@@ -191,6 +194,7 @@ func NewClient(state *state.State, p *processing.Processor) *Client {
preferences: preferences.New(p),
push: push.New(p),
reports: reports.New(p),
+ scheduledStatuses: scheduledstatuses.New(p),
search: search.New(p),
statuses: statuses.New(p),
streaming: streaming.New(p, time.Second*30, 4096),