Brittomara (Cara Collins) is a shape-shifting devil who offers a supernatural power to Fabian (Michael Day) in the world premiere of "If I Were You" by Jake Heggie and Gene Scheer, presented by the Merola Opera Program, August 1-6 at the Herbst Theatre in San Francisco. (Photo by Kristen Loken)

When Mozart composed his operas, he knew his singers, their sound, range and potential.

When prolific American composer Jake Heggie and librettist Gene Scheer were commissioned by the Merola Opera Program to write a new work for the summer program, the singers hadn’t yet appeared on the scene.

All Heggie could surmise was that he would be dealing with fresh young voices and that the singers would give their all to the performances.

That is exactly what happened at the world premiere of the exuberant, propulsive work “If I Were You” at the Herbst Theatre: They sang with high spirits and wholehearted engagement.

Heggie, whose “Dead Man Walking’’ is the most often-performed contemporary opera in the U.S., writes a score that is rich and tonal, with few big takeaway arias, but with plenty of melodic imagery that closely defines each character in this fascinating tale, and plenty of vocal challenges.

With Nicole Paiement conducting, the entire enterprise was vocally compelling and highly theatrical.

The singers picked up on the excitement and responded by singing their collective hearts out. So fast forward was the performance that there wasn’t a dramatic lapse the entire evening.

The story is Faustian: When young Fabian comes to after a car accident, he meets the devil in the person of Brittomara, an attendant  in the ER-bound ambulance. She convinces him that he can buy eternal life by reciting a Sanskrit mantra that allows him to inhabit the bodies of others.

Fabian is convinced: He has a boring job and a demanding boss, and after he tries life as the difficult boss and the best friend of the woman he is enamored of and a number of others, he is still despairing, despite the ravishing Diana, who loves him and tries to help. There is no looking back — he has traded in his soul.

Outstanding in the opening night cast (some roles were double cast) were mezzo Cara Collins, who shone as the demonic Brittomara. She has several identities herself: In addition to her role as devil’s brokers, she appears as an entertaining bartender and a gossipy beautician, and Collins changed character with light-hearted flair.

American composer Jake Heggie, left, and librettist Gene Scheer collaborated on the new commissioned work, “If I Were You.” (Photo by Stefan Cohen)

Soprano Esther Tonea was the lustrous-voiced Diana, who struggles to save Fabian (tenor Michael Day). Rafael Porto made a potent appearance as Fabian’s boss, and some of the others inhabited by Fabian were well portrayed by Patricia Westley, Timothy Murray and Brandon Russell.

Keturah Stickann’s staging and the design team’s explosive sound effects and projections made crystal clear the complex narrative, which is based on a 1947 novel by French writer Julien Green. The small chorus of Merola singers enhanced the underworld.

The Merola Opera Program singers, coaches and directors are going places. There is one more chance to hear them and experience their work: The Merola Grand Finale takes place at the San Francisco War Memorial Opera House on Aug. 17.