Most likely you are having 'trigger finger'.
Trigger finger occurs if there is a problem with the tendon or sheath, such as swelling, which means the tendon can no longer slide easily through the sheath. This makes it harder to bend the affected finger or thumb. If the tendon gets caught in the opening of the sheath, the finger can give a painful click, like a trigger being released, as it is straightened.
Exact cause is unknown.
If you see this video it will help you in understanding it .
Treatment is taking NSAIDS like ibuprofen etc.
Give rest to this hand .
In extreme cases we have to give steroid injection in joint.#
Some time ,it has to be surgically treated at last.
However,80 percent of cases are treated by NSAIDS.
They are fine afterwards.
Hope it helped.
Okay, thank you. I was thinking along the lines of trigger finger but the pain is not when I bend the finger, but rather when I use it to type (like now) or when I try to straighten it fully. I am noticing that the pain is now more above the knuckle.
Yes,still it is under diagnosis of 'trigger finer'.Main feature of trigger finger is 'pain when we try to straighten it'.Because in this movement the tendon get rubbed under ligament sheath this causes pain (because sheath is swollen).I forgot to tell you that it is mostly seen in people who are typist as they do repetitive movement like typing.
If you have questions you can still ask.