pass token for user

Hi I am beginner of ejabberd,

I created a mod_offline_pushnotification module extension to call an external php for users offline. Now I need to pass to this php a token. This token should be passed client jabber to server, and save it into db user table. When user is offline and a message come for it, I will call php and pass token of user offline. What is the best approach ?
What is the best approach client to pass this token to the server, and it save into db ?

thanks

Syndicate content