How to validate a token on Next.js backend from a separate frontend

Yes I came across that too, but I didn’t understand how to use middleware in Next.js at first to build something similar without express.