Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a rule to validate servers in the channel #2124

Closed
Tracked by #2100
magicmatatjahu opened this issue Apr 12, 2022 · 1 comment · Fixed by #2122
Closed
Tracked by #2100

Add a rule to validate servers in the channel #2124

magicmatatjahu opened this issue Apr 12, 2022 · 1 comment · Fixed by #2122
Labels
AsyncAPI Issues related to the AsyncAPI ruleset enhancement New feature or request released

Comments

@magicmatatjahu
Copy link
Contributor

User story.
As a user I want to know if the servers defined in the channels.*.servers array exist in the servers object.

Is your feature request related to a problem?
The following AsyncAPI document is invalid and Spectral should throw errors:

asyncapi: "2.0.0"
info:
  title: Awesome API
  description: A very well defined API
  version: "1.0"
servers:
  production:
    url: "stoplight.io"
    protocol: "https"
channels:
  hello:
    servers:
      - development

Additional context
Part of #2100

@stoplight-bot
Copy link
Collaborator

🎉 This issue has been resolved in version @stoplight/spectral-rulesets-v1.11.0 🎉

The release is available on npm package (@latest dist-tag)

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
AsyncAPI Issues related to the AsyncAPI ruleset enhancement New feature or request released
Projects
None yet
2 participants