FAQ

  • GitHub GitHub Repo stars
  • Discord Discord Server
  • Recommended

    info-description


    Formats: Severity:

    JSON Path: $.info

    The Info Object should always have a description defined.

    Think about the kind of questions that someone consuming the contract would want to know. A description should try to answer questions like:

    • What is this API contract about?
    • Why does it exist?
    • Why should I use it?
    • Who built it?
    • Where can I learn more?

    Why did this violation appear?

    There is no description defined in the info object. The info object may also be missing entirely.

    Bad example

    info:
      title: Chicken Nuggets Inc. Developer API
    

    Good example

    info:
      title: Chicken Nuggets Inc. Developer API
      description: |
        Do you love chicken nuggets? Need API driven chicken nugget delivery? We got you covered. Built by nugget fanatics with love.
        Check out https://chicken-nug-nugs.com/api for more information    
    

    How do I fix this violation?

    Ensure description has been defined with something meaningful, as a part of the Info Object

    Spectral Equivalent

    The rule is equivalent to info-description