How can I understand that I have had a lucid dream?
By definition, any dream where you understood that you were dreaming is considered to be a lucid dream.
As it was mentioned in the study of Stumbrys et al., 2012 "… it is important to acknowledge that dream lucidity is not an ‘all-or-nothing’ phenomenon, but rather a continuum with different degrees: some dreams can be more lucid than others." (Barrett, 1992; Moss, 1986)
Of course, there are different levels of lucidity and you have to learn how to develop and maintain the high level of lucidity to enjoy your lucid dream to the fullest extent.
Besides, if you don’t know how to enhance lucidity and exercise dream control you may not have exactly the experience you were thinking of.
Nevertheless, if you have understood at least for a second that you were dreaming, that means that you have had a lucid dream, even if the level of lucidity was quite low and everything was rather blurry. Even if you lost your lucidity almost immediately, it doesn’t matter.
It is great anyway, as it proves that you are capable of lucid dreaming and all you need to do now is to develop your natural ability.