Warning: Video contains images that some viewers may find disturbing

A horrifying video has captured the exact moment a sidewalk collapsed, swallowing two women in the city of Diyarbakir, Turkey.

The CCTV footage, which has gone viral, shows two women causally talking to each other before the pavement in front of building opened up right beneath them. 

Local media reports identified the women — one is a doctor and another, a nurse. 

The incident took place in front of a building at around 4pm on Wednesday in a district of Diyarbakir. The two were walking along the pavement before stopping to talk to each other. 

Within moments, the sidewalk collapsed, swallowing both of them.

Some media reports said it was a "sinkhole", but it was not immediately clear that it was the case. 

Passersby rushed to help them out of the rubble.

Miraculously, the two managed to escape with only some minor injuries.

The footage was released by Turkish security forces, and has since gone viral after being shared thousands of times.

Local media reported that the two women were taken to a hospital, and were later discharged after undergoing treated for some light injuries.

Police and fire department officers were sent to the scene to investigate.