In a small saucepan, bring the vinegar, 1 cup of water, sugar, salt and peppercorns to a boil over medium heat, stirring until the sugar and salt dissolve.
Remove from heat, separate the shallots and add to a large mason jar then pour the vinegar mixture over the top.
Close the jar and let sit for at least 1 hour before using. Refrigerate for up to 2 weeks and drain before using.
For the corn:
Heat a large cast iron pan over medium heat, add the oil and heat through. Add the shallot and serrano pepper and sauté until the shallots are soft, about 4 minutes. Add the corn and cook, stirring occasionally, until the corn is tender, about an additional 6 minutes.
In a small bowl stir together the paprika, thyme, cumin, all-spice and cinnamon. Add the spice mixture to the coconut milk, stirring to combine. Continue to cook over medium-low heat, stirring occasionally, until the coconut milk has reduced, about an additional 10 minutes.
Stir in a generous forkful of the pickled shallots. Add to a serving bowl and top with the toasted coconut and green onion.