If it is a truck then dents from loading and hauling cargo are normal (though cargo should be tied down). Likewise scratched paint caused by off road driving are normal things for trucks with 4 wheel drive (buy a 2 wheel drive if you are only driving on road). If it is a truck you cannot consider cosmetic damage in the value, if it is road worthy then the value is about how many hours are on the engine and nothing else. (this just killed the used and trade in market for trucks so if you buy one you better keep it for 15000 engine hours)
I know everyone says that the EPA killed small trucks in 2008[1] but Toyota replaced the "Toyota Pickup" with the less-practical Tundra in '95, and embiggened it in 2004, so I'm not convinced that companies would make them even were they legal.
It boggles the mind that people drop absolutely inordinate amounts of money on the King Ranch Escalade doo-doo trucks that don't seem to do work any better than any truck I've owned, but cost an arm and a leg when something goes wrong. The Telsa truck looks like one of the worst offenders: it's rare to see a vehicle that is THAT stupidly designed inside and out.