Removing a contact from Roster


I’ve checked every possible thread to find out how to remove a contact from a Roster but in vain. I’ve also checked for some documentation, but didn’t find any answer.

I have two users A & B having a private chat, each one has a list of contacts with whom he can chat (1 to 1 chat only). I need to implement a blacklisting functionality.

I am developing the chat client in Flex3, I’ve created some static users with their respective Rosters for the tests & dev purposes, the subscriptions will be handled later from PHP in the website (a dating website), I will certainly have other questions for that

So the idea is when A blocks B, I need to close the chat session, remove A from B’s Roster, and then remove B from A’s Roster.

It seems that Roster.removeContact is not suited for this :

" Removes a contact from the roster and revokes all presence subscriptions for that contact. This method will only attempt action if the contact you are trying to remove is currently on the roster in the first place. "

Source: &

So how can I do that ?

how to remove a contact please ?

A more recent version of the API documentation can be found from here:

thanks mate, I already have that link since I’ve based my project on the tutorials you have written, so I found the new API Doc.

But I think there is a lack of tutorials around here