Welcome to the club! Sorry your first experience ended badly.
I'm glad you weren't injured!
Without the missing pin as evidence, it's tough to say what went wrong. I doubt a pin would break in that situation, but I suppose it could happen if it was defective. Was there anything else damaged?
I'd say the only clue is that putting the ring on the pin is usually the last thing done when raising the mast. Perhaps the dealer was too anxious to get you on your way, and he forgot the ring or didn't get it spun all the way on. Or maybe he spun it too far, and it started off the other way.
The other possibility is that someone else fiddled with it, between the time the dealer set it up and you took it out. There are people who will do that sort of thing, just for kicks.
Either way, it's not something which happens often; but it is always a good idea to take a look at your rigging before heading out.