The question asks for "the correct answer". I don't think that's a realistic goal, and in a sense, a part of the OP's problem is the very assumption that there must be one correct meaning for the word "key" that we could find in some kind of ISO standard catalog of definitions. I see challenges with the feasibility of finding such correctness. Just to try something different, as an experiment, I try to answer from a subjective point of view, because after all, music is culture, people doing things and talking about it. The doing and talking is as diverse and ever-changing as people themselves, and failing to see the diversity is an obstacle to understanding music.
I don't play J.S. Bach and don't study the history of Western classical music, so I never use the term key in a historical sense. I also don't require the use of a leading tone in a piece to say it's in a minor key, even though I've heard that there have been people who do require such things. I don't have a lot of use for melodic and harmonic minor scales - they just mean temporarily altering some scale degrees, relative to the basic default scale i.e. reference grid that's given by the key signature. I consider key signatures as just convenient helpers - because pieces tend to use "in-key" notes very often, and a key signature reduces the amount of accidentals needed to write down a piece or passage of music.
What's common and what's not - I grew up in a culture where temporary accindentals were used in pieces all the time. When I was a small child, my aunt showed me some of the basics of musical notation, and accidentals were introduced within the first five minutes. Now G is sharp, now it's not sharp anymore. So what if there's an accidental somewhere, it doesn't change my feeling of balance and where the home chord is. You can use a B7 chord in a tune that's in A minor. (Much later I heard this is called a secondary dominant ... ooh what pompous names they have for simple everyday things)
What "key" meant for me was very practical. Whether the tune's center chord is minor or major, and how high it is. Well you can tell if a tune is in minor or major anyway, so stating that was kind of redundant, but ok. (edit: for those tunes that are ambivalent about which side is more prominent, saying "minor" or "major" is useful, because it tells which side they mean) Key was chosen according to who is singing and how high or low they could sing. Or if there are transposing instruments like saxophone or trumpet, let's select the key i.e. pitch height so that they don't have to play too many sharps or flats, if they aren't very good players.
Then, decades pass and the internet comes around and I see music.stackexchange. People asking questions about simple concepts like scale and key, as if they've had no practical touch with music-making, and are trying to construct music from theoretical formulas they found from random places. Tell me all rules of music. What is the correct definition of such and such term, how come there is a note that's "outside the key"... Umm, try it out in your own music in practice?
Ok. Now feel free to downvote and say that this approach for answering is against rules. ;) Music and life are about rules that can be programmed and calculated, right...?