Skip to content

Commit

Permalink
test(schemas): update schemas
Browse files Browse the repository at this point in the history
  • Loading branch information
Kinplemelon authored and ysfscream committed Sep 24, 2024
1 parent b418189 commit def7816
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 1 deletion.
23 changes: 22 additions & 1 deletion src/types/schemas/banned.schemas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,18 @@ export type PostBanned200 = {
data?: EmqxMgmtApiBannedBan[]
}

export type GetBanned400Code = typeof GetBanned400Code[keyof typeof GetBanned400Code]

// eslint-disable-next-line @typescript-eslint/no-redeclare
export const GetBanned400Code = {
BAD_REQUEST: 'BAD_REQUEST',
} as const

export type GetBanned400 = {
code?: GetBanned400Code
message?: string
}

export type GetBanned200 = {
data?: EmqxMgmtApiBannedBan[]
meta?: PublicMeta
Expand All @@ -40,6 +52,13 @@ export type PublicLimitParameter = number
export type GetBannedParams = {
page?: PublicPageParameter
limit?: PublicLimitParameter
clientid?: string
username?: string
peerhost?: string
like_clientid?: string
like_username?: string
like_peerhost?: string
like_peerhost_net?: string
}

export interface PublicMeta {
Expand All @@ -49,7 +68,9 @@ export interface PublicMeta {
hasnext: boolean
}

export type EmqxMgmtApiBannedBanUntil = number | string
export type EmqxMgmtApiBannedBanUntilOneOf = number | string

export type EmqxMgmtApiBannedBanUntil = EmqxMgmtApiBannedBanUntilOneOf | 'infinity'

export type EmqxMgmtApiBannedBanAt = number | string

Expand Down
2 changes: 2 additions & 0 deletions src/types/schemas/rules.schemas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -334,6 +334,7 @@ export interface RuleEngineNodeMetrics {
'actions.failed'?: number
'actions.failed.out_of_service'?: number
'actions.failed.unknown'?: number
'actions.discarded'?: number
}

export interface RuleEngineMetrics {
Expand All @@ -350,6 +351,7 @@ export interface RuleEngineMetrics {
'actions.failed'?: number
'actions.failed.out_of_service'?: number
'actions.failed.unknown'?: number
'actions.discarded'?: number
}

export type RuleEngineCtxUnsubEventType =
Expand Down

0 comments on commit def7816

Please sign in to comment.