Setting presence externally

Hello,
I've been trying and failing so far to work out how I can set an ejabberd user's status from an external program.
The scenario is that if a user goes on a telephone call, I want the telephone system to set their status to "On the phone" for anyone who's buddies with that user. It doesn't need to update the user's own jabber client.
Can anyone advise how this might be done?
Thanks very much.

Syndicate content