Add account block status in openapi
This commit is contained in:
parent
d9f9804d86
commit
bdf70330e4
|
@ -3792,6 +3792,39 @@ paths:
|
||||||
'500':
|
'500':
|
||||||
description: search index unavailable
|
description: search index unavailable
|
||||||
|
|
||||||
|
/blocklist/status:
|
||||||
|
get:
|
||||||
|
tags:
|
||||||
|
- Account Blocks
|
||||||
|
- Server Blocks
|
||||||
|
summary: Get block status of accounts/hosts
|
||||||
|
parameters:
|
||||||
|
-
|
||||||
|
name: 'accounts'
|
||||||
|
in: query
|
||||||
|
description: 'Check if these accounts are blocked'
|
||||||
|
example: [ 'goofy@example.com', 'donald@example.com' ]
|
||||||
|
schema:
|
||||||
|
type: array
|
||||||
|
items:
|
||||||
|
type: string
|
||||||
|
-
|
||||||
|
name: 'hosts'
|
||||||
|
in: query
|
||||||
|
description: 'Check if these hosts are blocked'
|
||||||
|
example: [ 'example.com' ]
|
||||||
|
schema:
|
||||||
|
type: array
|
||||||
|
items:
|
||||||
|
type: string
|
||||||
|
responses:
|
||||||
|
'200':
|
||||||
|
description: successful operation
|
||||||
|
content:
|
||||||
|
'application/json':
|
||||||
|
schema:
|
||||||
|
$ref: '#/components/schemas/BlockStatus'
|
||||||
|
|
||||||
/server/blocklist/accounts:
|
/server/blocklist/accounts:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
|
@ -5134,6 +5167,29 @@ components:
|
||||||
label:
|
label:
|
||||||
type: string
|
type: string
|
||||||
|
|
||||||
|
BlockStatus:
|
||||||
|
properties:
|
||||||
|
accounts:
|
||||||
|
type: object
|
||||||
|
additionalProperties:
|
||||||
|
x-additionalPropertiesName: account
|
||||||
|
type: object
|
||||||
|
properties:
|
||||||
|
blockedByServer:
|
||||||
|
type: boolean
|
||||||
|
blockedByUser:
|
||||||
|
type: boolean
|
||||||
|
hosts:
|
||||||
|
type: object
|
||||||
|
additionalProperties:
|
||||||
|
x-additionalPropertiesName: host
|
||||||
|
type: object
|
||||||
|
properties:
|
||||||
|
blockedByServer:
|
||||||
|
type: boolean
|
||||||
|
blockedByUser:
|
||||||
|
type: boolean
|
||||||
|
|
||||||
NSFWPolicy:
|
NSFWPolicy:
|
||||||
type: string
|
type: string
|
||||||
enum:
|
enum:
|
||||||
|
|
Loading…
Reference in New Issue