import { isDereferenced as u } from "@scalar/openapi-types/helpers";
import { computed as n } from "vue";
function l(s) {
  return {
    parameterMap: n(() => {
      var h;
      const o = {
        path: [],
        query: [],
        header: [],
        cookie: [],
        body: [],
        formData: []
      };
      s.pathParameters && s.pathParameters.forEach((i) => {
        i.in === "path" ? o.path.push(i) : i.in === "query" ? o.query.push(i) : i.in === "header" ? o.header.push(i) : i.in === "cookie" ? o.cookie.push(i) : i.in === "body" ? o.body.push(i) : i.in === "formData" && o.formData.push(i);
      });
      const f = ((h = s.information) == null ? void 0 : h.parameters) ?? [];
      return f && f.forEach((i) => {
        u(i) && (i.in === "path" ? o.path.push(i) : i.in === "query" ? o.query.push(i) : i.in === "header" ? o.header.push(i) : i.in === "cookie" ? o.cookie.push(i) : i.in === "body" ? o.body.push(i) : i.in === "formData" && o.formData.push(i));
      }), o;
    })
  };
}
export {
  l as useOperation
};
