how to use getServerSession inside onclick server action

I am trying to call getServerSession inside onClick and it's not working can anyone have answer to this how can we call getServerSession inside server action which is used inside onClick
export async function Example() {
  const session = await getServerSession(authOption);
  console.log(session);
}

export default function Page() {
  return <div onClick={() => Example()}>hello</div>;
}
Was this page helpful?