Bats entering human dwellings are not that uncommon.
They are usually not dangerous and do not show aggression, but they can accidentally scratch the owners of the apartment if they feel afraid and start rushing around the rooms.
Scratches left by these animals are dangerous because they can introduce infection.
This is the main reason why you should exercise maximum caution and try to get rid of uninvited guests as quickly as possible.
To begin, isolate pets, if you have any, in another room.
After this, wait until the bat stops scurrying and lands on any surface.
Put on thick gloves and a long-sleeved sweater. You will also need any container that will fit the animal - this can be a bowl, a pan, a box, etc.
Press it against the wall so that the mouse is inside, and then carefully slide the cardboard between the wall and the container.
All that remains is to take the bat outside and leave it in a safe place. Do not throw the animal out of the window - because it is disoriented, there is a risk of falling and dying.
For reference
Bats is a general name for representatives of the order Chiroptera, excluding fruit bats.