enabled should be a boolean
more robust deserialisation