aboutsummaryrefslogtreecommitdiffstats
path: root/pydis_site/apps/api/viewsets
diff options
context:
space:
mode:
Diffstat (limited to 'pydis_site/apps/api/viewsets')
-rw-r--r--pydis_site/apps/api/viewsets/bot/reminder.py30
1 files changed, 28 insertions, 2 deletions
diff --git a/pydis_site/apps/api/viewsets/bot/reminder.py b/pydis_site/apps/api/viewsets/bot/reminder.py
index 147f6dbc..6f8a28f2 100644
--- a/pydis_site/apps/api/viewsets/bot/reminder.py
+++ b/pydis_site/apps/api/viewsets/bot/reminder.py
@@ -27,9 +27,16 @@ class ReminderViewSet(
... {
... 'active': True,
... 'author': 1020103901030,
+ ... 'mentions': [
+ ... 336843820513755157,
+ ... 165023948638126080,
+ ... 267628507062992896
+ ... ],
... 'content': "Make dinner",
... 'expiration': '5018-11-20T15:52:00Z',
- ... 'id': 11
+ ... 'id': 11,
+ ... 'channel_id': 634547009956872193,
+ ... 'jump_url': "https://discord.com/channels/<guild_id>/<channel_id>/<message_id>"
... },
... ...
... ]
@@ -43,8 +50,11 @@ class ReminderViewSet(
#### Request body
>>> {
... 'author': int,
+ ... 'mentions': List[int],
... 'content': str,
- ... 'expiration': str # ISO-formatted datetime
+ ... 'expiration': str, # ISO-formatted datetime
+ ... 'channel_id': int,
+ ... 'jump_url': str
... }
#### Status codes
@@ -52,6 +62,22 @@ class ReminderViewSet(
- 400: if the body format is invalid
- 404: if no user with the given ID could be found
+ ### PATCH /bot/reminders/<id:int>
+ Update the user with the given `id`.
+ All fields in the request body are optional.
+
+ #### Request body
+ >>> {
+ ... 'mentions': List[int],
+ ... 'content': str,
+ ... 'expiration': str # ISO-formatted datetime
+ ... }
+
+ #### Status codes
+ - 200: returned on success
+ - 400: if the body format is invalid
+ - 404: if no user with the given ID could be found
+
### DELETE /bot/reminders/<id:int>
Delete the reminder with the given `id`.