Private First Class Hansen Kirkpatrick, 19, of Wasilla, Alaska died Monday following the "indirect fire" assault, which means he was hit by a mortar or some other incoming round.
The wounds sustained by the two soldiers were not considered life threatening, and they were being treated at a coalition medical facility, US Forces-Afghanistan said in a statement.
"At a time when we remember the patriots who founded our nation in freedom, we are saddened by the loss of one of our comrades who was here protecting our freedom at home," said General John Nicholson, who commands US Forces-Afghanistan, referring to America's July 4 Independence Day commemorations.
Pentagon chief Jim Mattis is expected to present President Donald Trump this month with a revamped Afghanistan strategy aimed at breaking a stalemate with the Taliban.