import { getServerSession } from 'next-auth';
import { getData } from '@/app/util/api';
import { authOptions } from '@/pages/api/auth/[...nextauth]';
const session = await getServerSession(authOptions);
let data = await getData(api/get-category-challenges/${session?.userDbId}/${params.id}?status=${params.status});
The error I'm getting is
Error: An error occurred in the Server Components render,
and also an internal server error 500