I agree with the above advice. Do not participate in the abuse. I don't know what is going on with your H. But to me it sounds like when he is falling apart inside he projects it onto you and your relationship. However that doesn't make it any less painful for you. When he gets like that I agree that you shouldn't engage him. My H has had a similar projection issue although not as extreme as what you are describing. Sometimes I have to remind H that I'm not the one who hurt him. I doubt your H thinks you are a joke. My H admitted once that he knows he is mean and hurtful at times and that it is because it is easy to lash out and tear others down instead of looking inward at himself. He knows it is wrong and hates that he hurts others. This is not an excuse but did help me not take some of his behavior personally. Hopefully your H will get this behavior under control as it is so destructive to both of you.
Everything comes from within