aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/models/plugins
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2019-12-06 15:59:12 +0100
committerChocobozzz <me@florianbigard.com>2019-12-06 15:59:12 +0100
commit6f3fe96f4003fd9ad198cdf0ee5a47b32e9e6568 (patch)
treea3f1f541abec41abee96df9960cbe2b2a6c3ba86 /shared/models/plugins
parent349be1eaa9a61b2e2acaa24db58acb95774c0d20 (diff)
downloadPeerTube-6f3fe96f4003fd9ad198cdf0ee5a47b32e9e6568.tar.gz
PeerTube-6f3fe96f4003fd9ad198cdf0ee5a47b32e9e6568.tar.zst
PeerTube-6f3fe96f4003fd9ad198cdf0ee5a47b32e9e6568.zip
Add action hooks to user routes
Diffstat (limited to 'shared/models/plugins')
-rw-r--r--shared/models/plugins/server-hook.model.ts18
1 files changed, 17 insertions, 1 deletions
diff --git a/shared/models/plugins/server-hook.model.ts b/shared/models/plugins/server-hook.model.ts
index 41ee28097..80ecd9e24 100644
--- a/shared/models/plugins/server-hook.model.ts
+++ b/shared/models/plugins/server-hook.model.ts
@@ -55,7 +55,23 @@ export const serverActionHookObject = {
55 // Fired when a reply to a thread is created 55 // Fired when a reply to a thread is created
56 'action:api.video-comment-reply.created': true, 56 'action:api.video-comment-reply.created': true,
57 // Fired when a comment (thread or reply) is deleted 57 // Fired when a comment (thread or reply) is deleted
58 'action:api.video-comment.deleted': true 58 'action:api.video-comment.deleted': true,
59
60 // Fired when a user is blocked (banned)
61 'action:api.user.blocked': true,
62 // Fired when a user is unblocked (unbanned)
63 'action:api.user.unblocked': true,
64 // Fired when a user registered on the instance
65 'action:api.user.registered': true,
66 // Fired when an admin/moderator created a user
67 'action:api.user.created': true,
68 // Fired when a user is removed by an admin/moderator
69 'action:api.user.deleted': true,
70 // Fired when a user is updated by an admin/moderator
71 'action:api.user.updated': true,
72
73 // Fired when a user got a new oauth2 token
74 'action:api.user.oauth2-got-token': true
59} 75}
60 76
61export type ServerActionHookName = keyof typeof serverActionHookObject 77export type ServerActionHookName = keyof typeof serverActionHookObject