Take off your t-shirt and go out into the hall naked. Then, lock the door behind you and slip your key back under the door or through the mail slot so that you can’t get it.
Your task now is simple: go get your spare keys and let yourself back into your apartment.
And it doesn’t look like you have much of a choice now, does it?