Zaro Bates operates and lives on a 5,000-square-foot farm on Staten Island, which may make her the city’s only commercial farmer-in-residence. But instead of a shingled farmhouse surrounded by acres of fields, Ms. Bates lives in a second-floor studio in a midrise apartment complex built on the site of a former naval base overlooking New York Bay.

The farm itself sits in a courtyard between two buildings at Urby, a development with 571 rental apartments that opened in Stapleton last year. Ms. Bates draws a modest salary and gets free housing, which sounds like a good deal until you discover how much work she has to put in.

The 26-year-old oversees a weekly farmstand on the complex premises from May through November and donates to food banks. In her repertory? Some 50 types of produce — greens, summer vegetables, flowers, herbs and roots. She does this with help from her business partner and husband, Asher Landes, 29.

Let the doubters doubt.

“A lot of people instinctively call it a garden, but we really try to manage it for a commercial market,” Ms. Bates said. “It’s funny that people have different kinds of notions of what a farm is. Some people think it needs to have animals, that it needs to have acreage. We intensively crop this space so that we can produce for market, and that’s why we call it a farm.”