Package blue.starry.penicillin.endpoints.lists

Types

Link copied to clipboard
enum ListVisibilityMode : Enum<ListVisibilityMode> , StringJsonEnum, EnumRequestParameter

Represents list mode. For example, "Private" means protected list, and is invisible to unfollowed users.

Functions

Link copied to clipboard
fun Lists.addMember(    listId: Long,     userId: Long,     vararg options: Option): EmptyApiAction
fun Lists.addMember(    listId: Long,     screenName: String,     vararg options: Option): EmptyApiAction
fun Lists.addMember(    slug: String,     ownerId: Long,     userId: Long,     vararg options: Option): EmptyApiAction
fun Lists.addMember(    slug: String,     ownerId: Long,     screenName: String,     vararg options: Option): EmptyApiAction
fun Lists.addMember(    slug: String,     ownerScreenName: String,     userId: Long,     vararg options: Option): EmptyApiAction
fun Lists.addMember(    slug: String,     ownerScreenName: String,     screenName: String,     vararg options: Option): EmptyApiAction

Add a member to a list. The authenticated user must own the list to be able to add members to it. Note that lists cannot have more than 5,000 members.

Link copied to clipboard
fun Lists.addMembersByScreenNames(    listId: Long,     screenNames: List<String>,     vararg options: Option): EmptyApiAction
fun Lists.addMembersByScreenNames(    slug: String,     ownerId: Long,     screenNames: List<String>,     vararg options: Option): EmptyApiAction
fun Lists.addMembersByScreenNames(    slug: String,     ownerScreenName: String,     screenNames: List<String>,     vararg options: Option): EmptyApiAction

Adds multiple members to a list, by specifying a comma-separated list of member ids or screen names. The authenticated user must own the list to be able to add members to it. Note that lists can't have more than 5,000 members, and you are limited to adding up to 100 members to a list at a time with this method. Please note that there can be issues with lists that rapidly remove and add memberships. Take care when using these methods such that you are not too rapidly switching between removals and adds on the same list.

Link copied to clipboard
fun Lists.addMembersByUserIds(    listId: Long,     userIds: List<Long>,     vararg options: Option): EmptyApiAction
fun Lists.addMembersByUserIds(    slug: String,     ownerId: Long,     userIds: List<Long>,     vararg options: Option): EmptyApiAction
fun Lists.addMembersByUserIds(    slug: String,     ownerScreenName: String,     userIds: List<Long>,     vararg options: Option): EmptyApiAction

Adds multiple members to a list, by specifying a comma-separated list of member ids or screen names. The authenticated user must own the list to be able to add members to it. Note that lists can't have more than 5,000 members, and you are limited to adding up to 100 members to a list at a time with this method. Please note that there can be issues with lists that rapidly remove and add memberships. Take care when using these methods such that you are not too rapidly switching between removals and adds on the same list.

Link copied to clipboard
fun Lists.create(    name: String,     mode: ListVisibilityMode = ListVisibilityMode.Default,     description: String? = null,     vararg options: Option): JsonObjectApiAction<TwitterList>

Creates a new list for the authenticated user. Note that you can create up to 1000 lists per account.

Link copied to clipboard
fun Lists.delete(listId: Long, vararg options: Option): JsonObjectApiAction<TwitterList>

Deletes the specified list. The authenticated user must own the list to be able to destroy it.

Link copied to clipboard
fun Lists.deleteByOwnerId(    slug: String,     ownerId: Long,     vararg options: Option): JsonObjectApiAction<TwitterList>

Deletes the specified list. The authenticated user must own the list to be able to destroy it.

Link copied to clipboard
fun Lists.deleteByOwnerScreenName(    slug: String,     ownerScreenName: String,     vararg options: Option): JsonObjectApiAction<TwitterList>

Deletes the specified list. The authenticated user must own the list to be able to destroy it.

Link copied to clipboard
fun Lists.list(reverse: Boolean? = null, vararg options: Option): JsonArrayApiAction<TwitterList>
fun Lists.list(    userId: Long,     reverse: Boolean? = null,     vararg options: Option): JsonArrayApiAction<TwitterList>
fun Lists.list(    screenName: String,     reverse: Boolean? = null,     vararg options: Option): JsonArrayApiAction<TwitterList>

