Shredded coconut is preserved and whitened with sulfite. It could be used in the water as well, or comes in from the coconut meat when they squeeze it dry of the water. They may sulfite the meat before squeezing it during processing when they are getting the last of the water out, since there isn't much flavor in fresh coconut water, which is clean.
It's also possible that the red coloring is the source of the sulfite (assuming that's what you reacted to), or the little bit of guava juice in the mix could have been preserved. A lot of colorings have sulfite (azo dyes).
If you have that kind of reaction, the true allergic one, I would be carrying Benadryl. But don't use the liquid; it has sulfites. The tablets do not. Look up Valsalva maneuvers. I can usually get my heart rate down that way. My cardiologist has also given me atenolol pills to take when the tachycardia reaction comes on, and they help.
I recommend (as a patient) everyone with allergies triggered by something they ingest start keeping a food log so they can identify food, drink, medicine and chemical triggers.
I'm glad you posted this reaction. I was thinking of trying the juice at a sample table the other day. Glad I didn't do it! I get the rapid heart beat too, needed cardioversion for it once.