How do you get the shotgun in Tomb Raider (2013)?

Quick answer: In the Chasm Monastery, right after you escape the Oni lair, climb the stone steps in the sandy corridor and take the Trench Shotgun from a dead body.
Show walkthrough
Escape the lair first
Chasm Monastery starts with Lara hanging upside down in an Oni lair. Break free, avoid the Oni and go through the tunnel of corpses.
Find the body
In the sandy corridor beyond, pick up the shotgun shells and climb the stone steps. A dried-out body there holds the Trench Shotgun. Take it to add it to your weapons.
Break barriers
The shotgun blasts open plank-and-barbed-wire barriers, and the first one is right in front of you. From now on, any barrier like this can be cleared with it, including the ones in Shantytown.
Upgrades
Shotgun Parts found in salvage crates later upgrade the weapon. Continue with the Chasm Monastery walkthrough.
