Completely depends on the snake and its temperament.
Some handle "handling" better then others.
My adults are completely "chill". They know nothing bad happens with handling, so they are ok with longer sessions. That said, its usually 20 minutes or so. The one that likes to explore on my desk behind my monitor gets longer. He comes to the front of the desk when he is done exploring and slithers onto my hands while I type. That is when I will return him to his cage. That can be anywhere from 15 minutes to 45 minutes or so.
When they are young and shy, you want to do shorter sessions, and more often. (daily, apart from after feeding and during shed)
When I have one that is overly shy or defensive, I make SURE I handle often, but I keep it short enough so I always return them to their tub BEFORE they start stressing. Stressing can be trying to get away and getting frantic about it, or completely balling up, playing "dead". You always want to end on a good note. When you return them to their enclosure, let them slither off and keep your hands still. In the beginning they are in a huge rush, eventually, they calmly return to the enclosure. With those I try to keep the handling to about 5 minutes or so.