public interface TwitterScheduledTweetApi
| Modifier and Type | Method and Description |
|---|---|
BaseAdsResponse<ScheduledTweet> |
create(java.lang.String accountId,
java.util.Date scheduledAt,
java.lang.String text,
java.lang.String userId,
java.lang.String cardURI,
java.util.List<java.lang.String> mediaIds,
boolean nullCast) |
BaseAdsResponse<ScheduledTweet> |
delete(java.lang.String accountId,
java.lang.String scheduledTweetId) |
BaseAdsListResponseIterable<ScheduledTweet> |
fetch(java.lang.String accountId,
java.lang.String userId,
boolean withDeleted,
java.lang.Integer count,
java.lang.String cursor) |
BaseAdsResponse<ScheduledTweet> |
fetchScheduledTweetById(java.lang.String accountId,
java.lang.String scheduledTweetId,
boolean withDeleted) |
BaseAdsResponse<ScheduledTweet> |
update(java.lang.String accountId,
java.lang.String scheduledTweetId,
java.util.Date scheduledAt,
java.lang.String text,
java.lang.String cardURI,
java.util.List<java.lang.String> mediaIds) |
BaseAdsListResponseIterable<ScheduledTweet> fetch(java.lang.String accountId, java.lang.String userId, boolean withDeleted, java.lang.Integer count, java.lang.String cursor) throws TwitterException
accountId - The identifier for the leveraged account.userId - Full promotable user Id.withDeleted - Include deleted results in your request. Defaults to false.count - Specifies the number of Scheduled Promoted Tweets to try to retrieve, up to a maximum of 1000 per distinct request.cursor - Specifies a cursor to get the next page of Scheduled Promoted Tweets.TwitterExceptionBaseAdsResponse<ScheduledTweet> fetchScheduledTweetById(java.lang.String accountId, java.lang.String scheduledTweetId, boolean withDeleted) throws TwitterException
accountId - The identifier for the leveraged account.scheduledTweetId - The id of the scheduled tweetwithDeleted - Include deleted results in your request. Defaults to false.TwitterExceptionBaseAdsResponse<ScheduledTweet> create(java.lang.String accountId, java.util.Date scheduledAt, java.lang.String text, java.lang.String userId, java.lang.String cardURI, java.util.List<java.lang.String> mediaIds, boolean nullCast) throws TwitterException
accountId - The identifier for the leveraged account.userId - The user ID of the advertiser on behalf of whom you are posting the Tweet. The advertiser must grant your handle (or handles) access to their ads account via ads.twitter.com. This permission allows you to call the API using the OAuth tokens of your own handle rather than the advertisers..scheduledAt - The time, expressed in ISO 8601, that the Tweet should be published (or go live).. 2017-12-31T23:59:00Z
Tweets can only be scheduled up to one year in the future.
Note: Tweets should only be scheduled at minute-granularity; seconds will be ignored.text - The text of your status update, typically up to 140 characters.cardURI - Associate a card with the Tweet using the card_uri value from any cards response, if available. card://855591459410511943
IMPORTANTmediaIds - Associate media with the Tweet by specifying a comma-separated list of identifiers. Include up to 4 images, 1 animated GIF, or 1 video. See Uploading Media for additional details on uploading media.nullCast - Whether to create a nullcasted (or Promoted-only) Tweet..TwitterExceptionBaseAdsResponse<ScheduledTweet> update(java.lang.String accountId, java.lang.String scheduledTweetId, java.util.Date scheduledAt, java.lang.String text, java.lang.String cardURI, java.util.List<java.lang.String> mediaIds) throws TwitterException
TwitterExceptionBaseAdsResponse<ScheduledTweet> delete(java.lang.String accountId, java.lang.String scheduledTweetId) throws TwitterException
TwitterException