You may want to take the keyboard and the key to the Apple Store to see if they can fix it for you; You can do the same as above at an Apple Authorized Service Center; Here is a link to a video on YouTube which discusses cleaning the Magic Keyboard’s key and the tutorial involves removing and replacing the key. More @Wikipedia
Hover over any link to get a description of the article. Please note that search keywords are sometimes hidden within the full article and don't appear in the description or title.