export default defineCachedEventHandler(
  async () => {
    const data = await $fetch(`${POD_API_BASE}/category/tree/3`, {
      method: 'POST',
      headers: POD_HEADERS,
      body: {
        withActivityArea: true,
        withPrivate: true,
        onlyHaveProduct: true,
      },
    });
    return data;
  },
  {
    maxAge: 60 * 10,
    swr: true,
    name: 'pod-categories',
    getKey: () => 'tree',
  },
);
