implement some functions for wrapping twitter API