"a XML API" or "an XML API"? [duplicate]

On StackOverflow I wrote :

It often comes that a XML API reorder tags without our will.
(API : Application Program Interface)

Is "a XML API" the correct sentence or "an XML API" ?


It's "an X...". The reason is that it's "an" before a vowel sound, no matter how you spell it, and the name of the letter X sounds like "ex".