Put the chicken thighs, onion, carrot, bay leaf and thyme in a large saucepan. Crumble in the stock cubes and pour over 1.5 litres of boiling water. Bring back to the boil, skim off any scum with a spoon, then reduce to a simmer.
Simmer for 30 minutes until the chicken is cooked through and the broth is golden.
Lift the chicken thighs onto a plate. Strip the meat off the bones and roughly chop it, then discard the skin and bones.
Add the leeks and pearl barley to the pan and simmer for 20 minutes until the barley is tender and the leeks are soft.
Return the chopped chicken to the pan along with the prunes, if using. Simmer for 2 minutes, then taste and season with salt and pepper.