Preheat oven to 400 degrees and line a baking sheet with parchment paper. Unfold puff pastry and lay on a lightly floured surface. Pinch together the seams where the dough was folded and roll the dough about 1" longer in each direction.
Transfer dough to the center of the parchment lined baking sheet. Unwrap brie and place on the center of the dough. Spoon pesto onto the center of the brie, spreading within about ½" of the edge. Sprinkle with pine nuts or pecans. Be sure the nuts stay on top of the pesto. If they fall down the side they may poke holes in the dough and create a leak.
Brush dough lightly with beaten egg, then gather the dough up around the cheese and press it together at the top to form a pouch or beggar’s purse. Arrange the top of the pastry into a ruffle and trim any excess dough from areas where it feels particularly thick. Ensure that all edges are sealed.
Brush the entire exterior of the pastry with remaining beaten egg then bake 30–35 minutes until the crust is dark golden brown, rotating if necessary for even browning.
Remove from oven and allow to cool for about 10 minutes before cutting. Serve with your favorite crackers, crostini or even some green apple slices. Enjoy!
One Last Thing
For a sweeter version of this baked brie, substitute seedless raspberry jam for the pesto.