summaryrefslogtreecommitdiff
path: root/internal/api/s2s/user/user.go
diff options
context:
space:
mode:
authorLibravatar tobi <31960611+tsmethurst@users.noreply.github.com>2021-10-24 11:57:39 +0200
committerLibravatar GitHub <noreply@github.com>2021-10-24 11:57:39 +0200
commit4b1d9d3780134098ff06877abc20c970c32d4aac (patch)
treea46deccd4cdf2ddf9d0ea92f32bd8669657a4687 /internal/api/s2s/user/user.go
parentpregenerate RSA keys for testrig accounts. If a user is added without a key,... (diff)
downloadgotosocial-4b1d9d3780134098ff06877abc20c970c32d4aac.tar.xz
Serve `outbox` for Actor (#289)
* add statusesvisible convenience function * add minID + onlyPublic to account statuses get * move swagger collection stuff to common * start working on Outbox GETting * move functions into federationProcessor * outboxToASCollection * add statusesvisible convenience function * add minID + onlyPublic to account statuses get * move swagger collection stuff to common * start working on Outbox GETting * move functions into federationProcessor * outboxToASCollection * bit more work on outbox paging * wrapNoteInCreate function * test + hook up the processor functions * don't do prev + next links on empty reply * test get outbox through api * don't fail on no status entries * add outbox implementation doc * typo
Diffstat (limited to 'internal/api/s2s/user/user.go')
-rw-r--r--internal/api/s2s/user/user.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/internal/api/s2s/user/user.go b/internal/api/s2s/user/user.go
index ef0057f98..56b940f1d 100644
--- a/internal/api/s2s/user/user.go
+++ b/internal/api/s2s/user/user.go
@@ -37,6 +37,8 @@ const (
OnlyOtherAccountsKey = "only_other_accounts"
// MinIDKey is for filtering status responses.
MinIDKey = "min_id"
+ // MaxIDKey is for filtering status responses.
+ MaxIDKey = "max_id"
// PageKey is for filtering status responses.
PageKey = "page"
@@ -50,6 +52,8 @@ const (
UsersPublicKeyPath = UsersBasePathWithUsername + "/" + util.PublicKeyPath
// UsersInboxPath is for serving POST requests to a user's inbox with the given username key.
UsersInboxPath = UsersBasePathWithUsername + "/" + util.InboxPath
+ // UsersOutboxPath is for serving GET requests to a user's outbox with the given username key.
+ UsersOutboxPath = UsersBasePathWithUsername + "/" + util.OutboxPath
// UsersFollowersPath is for serving GET request's to a user's followers list, with the given username key.
UsersFollowersPath = UsersBasePathWithUsername + "/" + util.FollowersPath
// UsersFollowingPath is for serving GET request's to a user's following list, with the given username key.
@@ -83,5 +87,6 @@ func (m *Module) Route(s router.Router) error {
s.AttachHandler(http.MethodGet, UsersStatusPath, m.StatusGETHandler)
s.AttachHandler(http.MethodGet, UsersPublicKeyPath, m.PublicKeyGETHandler)
s.AttachHandler(http.MethodGet, UsersStatusRepliesPath, m.StatusRepliesGETHandler)
+ s.AttachHandler(http.MethodGet, UsersOutboxPath, m.OutboxGETHandler)
return nil
}