import { c as defineEventHandler, g as getQuery } from '../../../_/nitro.mjs';
import { parseArticle } from './_shared.mjs';
import 'node:http';
import 'node:https';
import 'node:events';
import 'node:buffer';
import 'node:fs';
import 'node:path';
import 'node:crypto';
import 'node:url';
import 'fs';
import 'path';

const retrieve_get = defineEventHandler(async (event) => {
  const fileName = getQuery(event).fileName;
  const parsedArticle = parseArticle(fileName);
  return parsedArticle;
});

export { retrieve_get as default };
