New York taxes the military pay of resident service members, with two exceptions. If you were stationed and living outside New York, kept no permanent home in New York during the tax year, kept a permanent home outside New York for the whole year and spent 30 days or less in New York, your military pay is not taxed. If you served overseas for at least 450 days in any 548 consecutive days and spent 90 days or less in New York during that 548-day period, it is also not taxed.
There is nothing to apply for. Claim nonresident or nonresident-equivalent treatment when you file your New York State return, and keep your orders and travel records in case the state asks.
Your orders showing where you were stationed, your Leave and Earnings Statements, and records of the days you spent in New York.