/* eslint-disable @typescript-eslint/no-unused-expressions,@typescript-eslint/require-await */
-import { AccountBlock, HttpStatusCode, ResultList, ServerBlock } from '@shared/models'
+import { AccountBlock, BlockStatus, HttpStatusCode, ResultList, ServerBlock } from '@shared/models'
import { AbstractCommand, OverrideCommandOptions } from '../shared'
type ListBlocklistOptions = OverrideCommandOptions & {
// ---------------------------------------------------------------------------
+ getStatus (options: OverrideCommandOptions & {
+ accounts?: string[]
+ hosts?: string[]
+ }) {
+ const { accounts, hosts } = options
+
+ const path = '/api/v1/blocklist/status'
+
+ return this.getRequestBody<BlockStatus>({
+ ...options,
+
+ path,
+ query: {
+ accounts,
+ hosts
+ },
+ implicitToken: false,
+ defaultExpectedStatus: HttpStatusCode.OK_200
+ })
+ }
+
+ // ---------------------------------------------------------------------------
+
addToMyBlocklist (options: OverrideCommandOptions & {
account?: string
server?: string