I'm doing that exactly - were in an urban part of Boston and have a 2nd story apartment. It is currently running the level 1 charger out our second story window. I purchased a 25' 10 Gauge Black Heavy Duty Extension Cord (Ebay $30) and ran that out of my kitchen window. It goes to a Waterproof IP65 Enclosure ABS Control Electronic Junction Box that I mounted on the outside of our downstairs neighbor's wall. In the box, it connects to the Level 1 charger that came with the car. I could lock the box, but the box has a special key anyway to open.
I've considered upgrading to a level 2 charger, but the level 1 is sufficient for most days. It does provide a trip hazard, but the only ones in our back parking lot are us and our neighbors. If you live in a fancy place with an overreaching HOA they might not like it, but our landlord is just happy to collect his rent. It is a pain if I want to unplug the charger to take it with me, but rarely do I need to do that.
Figure out how long an extension cord you need, and what gauge you need. I first tested it with a regular 100' ft outdoor cord. The car charged, but the charger was smart enough to only pull so much power so it took 2-3x as long to charge.