To deserve something is to be worthy of something because you did, said or had something. It is an interesting word, because it can be positive:
"You deserve the world!"
or negative:
"You deserve a slap in the face!"
It also depends on how someone says it.
"You got what you deserved".
Can you say this sentence in a positive and negative way?