Can i use my lenovo all in one as a stand alone?

I will be working from home in the next month or so. I have a Lenovo all in one but the job requires a stand alone monitor because they will be supplying the computer. I don't want to buy a new 22 inch stand alone monitor if I don't have to. Is there a way to connect an external pc to my all in one?

No… You have to use a monitorl.

Yes. Some Lenovo models have HDMI IN port. You could use that.
If none there, you can use an ethernet connection between that Lenovo and the other computer. But you must have a monitor (or a TV) hooked to the computer at least for setup of software like MaxiVistA or ZoneScreen or AirDisplay or TeamViewer or Remote Access or VNC or several others.