Return Tweet successfully sent

Get a response on successfully sent tweet, using code 200 of Twitter API. 

Something like this:
return ($textContents->OAuth->response["code"] == 200);