Based on the wording of the statute, it looks like the strongest argument would be for using the exchange rate at the time that you pay the provider, or more accurately, for using the amount of United States dollars required to pay the bill (i.e. not the notional midmarket rate). Under the Internal Revenue Code, "[a]ny amount ... distributed out of [an HSA] which is used exclusively to pay qualified medical expenses of any account beneficiary shall not be includible in gross income", but conversely, "[a]ny amount ... distributed out of [an HSA] which is not used exclusively to pay the qualified medical expenses of the account beneficiary shall be included in the gross income of such beneficiary". 26 USC § 223(f)(1), (2) (emphasis mine). Also, under the statute, the term "qualified medical expenses" means in relevant part "amounts paid by such beneficiary for medical care". 26 USC § 223(d)(2)(A) (emphasis added).
As can be seen, the focus of the test for whether an HSA distribution is included in income is on whether the distribution is used "to pay" qualified medical expenses (which are "amounts paid"). This suggests to me that the relevant question is how much USD did you actually fork over to pay the bill, or, if you didn't pay in USD, how much you would have had to fork over if you had paid in USD. This is only one argument, not a definitive conclusion. You should do your own research and draw your own conclusions. I make no comment on any other issue raised by the original post.