“So the tree house started to spin,” a voice said, and on the stage of the Newmark Theatre in downtown Portland, it spun round and round, a glittery little spectacle of stage magic that had the midmorning crowd of early grade-school kids and their appointed adult herders oohing and ahhing at the wonder of it all.

The spinning tree house, after all, is a Magic Tree House, a time-traveling portal for a series of insanely popular kids’ books in which a sister and brother zip around the historical universe, discovering cool stuff and generally setting things right so the world as we know it doesn’t suffer some sort of inexplicable and possibly catastrophic rupture in its fabric. And it was obvious that this mostly full house on Wednesday morning knew the Tree House tales very well, indeed. The books are, for children of a more contemporary age, what Junie B. Jones and Goosebumps and Ramona the Pest and the Hardy Boys and Nancy Drew and Trixie Belden and Tom Swift were to their older siblings and parents and grandparents: pulp fiction with a good hook and an underlying theme that there’s a big world out there, just waiting to be discovered.

So, yes: the lighting, designed by Nathaniel Bartos, was good. But in Oregon Children’s Theatre’s current show, “Magic Tree House: A Night in New Orleans,” it’s the music that takes the cakewalk. And little wonder. This stage adaptation (based, if you’re counting, on “A Good Night for Ghosts,” Magic Tree House #42) features a youthful Louis Armstrong, who, as a teen, is working so hard at menial jobs that he doesn’t have time to tend to his horn and begin a career that would make musical history. It’s up to time travelers Annie (Ashlee Waldbauer) and Jack (Thom Hilton) to persuade him that trumpeters can make good money, too, and he really should quit shoveling coal for the furnaces of Storyville and start following his bliss.

Director Stan Foote and musical director Mont Chris Hubbard have pulled out the stops with their onstage New Orleans-style band, which enters the stage like a traditional funeral-procession marching band and then settles into its seats on a bandstand. The six-piece outfit includes Hubbard on keyboards, the fine bassist Andre St. James, Thomas Barber on trumpet, Bryant Byers on trombone, Sam Foulger on drums, and reed player Mieke Bruggeman (with Mary-Sue Tobin subbing for some performances) on sax, flute, and clarinet, in addition to some banjo-plucking and ukulele-strumming from the acting ensemble. The songs – a generous 15, in a show that runs a little over an hour – are by New Orleans R&B legend Allen Toussaint, who provides about as good a musical bloodline as a show can get. And high school senior Javon Carter, starring as the young Armstrong, gives a magnetic and self-assured performance: he holds the stage with an easy grace, and sings (in a buttery style unlike Armstrong’s gravelly tone) with the command of a stage vet.

The music is the heart and soul of “A Night in New Orleans,” and if anything it’d be good to have even more of it – maybe a couple of breakouts for the band to cut loose and really show its stuff. But like most children’s theater companies, OCT has time restraints (most of its audiences are here on school field trips) and a fair amount of time has to be given over to the plot. The Magic Tree House franchise must be served, and the narrative can get a little clunky. The ghosts, so prominent in the title of the book, seem almost a side issue onstage, although Daniel East makes a stirringly swashbuckling appearance as the banjo-toting spectre of pirate king Jean Lafitte. There are, apparently, a number of hoops that Jack and Annie must jump through in each episode of the series, and the young audience seems to expect them. It’s understandable that the story skips some of the grittier aspects of Armstrong’s youthful life (he was in and out of trouble with the law, although the script mentions just one almost accidental transgression; those coal customers were in the red-light district of Storyville, where he hung around the clubs and soaked in the music; his mother was a prostitute; his father abandoned the family when Louis was an infant) – after all, the target audience for the Magic Tree House books is kids ages 5 to 8. But things also tend to get a little preachy, and a little obviously instructional, and although that might play well to the didactitions of the educational establishment, it generally also gets in the way of just telling a good story. Wednesday morning’s crowd wound up clapping enthusiastically in rhythm to the tunes, but minds seemed to wander during the telling of the tale.

But it really IS about the music, and on that score “A Night in New Orleans” is a solid hit. As usual, OCT’s production values are high, with special nods to Sara Mishler Martins for her vivid choreography and especially the talented Margaret Louise Chapman for her spot-on period costumes. The mostly young cast (it’s rounded out capably by song-and-dancer Haley Ward and Louis’ trio of sidekicks: Nate Golden as Happy, Isaiah Rosales as Big Nose, Xavier B. Warner as Little Mac) is well-rehearsed and appealing, with the energy flowing beneath the twin poles of Carter’s congenial Armstrong and Waldbauer’s spunky Annie. Book and lyrics are by Murray Horwitz and Will Osborne, who knows the territory: He’s married to Mary Pope Osborne, author of the Magic Tree House books.

*

“A Night in New Orleans” continues at the Newmark Theatre through Nov. 10, with weekday school performances and public performances on the weekends. The show is recommended for ages 4 and older. Ticket and schedule information are here.