you didn't mess up. you weren't clear about the rules, quite possibly no one told you.
addiction will use any excuse to avoid taking action today, and getting help is a great one. don't beat yourself up. i know its hard not to but its not useful.
hopefully what happened today will help you to reframe your use, and therefore stop. reframing, taking a different perspective, is how to get around the fact willpower does not work.
you are in a life or death situation. when i used to abuse opiates and alcohol (and benzos) on a daily basis my now ex would stay up watching me breathe if he thought i'd done too much. i thought he was being stupid but now i can see he wasn't.
whatever help you get, they can't do your recovery for you, that has to come from you. get to meetings if you can so you can talk to people who know exactly what you're going through. i would ask cgl to start applying for funding for rehab ASAP, its not guaranteed and it would take a long time, but its a good contingency and if you get yourself sorted without it, excellent, if you don't then you have that to fall back on.
this is the sort of time that 'just for today' might actually be useful. i hated being told i didn't have to use today before, cos i fucking wanted to. but you really don't have to drown your feelings in a bottle of wine today. if you do, then don't get upset, using is what addicts do. but if you don't think about how proud you'll be, it'll give you a boost, even if you do drown your feelings tomorrow. you'll have done it once.