First question is where was he and who was watching him while you were gone? Was he playing too hard? Did they notice anything or hear him yelp? There could be a cut on the foot, something stuck between the pads or in the pad. Could be a fracture or may not even be the foot. Hard to check when they are hurting. If you have someipone to help you, make a muzzle, have someone hold him and check it. You can look up on the Internet how to muzzle a dog. You just might have to take him into the Vet to determine the exact cause. Until then, I would limit exercise to just potty breaks.
This is actually a forum for birds so I will have your question moved to the dog forum. There are some terrific people over there that can probably help you. My guess is that he may have an infected nail or toe or worst case, a small fracture in one of the digits. A trip to the vet is the best way to find out what's wrong. A foot that is so tender that your dog snaps at you when you touch it sounds a bit serious.