Using screencapture when remotely logged in to a headless mac via ssh

I'm not sure if this will work, but, it's worth a shot...

What is you create an Automator script to take a screen capture, and then run that using the terminal?

Similar to what is described in this TUAW article, however, without the part that mails the screen capture to you.

TUAW Example

Save the Automator script as an application, SSH in, and run open /path/to/the/automator.app