It could be solenoids firing on and off for some unknown reason. Loosen the Neg cable from the battery get the truck to start doing it then remove the Neg cable and if it quits then you know theres a short in the system. Do you have a check engine light on? And maybe not be a **** to those trying to help you.
"The truck starts right up, runs fine, but as soon as I turn it off and get out I can here the click. I'm not sure if it's doing it while I'm driving" is what you said! Maybe be more specific with what you say. Want me to word it for you?
After the truck sits overnight I turn the key to ON and then I hear some clicking noises from underneth. Does anyone know what this could be? BOOM Done!! You're welcome!!