Place the lamb, onions, parsley, garlic, allspice, cinnamon, barberries, egg, 1 teaspoon salt, and ½ teaspoon black pepper in a large bowl. Mix with your hands, then roll into balls about the size of golf balls.
Heat one-third of the oil over medium heat in a large, heavy-bottomed pot for which you have a tight-fitting lid. Put in a few meatballs at a time and cook and turn them around for a few minutes until they color all over. Remove from the pot and set aside. Cook the remaining meatballs the same way.
Wipe the pot clean and add the remaining oil. Add the shallots and cook them over medium heat for 10 minutes, stirring frequently, until golden brown.
Add the wine, leave to bubble for a moment or two, then add the stock, bay leaves, thyme, sugar, and some salt and pepper.
Arrange the figs and meatballs among and on top of the shallots; the meatballs need to be almost covered in the liquid. Bring to a boil, cover with the lid, decrease the heat to very low, and leave to simmer for 30 minutes. Remove the lid and simmer for about another hour, until the sauce has reduced and intensified in flavor. Taste and add salt and pepper, if needed.
Transfer to a large, deep serving dish. Whisk the yogurt, pour on top, and scatter with herbs.