a pastry bag fitted with a 1/2-inch tip; an apple corer; a candy thermometer; a large piping bag fitted with a 5/8-inch round tip
For the cupcakes: Preheat the oven to 350 degrees F. Line a 12-cup cupcake tin with liners and set aside.
Whisk the flour, granulated sugar, cocoa powder, baking powder and salt together in a medium bowl. Mix the buttermilk, coconut oil, vanilla, apple cider vinegar, food coloring and egg in a large bowl. Fold the flour mixture into the buttermilk mixture in two batches until well combined.
Pour about 1/4 cup batter into each cupcake liner and bake until a toothpick inserted into the center comes out clean, 20 to 25 minutes.
Let cool in the tin on a rack for 10 minutes, then remove the cupcakes to the rack to cool completely, about 1 hour.
For the filling: Beat together the powdered sugar, cream cheese, butter, cream and salt in a stand mixer fitted with a paddle attachment on low speed until smooth, then turn up to high speed and beat until lightened, a few minutes. Transfer to a piping bag fitted with a 1/2-inch tip.
Remove the cupcake liners from the cupcakes, then turn them upside down and place them on a parchment-lined sheet pan. Use an apple corer to extract the centers, then fill the centers with the filling. Set aside.
For the marshmallow: Combine the vanilla and 1/4 cup water in a stand mixer fitted with a whisk attachment. Sprinkle the gelatin over the liquid.
Meanwhile, stir together the granulated sugar, corn syrup, salt and 1/4 cup water in a small saucepan. Clip on a candy thermometer. Heat the mixture over medium-high heat until it reaches 240 degrees F, then immediately remove it from the heat and bring it over to the mixer.
Turn the mixer on low speed and drizzle the sugar mixture in a slow and steady stream down the side of the bowl. Once you have added the entire mixture, gradually increase the speed to high and let it mix until lukewarm and fluffy, 7 to 10 minutes. While the mixer is running, grease a rubber spatula with cooking spray and keep it near the mixer; also prepare a large piping bag fitted with a 5/8-inch round tip. Scrape the marshmallow mixture into the piping bag and secure the end with a twist tie.
For the assembly: Pour the shredded coconut onto a wide plate.
Working with a couple of cupcakes at a time, pipe a big blob of marshmallow on top of the cupcakes and use an offset spatula to spread it evenly around the sides. (You want to work with just a few at a time, because the marshmallow firms up quickly!) Cover with coconut. Let set 15 minutes, then enjoy!