Returns all lists the authenticating or specified user subscribes to, including their own. The user is specified using the user_id or screen_name parameters. If no user is given, the authenticating user is used. A maximum of 100 results will be returned by this call. Subscribed lists are returned first, followed by owned lists. This means that if a user subscribes to 90 lists and owns 20 lists, this method returns 90 subscriptions and 10 owned lists. The reverse method returns owned lists first, so with reverse=true, 20 owned lists and 80 subscriptions would be returned. If your goal is to obtain every list a user owns or subscribes to, use GET lists/ownerships and/or GET lists/subscriptions instead.

Link copied to clipboard
fun Lists.member(    listId: Long,     userId: Long,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): JsonObjectApiAction<User>
fun Lists.member(    listId: Long,     screenName: String,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): JsonObjectApiAction<User>
fun Lists.member(    slug: String,     ownerId: Long,     userId: Long,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): JsonObjectApiAction<User>
fun Lists.member(    slug: String,     ownerId: Long,     screenName: String,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): JsonObjectApiAction<User>
fun Lists.member(    slug: String,     ownerScreenName: String,     userId: Long,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): JsonObjectApiAction<User>
fun Lists.member(    slug: String,     ownerScreenName: String,     screenName: String,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): JsonObjectApiAction<User>

Check if the specified user is a member of the specified list.

Link copied to clipboard
fun Lists.members(    listId: Long,     count: Int? = null,     cursor: Long? = null,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): CursorJsonObjectApiAction<CursorUsers, User>

Returns the members of the specified list. Private list members will only be shown if the authenticated user owns the specified list.

Link copied to clipboard
fun Lists.membersByOwnerId(    slug: String,     ownerId: Long,     count: Int? = null,     cursor: Long? = null,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): CursorJsonObjectApiAction<CursorUsers, User>

Returns the members of the specified list. Private list members will only be shown if the authenticated user owns the specified list.

Link copied to clipboard
fun Lists.membersByOwnerScreenName(    slug: String,     ownerScreenName: String,     count: Int? = null,     cursor: Long? = null,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): CursorJsonObjectApiAction<CursorUsers, User>

Returns the members of the specified list. Private list members will only be shown if the authenticated user owns the specified list.

Link copied to clipboard
fun Lists.memberships(    count: Int? = null,     cursor: Long? = null,     filterToOwnedLists: Boolean? = null,     vararg options: Option): CursorJsonObjectApiAction<CursorLists, TwitterList>

Returns the lists the specified user has been added to. If user_id or screen_name are not provided, the memberships for the authenticating user are returned.

Link copied to clipboard
fun Lists.membershipsByScreenName(    screenName: String,     count: Int? = null,     cursor: Long? = null,     filterToOwnedLists: Boolean? = null,     vararg options: Option): CursorJsonObjectApiAction<CursorLists, TwitterList>

Returns the lists the specified user has been added to. If user_id or screen_name are not provided, the memberships for the authenticating user are returned.

Link copied to clipboard
fun Lists.membershipsByUserId(    userId: Long,     count: Int? = null,     cursor: Long? = null,     filterToOwnedLists: Boolean? = null,     vararg options: Option): CursorJsonObjectApiAction<CursorLists, TwitterList>

Returns the lists the specified user has been added to. If user_id or screen_name are not provided, the memberships for the authenticating user are returned.

Link copied to clipboard
fun Lists.ownerships(    count: Int? = null,     cursor: Long? = null,     vararg options: Option): CursorJsonObjectApiAction<CursorLists, TwitterList>
fun Lists.ownerships(    screenName: String,     count: Int? = null,     cursor: Long? = null,     vararg options: Option): CursorJsonObjectApiAction<CursorLists, TwitterList>

Returns the lists owned by the specified Twitter user. Private lists will only be shown if the authenticated user is also the owner of the lists.

Link copied to clipboard
fun Lists.ownershipsByUserId(    userId: Long,     count: Int? = null,     cursor: Long? = null,     vararg options: Option): CursorJsonObjectApiAction<CursorLists, TwitterList>

Returns the lists owned by the specified Twitter user. Private lists will only be shown if the authenticated user is also the owner of the lists.

