    (s/optional-key "externalDocs")      external-documentation-object
    (s/optional-key "consumes")          [s-string]
    (s/optional-key "produces")          [s-string]
-   (s/optional-key "parameters")        [(s/either parameter-object reference-object)]
+   (s/optional-key "parameters")        [(s/if ref? reference-object parameter-object)]
    (s/optional-key "schemes")           [s-string]
    (s/optional-key "deprecated")        s-boolean
    (s/optional-key "security")          [security-requirement-object]

   (s/optional-key "options")           operation-object
   (s/optional-key "head")              operation-object
   (s/optional-key "patch")             operation-object
   (s/optional-key "parameters")        [(s/either parameter-object reference-object)]
   (s/optional-key (s/pred extension?)) s/Any})

(def paths-object

  {s-string [s-string]})

(def responses-object
  {(s/optional-key "default")           (s/if ref? reference-object response-object)
   (s/cond-pre s-long s-string)         (s/if ref? reference-object response-object)
   (s/optional-key (s/pred extension?)) s/Any})

(def operation-object
