Using the iOS 5 Twitter API to send a private message?

Can I use the iOS 5 Twitter API to send a private (direct) message? I don't seem to know how to do this.

+4
source share
1 answer

You cannot edit the text that the User sends through the Twitter Compose window, but you can set the source using the setInitialText: method and use the DM syntax for Twitter. Twitter DMX syntax is described here.

 TWTweetComposeViewController *controller = [[TWTweetComposeViewController alloc] init]; [controller setInitialText:@"d some-twitter-username Something I want to tweet"; 

You cannot change the window or tweets after the view is displayed, so that you cannot transfer it at the end when the user clicks "Submit". The Twitter Framework does not abstract DM'ing out of the box with all the features, such as choosing who to send to, but using this Twitter Twitter syntax is just fine if you know the recipient or ask the user to enter the recipientโ€™s username after d

+3
source

All Articles