Low Battery Indcator Flashes
You can check the status of your battery, including chargeble life remaining, in the Setup Menu. You need to have the CSM/Setup menu option to display Full menus, not Simple, in order to get battery status. So see if that battery status selection says you need to replace the battery.
Since you can shake the camera to get full battery, it's possible the battery contacts (on the battery or in the camera) are dirty, so check that.
If you do need a new battery, spend the few extra bucks to get a genuine Nikon EN-EL3e from a Nikon dealer. I have learned that many off-brand batteries do not properly implement a needed reserve, and "Genuine Nikon" batteries bought online from non-dealers are often counterfeit, just relabeled junk.