FAQ

  • GitHub GitHub Repo stars
  • Discord Discord Server
  • ✨ New! Try the OpenAPI Doctor ✨ The OpenAPI Doctor
    Recommended

    paths-kebab-case


    Formats: Severity:

    Paths should not use underscores or uppercase letters. Neither should they be empty.

    Servers may or may not be case-sensitive, so everything should be lowercase, there is no good reason for uppercase path segments.

    Why did this violation appear?

    A segment in one of the paths defined in the specification, is not kebab-case

    What is this rule checking for?

    Every path segment isn’t empty, and if not a variable - checks the value is kebab-case.

    Bad example

    paths: 
      '/iAm/not_a/valid/PATH':
        get:
          description: This is no good.
      '/hey~there/How/are//you':
        post:
          description: This is also no good.
    

    Good Example

    paths: 
      '/always/kebab-case/never-anything-else':
        get:
          description: A certain pass.
      '/this-is/a-good/example-of/kebab-case':
        post:
          description: Will always pass.
    

    How do I fix this violation?

    Ensure that no path segment uses any other case, other than kebab-case