It has a chance but it is difficult to say how much of a chance. You said it still shows green when you scratch the trunk and branches which is a good sign.
The key right now is changing the conditions to a more suitable one (partial shade), patience, monitoring and careful watering when it needs it. Since it has lost a lot of its leaves, it won't use as much water as when it was full of leaves.
One good way to monitor when it needs water is to stick a wooden chopstick or dowel into the soil and leave it in the soil. Every day, take the chopstick/ dowel out and see how wet it is. Water the tree when the stick is almost dry.