Package blue.starry.penicillin.extensions.endpoints

Types

Link copied to clipboard
class TweetstormHandler(val client: ApiClient, val listener: TweetstormListener) : StreamHandler<TweetstormListener>

Default TweetStorm StreamHandler. Accepts listener of TweetstormListener.

Link copied to clipboard
interface TweetstormListener : StreamListener

An event model interface for TweetstormHandler.

Functions

Link copied to clipboard
suspend fun Media.awaitProcessing(timeout: Duration? = null): Media

Awaits until media processing is done, and returns Media response. This operation is suspendable.

Link copied to clipboard
fun Lists.clone(sourceId: Long): ApiAction<JsonObjectResponse<TwitterList>>

Clones this list. The name, description and mode are copied to new list.

Link copied to clipboard
fun Statuses.createPollTweet(    status: String,     choices: List<String>,     minutes: Int = 1440,     vararg options: Option): ApiAction<Status>

Creates new poll tweet.

Link copied to clipboard
fun Statuses.createWithMedia(    status: String,     media: List<MediaComponent>,     vararg options: Option): ApiAction<JsonObjectResponse<Status>>

Creates new tweet with media.

Link copied to clipboard
fun Lists.hasMember(    listId: Long,     userId: Long,     vararg options: Option): ApiAction<Boolean>
fun Lists.hasMember(    listId: Long,     screenName: String,     vararg options: Option): ApiAction<Boolean>
fun Lists.hasMember(    slug: String,     ownerId: Long,     userId: Long,     vararg options: Option): ApiAction<Boolean>
fun Lists.hasMember(    slug: String,     ownerId: Long,     screenName: String,     vararg options: Option): ApiAction<Boolean>
fun Lists.hasMember(    slug: String,     ownerScreenName: String,     userId: Long,     vararg options: Option): ApiAction<Boolean>
fun Lists.hasMember(    slug: String,     ownerScreenName: String,     screenName: String,     vararg options: Option): ApiAction<Boolean>

Returns true if the specified user is a member of the specified list.

Link copied to clipboard
fun Stream.tweetstorm(    customHost: EndpointHost = EndpointHost.UserStream,     delimited: StreamDelimitedBy = StreamDelimitedBy.Default,     stringifyFriendIds: Boolean? = null,     vararg options: Option): StreamApiAction<TweetstormListener, TweetstormHandler>

Connects to Tweetstorm with custom EndpointHost.

fun Stream.tweetstorm(    customHost: String,     delimited: StreamDelimitedBy = StreamDelimitedBy.Default,     stringifyFriendIds: Boolean? = null,     vararg options: Option): StreamApiAction<TweetstormListener, TweetstormHandler>

Connects to Tweetstorm with custom host.

Link copied to clipboard
fun Account.updateProfileBackgroundImage(    media: MediaComponent,     tile: Boolean? = null,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): ApiAction<JsonObjectApiAction<User>>

Update profile background image.

Properties

Link copied to clipboard

Shorthand property to Stream.tweetstorm.