Does the key turn and it not unlock or does the key not turn?
If the key does not turn you could replace the cylinder with a new one but it would not be keyed thy same as the other locks. These are not expensive to buy online. I replaced the one on the back hatch of my x. it was not hard and amazon had a low cost replacement. It came with 2 door cylinders so you could do both doors but you may not want to deal with 2 keys for your truck.
If the key turns but nothing happens then the linkage may have came off the cylinder.