Hi Sanjay,
In addition to @jayeff's excellent advice on trying different cables, chargers and hooking it up to a computer, you'll want to try cleaning the port out; compressed air, toothpicks, 90% isopropyl alcohol and some microfiber eyeglass cloths are all useful.
If you've tried everything else without success then the most likely repair is to replace the charging port. Unfortunately iFixit doesn't have a guide for replacing the charging port, but there's a Spanish site called Nadie Me Llama Gallina that has just what you need. Together with the Chrome browser's automatic translation, the site is very usable even if you don't speak Spanish.
[link|https://www.nadiemellamagallina.com/en/manuales/smartphones-1/samsung-4/samsung-galaxy-s7-edge-453/placa-auxiliar-con-conector-usb-y-botones-frontales-3119|Manuales / Samsung Galaxy S7 Edge / Auxiliary board with USB connector and front buttons|new_window=true]