Link copied to clipboard
fun Lists.removeMember(    listId: Long,     userId: Long,     vararg options: Option): EmptyApiAction
fun Lists.removeMember(    listId: Long,     screenName: String,     vararg options: Option): EmptyApiAction
fun Lists.removeMember(    slug: String,     ownerId: Long,     userId: Long,     vararg options: Option): EmptyApiAction
fun Lists.removeMember(    slug: String,     ownerId: Long,     screenName: String,     vararg options: Option): EmptyApiAction
fun Lists.removeMember(    slug: String,     ownerScreenName: String,     userId: Long,     vararg options: Option): EmptyApiAction
fun Lists.removeMember(    slug: String,     ownerScreenName: String,     screenName: String,     vararg options: Option): EmptyApiAction

Removes the specified member from the list. The authenticated user must be the list's owner to remove members from the list.

Link copied to clipboard
fun Lists.removeMembersByScreenNames(    listId: Long,     screenNames: List<String>,     vararg options: Option): EmptyApiAction
fun Lists.removeMembersByScreenNames(    slug: String,     ownerId: Long,     screenNames: List<String>,     vararg options: Option): EmptyApiAction
fun Lists.removeMembersByScreenNames(    slug: String,     ownerScreenName: String,     screenNames: List<String>,     vararg options: Option): EmptyApiAction

Removes multiple members from a list, by specifying a comma-separated list of member ids or screen names. The authenticated user must own the list to be able to remove members from it. Note that lists can't have more than 500 members, and you are limited to removing up to 100 members to a list at a time with this method. Please note that there can be issues with lists that rapidly remove and add memberships. Take care when using these methods such that you are not too rapidly switching between removals and adds on the same list.

Link copied to clipboard
fun Lists.removeMembersByUserIds(    listId: Long,     userIds: List<Long>,     vararg options: Option): EmptyApiAction
fun Lists.removeMembersByUserIds(    slug: String,     ownerId: Long,     userIds: List<Long>,     vararg options: Option): EmptyApiAction
fun Lists.removeMembersByUserIds(    slug: String,     ownerScreenName: String,     userIds: List<Long>,     vararg options: Option): EmptyApiAction

Removes multiple members from a list, by specifying a comma-separated list of member ids or screen names. The authenticated user must own the list to be able to remove members from it. Note that lists can't have more than 500 members, and you are limited to removing up to 100 members to a list at a time with this method. Please note that there can be issues with lists that rapidly remove and add memberships. Take care when using these methods such that you are not too rapidly switching between removals and adds on the same list.

Link copied to clipboard
fun Lists.show(listId: Long, vararg options: Option): JsonObjectApiAction<TwitterList>

Returns the specified list. Private lists will only be shown if the authenticated user owns the specified list.

Link copied to clipboard
fun Lists.showByOwnerId(    slug: String,     ownerId: Long,     vararg options: Option): JsonObjectApiAction<TwitterList>

Returns the specified list. Private lists will only be shown if the authenticated user owns the specified list.

Link copied to clipboard
fun Lists.showByOwnerScreenName(    slug: String,     ownerScreenName: String,     vararg options: Option): JsonObjectApiAction<TwitterList>

Returns the specified list. Private lists will only be shown if the authenticated user owns the specified list.

Link copied to clipboard
fun Lists.subscribe(listId: Long, vararg options: Option): JsonObjectApiAction<TwitterList>

Subscribes the authenticated user to the specified list.

Link copied to clipboard
fun Lists.subscribeByOwnerId(    slug: String,     ownerId: Long,     vararg options: Option): JsonObjectApiAction<TwitterList>

Subscribes the authenticated user to the specified list.

Link copied to clipboard
fun Lists.subscribeByOwnerScreenName(    slug: String,     ownerScreenName: String,     vararg options: Option): JsonObjectApiAction<TwitterList>

Subscribes the authenticated user to the specified list.

