Madrasah of Nadir Diva-Beghi was constructed in 1622 by the vizier of Nadir Divan-begi. He served at court of Imam Kuli-khan. Initially it was intended as a caravanserai, but on the grand opening ceremony Imam Kuli-khan personally proclaimed this building as a madrasah. After that the vizier had to modify the architecture. Loggia, high portals, a number of towers and a khudjr – accommodation rooms for students had to be built later. However, it is interesting that the classrooms for students were never built.