close the door = shut the door
shut your trap = close your mouth = stop speaking
the meaning is the same in every case, however, common usage often chooses one over the other in particular cases, eg
close a meeting (= finish)
when used in idioms, the meaning can be quite varied, eg
the final ball closed out the innings (= finished)
he shut her out of the conv