I'm sorry to hear that you hurt your hand so badly! There are a couple of different possible outcomes of slamming your hand hard into the door like you did. The first, and most likely, is that you could just develop some local pain, bruising, and swelling, as well as stiffness, over the area of injury
. This contusion
tends to get better over a few days, with the swelling going down and the mobility improving. The second possibility, which is more serious, is that you can break one of the bones in your hand. This typically produces quite a bit more pain and limitation in mobility than just a minor contusion, and there may also be deformity of the hand, with for example one or more of the knuckles looking "funny."
What I would suggest is that you go see your primary care doctor
about this issue, especially if there is any concern that you may have broken something. They can examine your hand and figure out whether or not you need x-rays to rule out a fracture. They can also prescribe you some medications to help reduce the pain and the inflammation as quickly as possible.