aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/models/activitypub
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2022-03-23 16:14:33 +0100
committerChocobozzz <me@florianbigard.com>2022-03-24 09:40:46 +0100
commita219c9100b3ce8774d454497d46be87465bf664e (patch)
treecaa869e47919a9e23cc86dcece1100e239683b8c /shared/models/activitypub
parent7e98a7df7d04e19ba67163a86c7b876d78d76839 (diff)
downloadPeerTube-a219c9100b3ce8774d454497d46be87465bf664e.tar.gz
PeerTube-a219c9100b3ce8774d454497d46be87465bf664e.tar.zst
PeerTube-a219c9100b3ce8774d454497d46be87465bf664e.zip
Refactor AP context builder
Diffstat (limited to 'shared/models/activitypub')
-rw-r--r--shared/models/activitypub/context.ts16
-rw-r--r--shared/models/activitypub/objects/common-objects.ts4
2 files changed, 17 insertions, 3 deletions
diff --git a/shared/models/activitypub/context.ts b/shared/models/activitypub/context.ts
index bd795a2fd..4ada3b083 100644
--- a/shared/models/activitypub/context.ts
+++ b/shared/models/activitypub/context.ts
@@ -1 +1,15 @@
1export type ContextType = 'All' | 'View' | 'Announce' | 'CacheFile' 1export type ContextType =
2 'Video' |
3 'Comment' |
4 'Playlist' |
5 'Follow' |
6 'Reject' |
7 'Accept' |
8 'View' |
9 'Announce' |
10 'CacheFile' |
11 'Delete' |
12 'Rate' |
13 'Flag' |
14 'Actor' |
15 'Collection'
diff --git a/shared/models/activitypub/objects/common-objects.ts b/shared/models/activitypub/objects/common-objects.ts
index 43d7f7f74..9bf994379 100644
--- a/shared/models/activitypub/objects/common-objects.ts
+++ b/shared/models/activitypub/objects/common-objects.ts
@@ -46,7 +46,7 @@ export type ActivityTrackerUrlObject = {
46 href: string 46 href: string
47} 47}
48 48
49export type ActivityPlaylistInfohashesObject = { 49export type ActivityStreamingPlaylistInfohashesObject = {
50 type: 'Infohash' 50 type: 'Infohash'
51 name: string 51 name: string
52} 52}
@@ -97,7 +97,7 @@ export interface ActivityFlagReasonObject {
97 97
98export type ActivityTagObject = 98export type ActivityTagObject =
99 ActivityPlaylistSegmentHashesObject 99 ActivityPlaylistSegmentHashesObject
100 | ActivityPlaylistInfohashesObject 100 | ActivityStreamingPlaylistInfohashesObject
101 | ActivityVideoUrlObject 101 | ActivityVideoUrlObject
102 | ActivityHashTagObject 102 | ActivityHashTagObject
103 | ActivityMentionObject 103 | ActivityMentionObject