diff --git a/packages/rulesets/src/asyncapi/functions/asyncApi2ChannelParameters.ts b/packages/rulesets/src/asyncapi/functions/asyncApi2ChannelParameters.ts index 24897fc64..4302b33a3 100644 --- a/packages/rulesets/src/asyncapi/functions/asyncApi2ChannelParameters.ts +++ b/packages/rulesets/src/asyncapi/functions/asyncApi2ChannelParameters.ts @@ -8,7 +8,15 @@ import type { IFunctionResult } from '@stoplight/spectral-core'; export default createRulesetFunction<{ parameters: Record }, null>( { - input: null, + input: { + type: 'object', + properties: { + parameters: { + type: 'object', + } + }, + required: ['parameters'], + }, options: null, }, function asyncApi2ChannelParameters(targetVal, _, ctx) { diff --git a/packages/rulesets/src/asyncapi/functions/asyncApi2ServerVariables.ts b/packages/rulesets/src/asyncapi/functions/asyncApi2ServerVariables.ts index 2d7023a9d..e876cced5 100644 --- a/packages/rulesets/src/asyncapi/functions/asyncApi2ServerVariables.ts +++ b/packages/rulesets/src/asyncapi/functions/asyncApi2ServerVariables.ts @@ -8,7 +8,18 @@ import type { IFunctionResult } from '@stoplight/spectral-core'; export default createRulesetFunction<{ url: string; variables: Record }, null>( { - input: null, + input: { + type: 'object', + properties: { + url: { + type: 'string', + }, + variables: { + type: 'object', + } + }, + required: ['url', 'variables'], + }, options: null, }, function asyncApi2ServerVariables(targetVal, _, ctx) {