A funduq was a rest stop for merchants traveling along the Saharan trade routes. Most typically a funduq was a building with a square or rectangular walled exterior, with a single portal wide enough to permit large or heavily laden beasts such as camels to enter. The courtyard was almost always open to the sky, and the inside walls of the enclosure were outfitted with a number of identical animal stalls, bays, niches or chambers to accommodate merchants and their servants, animals, and merchandise. Funduqs provided water for human and animal consumption, washing and ritual purification – that is, washing before prayer or eating. Sometimes they had elaborate baths. They also kept fodder for animals and had shops for travelers where they could acquire new supplies. In addition, some shops bought goods from the travelling merchants.