Is there a way to get the application that copied the last item in the clipboard?

I'm trying to make a macro that filters everything that a specific application copies, I can create a macro that triggers when the system clipboard changes but the first thing I want to do is to check if it the source app was a specific one. Is there a way to do this?


The best you can do is base it on the front application.