That sounds a like a movie.... I don’t watch movies. Thanks anyway!
It’s an old Disney movie, in it the Devil (played by Bill Cosby) tricks a man (played by Elliot Gould) into thinking it is his time to die and he will be damned based on past minor sins, but he offers him a deal that his life can be extended if he helps to entrap 2 teenagers and a small boy into signing their souls over to the devil, in order to accomplish this he is given a super power to make their dreams come true and grant them talent and success, after successfully tricking the targets into signing the contracts he sees their personalities change and doesn’t like the results or the fact that the devil lied to him and says they will be killed right away instead of being allowed to live out their lives so he burns the contracts to free them and finds out that he freed himself by doing so.
There is more if you watch it and it’s not a bad movie at all.