What exactly did Private James W Brown do to earn this medal? He was among 300 soldiers of the 27th Maine Infantry Regiment who agreed to stay behind in Washington, DC in July 1863, while the Army of the Potomac marched to Gettysburg. He was not engaged in battle, nor proved himself by any act of heroism in the face of the enemy. He and his unit were all packed up and ready to head back to Maine, as they were just a nine-month regiment, when Secretary of War Edwin Stanton sent a messenger to their camp with his request for them to stay in DC just a bit longer. When Col. Wentworth and 1/3 of the others agreed to stay, Stanton said that they'd get medals for this. The only medals being issued at that time, though, were the medals of honor. So, that is what they got.
James Brown (blog post: the Browns of Locke's Cove, Kittery)