summaryrefslogtreecommitdiff
path: root/src/server/api/endpoints/blocking
diff options
context:
space:
mode:
Diffstat (limited to 'src/server/api/endpoints/blocking')
-rw-r--r--src/server/api/endpoints/blocking/create.ts6
-rw-r--r--src/server/api/endpoints/blocking/delete.ts70
2 files changed, 76 insertions, 0 deletions
diff --git a/src/server/api/endpoints/blocking/create.ts b/src/server/api/endpoints/blocking/create.ts
index bdaccc79ed..dfab338a8b 100644
--- a/src/server/api/endpoints/blocking/create.ts
+++ b/src/server/api/endpoints/blocking/create.ts
@@ -52,6 +52,12 @@ export const meta = {
code: 'ALREADY_BLOCKING',
id: '787fed64-acb9-464a-82eb-afbd745b9614'
},
+ },
+
+ res: {
+ type: 'object' as const,
+ optional: false as const, nullable: false as const,
+ ref: 'User'
}
};
diff --git a/src/server/api/endpoints/blocking/delete.ts b/src/server/api/endpoints/blocking/delete.ts
index 451da1c915..22d2df5970 100644
--- a/src/server/api/endpoints/blocking/delete.ts
+++ b/src/server/api/endpoints/blocking/delete.ts
@@ -52,6 +52,76 @@ export const meta = {
code: 'NOT_BLOCKING',
id: '291b2efa-60c6-45c0-9f6a-045c8f9b02cd'
},
+ },
+
+ res: {
+ type: 'object' as const,
+ optional: false as const, nullable: false as const,
+ properties: {
+ id: {
+ type: 'string' as const,
+ optional: false as const, nullable: false as const,
+ format: 'id',
+ description: 'The unique identifier for this blocking.',
+ example: 'xxxxxxxxxx',
+ },
+ name: {
+ type: 'string' as const,
+ optional: false as const, nullable: true as const
+ },
+ username: {
+ type: 'string' as const,
+ optional: false as const, nullable: false as const
+ },
+ host: {
+ type: 'string' as const,
+ optional: false as const, nullable: true as const
+ },
+ avatarUrl: {
+ type: 'string' as const,
+ optional: false as const, nullable: false as const,
+ format: 'url'
+ },
+ avatarBlurhash: {
+ type: 'string' as const,
+ optional: false as const, nullable: true as const
+ },
+ avatarColor: {
+ type: 'any' as const,
+ optional: false as const, nullable: true as const
+ },
+ emojis: {
+ type: 'array' as const,
+ optional: false as const, nullable: false as const,
+ items: {
+ type: 'object' as const,
+ nullable: false as const, optional: false as const,
+ properties: {
+ name: {
+ type: 'string' as const,
+ nullable: false as const, optional: false as const
+ },
+ host: {
+ type: 'string' as const,
+ nullable: true as const, optional: false as const
+ },
+ url: {
+ type: 'string' as const,
+ nullable: false as const, optional: false as const,
+ format: 'url'
+ },
+ aliases: {
+ type: 'array' as const,
+ nullable: false as const, optional: false as const,
+ items: {
+ type: 'string' as const,
+ nullable: false as const, optional: false as const
+ }
+ }
+ }
+ }
+ }
+ }
}
};