getServerSession it work in client side, but in API route is null

I already try to call getServerSession in client side it works:

enter image description here

This is my auth code:

enter image description here

This is API route that call getServerSession how to make in this API can get session.user.email?

I want to make API can get session.user.email for post data every day by use crons on vercel.