Switching Single and Double Quotes

You could isolate the System clipboard by using a Named clipboard. But I'd suggest copying the text from the clipboard to a local variable and working on it there. You can put the result back on the clipboard or paste it into the front document.

And I'd think you'd be better off coding this in Perl, say, because there are a lot of little gotchas in this kind of translation that can easily overwhelm you navigating a pile of Keyboard Maestro actions. You can get an idea of how this works in Literary Toolbox III and Text Toolbox I in the Smart/Straighten quote macros.