Link copied to clipboard
fun Lists.subscriber(    listId: Long,     userId: Long,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): JsonObjectApiAction<User>
fun Lists.subscriber(    listId: Long,     screenName: String,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): JsonObjectApiAction<User>
fun Lists.subscriber(    slug: String,     ownerId: Long,     userId: Long,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): JsonObjectApiAction<User>
fun Lists.subscriber(    slug: String,     ownerId: Long,     screenName: String,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): JsonObjectApiAction<User>
fun Lists.subscriber(    slug: String,     ownerScreenName: String,     userId: Long,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): JsonObjectApiAction<User>
fun Lists.subscriber(    slug: String,     ownerScreenName: String,     screenName: String,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): JsonObjectApiAction<User>

Check if the specified user is a subscriber of the specified list. Returns the user if they are a subscriber.

Link copied to clipboard
fun Lists.subscribers(    listId: Long,     count: Int? = null,     cursor: Long? = null,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): CursorJsonObjectApiAction<CursorUsers, User>

Returns the subscribers of the specified list. Private list subscribers will only be shown if the authenticated user owns the specified list.

Link copied to clipboard
fun Lists.subscribersByOwnerId(    slug: String,     ownerId: Long,     count: Int? = null,     cursor: Long? = null,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): CursorJsonObjectApiAction<CursorUsers, User>

Returns the subscribers of the specified list. Private list subscribers will only be shown if the authenticated user owns the specified list.

Link copied to clipboard
fun Lists.subscribersByOwnerScreenName(    slug: String,     ownerScreenName: String,     count: Int? = null,     cursor: Long? = null,     includeEntities: Boolean? = null,     skipStatus: Boolean? = null,     vararg options: Option): CursorJsonObjectApiAction<CursorUsers, User>

Returns the subscribers of the specified list. Private list subscribers will only be shown if the authenticated user owns the specified list.

Link copied to clipboard
fun Lists.subscriptions(    count: Int? = null,     cursor: Long? = null,     vararg options: Option): CursorJsonObjectApiAction<CursorLists, TwitterList>

Obtain a collection of the lists the specified user is subscribed to, 20 lists per page by default. Does not include the user's own lists.

Link copied to clipboard
fun Lists.subscriptionsByScreenName(    screenName: String,     count: Int? = null,     cursor: Long? = null,     vararg options: Option): CursorJsonObjectApiAction<CursorLists, TwitterList>

Obtain a collection of the lists the specified user is subscribed to, 20 lists per page by default. Does not include the user's own lists.

Link copied to clipboard
fun Lists.subscriptionsByUserId(    userId: Long,     count: Int? = null,     cursor: Long? = null,     vararg options: Option): CursorJsonObjectApiAction<CursorLists, TwitterList>

Obtain a collection of the lists the specified user is subscribed to, 20 lists per page by default. Does not include the user's own lists.

Link copied to clipboard
fun Lists.unsubscribe(listId: Long, vararg options: Option): JsonObjectApiAction<TwitterList>

Unsubscribes the authenticated user from the specified list.

Link copied to clipboard
fun Lists.unsubscribeByOwnerId(    slug: String,     ownerId: Long,     vararg options: Option): JsonObjectApiAction<TwitterList>

Unsubscribes the authenticated user from the specified list.

Link copied to clipboard
fun Lists.unsubscribeByOwnerScreenName(    slug: String,     ownerScreenName: String,     vararg options: Option): JsonObjectApiAction<TwitterList>

Unsubscribes the authenticated user from the specified list.

Link copied to clipboard
fun Lists.updateByOwnerId(    slug: String,     ownerId: Long,     name: String? = null,     mode: ListVisibilityMode = ListVisibilityMode.Default,     description: String? = null,     vararg options: Option): EmptyApiAction

Updates the specified list. The authenticated user must own the list to be able to update it.

Link copied to clipboard
fun Lists.updateByOwnerScreenName(    slug: String,     ownerScreenName: String,     name: String? = null,     mode: ListVisibilityMode = ListVisibilityMode.Default,     description: String? = null,     vararg options: Option): EmptyApiAction

Updates the specified list. The authenticated user must own the list to be able to update it.

Properties

Link copied to clipboard
val Lists.list: JsonArrayApiAction<TwitterList>

Shorthand property to Lists.list.

Link copied to clipboard

Shorthand property to Lists.memberships.

Link copied to clipboard

Shorthand property to Lists.ownerships.

Link copied to clipboard

Shorthand property to Lists.subscriptions.