Class BookmarksApi


  • public class BookmarksApi
    extends ApiCommon
    • Constructor Detail

      • BookmarksApi

        public BookmarksApi()
    • Method Detail

      • getUsersIdBookmarksCall

        public okhttp3.Call getUsersIdBookmarksCall​(String id,
                                                    Integer maxResults,
                                                    String paginationToken,
                                                    Set<String> expansions,
                                                    Set<String> tweetFields,
                                                    Set<String> userFields,
                                                    Set<String> mediaFields,
                                                    Set<String> placeFields,
                                                    Set<String> pollFields,
                                                    ApiCallback _callback)
                                             throws ApiException
        Build call for getUsersIdBookmarks
        Parameters:
        id - The ID of the user for whom to return results (required)
        maxResults - The maximum number of results (optional)
        paginationToken - This parameter is used to get the next 'page' of results. (optional)
        expansions - A comma separated list of fields to expand. (optional)
        tweetFields - A comma separated list of Tweet fields to display. (optional)
        userFields - A comma separated list of User fields to display. (optional)
        mediaFields - A comma separated list of Media fields to display. (optional)
        placeFields - A comma separated list of Place fields to display. (optional)
        pollFields - A comma separated list of Poll fields to display. (optional)
        _callback - Callback for upload/download progress
        Returns:
        Call to execute
        Throws:
        ApiException - If fail to serialize the request body object
        Http Response Details:
        Status Code Description Response Headers
        200 The request was successful -
        0 The request has failed. -
      • getUsersIdBookmarks

        public GenericTweetsTimelineResponse getUsersIdBookmarks​(String id,
                                                                 Integer maxResults,
                                                                 String paginationToken,
                                                                 Set<String> expansions,
                                                                 Set<String> tweetFields,
                                                                 Set<String> userFields,
                                                                 Set<String> mediaFields,
                                                                 Set<String> placeFields,
                                                                 Set<String> pollFields)
                                                          throws ApiException
        Bookmarks by User Returns Tweet objects that have been bookmarked by the requesting user
        Parameters:
        id - The ID of the user for whom to return results (required)
        maxResults - The maximum number of results (optional)
        paginationToken - This parameter is used to get the next 'page' of results. (optional)
        expansions - A comma separated list of fields to expand. (optional)
        tweetFields - A comma separated list of Tweet fields to display. (optional)
        userFields - A comma separated list of User fields to display. (optional)
        mediaFields - A comma separated list of Media fields to display. (optional)
        placeFields - A comma separated list of Place fields to display. (optional)
        pollFields - A comma separated list of Poll fields to display. (optional)
        Returns:
        GenericTweetsTimelineResponse
        Throws:
        ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
        Http Response Details:
        Status Code Description Response Headers
        200 The request was successful -
        0 The request has failed. -
      • getUsersIdBookmarksWithHttpInfo

        public ApiResponse<GenericTweetsTimelineResponse> getUsersIdBookmarksWithHttpInfo​(String id,
                                                                                          Integer maxResults,
                                                                                          String paginationToken,
                                                                                          Set<String> expansions,
                                                                                          Set<String> tweetFields,
                                                                                          Set<String> userFields,
                                                                                          Set<String> mediaFields,
                                                                                          Set<String> placeFields,
                                                                                          Set<String> pollFields)
                                                                                   throws ApiException
        Bookmarks by User Returns Tweet objects that have been bookmarked by the requesting user
        Parameters:
        id - The ID of the user for whom to return results (required)
        maxResults - The maximum number of results (optional)
        paginationToken - This parameter is used to get the next 'page' of results. (optional)
        expansions - A comma separated list of fields to expand. (optional)
        tweetFields - A comma separated list of Tweet fields to display. (optional)
        userFields - A comma separated list of User fields to display. (optional)
        mediaFields - A comma separated list of Media fields to display. (optional)
        placeFields - A comma separated list of Place fields to display. (optional)
        pollFields - A comma separated list of Poll fields to display. (optional)
        Returns:
        ApiResponse<GenericTweetsTimelineResponse>
        Throws:
        ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
        Http Response Details:
        Status Code Description Response Headers
        200 The request was successful -
        0 The request has failed. -
      • getUsersIdBookmarksAsync

        public okhttp3.Call getUsersIdBookmarksAsync​(String id,
                                                     Integer maxResults,
                                                     String paginationToken,
                                                     Set<String> expansions,
                                                     Set<String> tweetFields,
                                                     Set<String> userFields,
                                                     Set<String> mediaFields,
                                                     Set<String> placeFields,
                                                     Set<String> pollFields,
                                                     ApiCallback<GenericTweetsTimelineResponse> _callback)
                                              throws ApiException
        Bookmarks by User (asynchronously) Returns Tweet objects that have been bookmarked by the requesting user
        Parameters:
        id - The ID of the user for whom to return results (required)
        maxResults - The maximum number of results (optional)
        paginationToken - This parameter is used to get the next 'page' of results. (optional)
        expansions - A comma separated list of fields to expand. (optional)
        tweetFields - A comma separated list of Tweet fields to display. (optional)
        userFields - A comma separated list of User fields to display. (optional)
        mediaFields - A comma separated list of Media fields to display. (optional)
        placeFields - A comma separated list of Place fields to display. (optional)
        pollFields - A comma separated list of Poll fields to display. (optional)
        _callback - The callback to be executed when the API call finishes
        Returns:
        The request call
        Throws:
        ApiException - If fail to process the API call, e.g. serializing the request body object
        Http Response Details:
        Status Code Description Response Headers
        200 The request was successful -
        0 The request has failed. -
      • postUsersIdBookmarksCall

        public okhttp3.Call postUsersIdBookmarksCall​(AddBookmarkRequest addBookmarkRequest,
                                                     String id,
                                                     ApiCallback _callback)
                                              throws ApiException
        Build call for postUsersIdBookmarks
        Parameters:
        addBookmarkRequest - (required)
        id - The ID of the user for whom to add bookmarks (required)
        _callback - Callback for upload/download progress
        Returns:
        Call to execute
        Throws:
        ApiException - If fail to serialize the request body object
        Http Response Details:
        Status Code Description Response Headers
        200 The request was successful -
        0 The request has failed. -
      • postUsersIdBookmarks

        public BookmarkMutationResponse postUsersIdBookmarks​(AddBookmarkRequest addBookmarkRequest,
                                                             String id)
                                                      throws ApiException
        Add Tweet to Bookmarks Adds a Tweet (ID in the body) to the requesting user's (in the path) bookmarks
        Parameters:
        addBookmarkRequest - (required)
        id - The ID of the user for whom to add bookmarks (required)
        Returns:
        BookmarkMutationResponse
        Throws:
        ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
        Http Response Details:
        Status Code Description Response Headers
        200 The request was successful -
        0 The request has failed. -
      • postUsersIdBookmarksWithHttpInfo

        public ApiResponse<BookmarkMutationResponse> postUsersIdBookmarksWithHttpInfo​(AddBookmarkRequest addBookmarkRequest,
                                                                                      String id)
                                                                               throws ApiException
        Add Tweet to Bookmarks Adds a Tweet (ID in the body) to the requesting user's (in the path) bookmarks
        Parameters:
        addBookmarkRequest - (required)
        id - The ID of the user for whom to add bookmarks (required)
        Returns:
        ApiResponse<BookmarkMutationResponse>
        Throws:
        ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
        Http Response Details:
        Status Code Description Response Headers
        200 The request was successful -
        0 The request has failed. -
      • postUsersIdBookmarksAsync

        public okhttp3.Call postUsersIdBookmarksAsync​(AddBookmarkRequest addBookmarkRequest,
                                                      String id,
                                                      ApiCallback<BookmarkMutationResponse> _callback)
                                               throws ApiException
        Add Tweet to Bookmarks (asynchronously) Adds a Tweet (ID in the body) to the requesting user's (in the path) bookmarks
        Parameters:
        addBookmarkRequest - (required)
        id - The ID of the user for whom to add bookmarks (required)
        _callback - The callback to be executed when the API call finishes
        Returns:
        The request call
        Throws:
        ApiException - If fail to process the API call, e.g. serializing the request body object
        Http Response Details:
        Status Code Description Response Headers
        200 The request was successful -
        0 The request has failed. -
      • usersIdBookmarksDeleteCall

        public okhttp3.Call usersIdBookmarksDeleteCall​(String id,
                                                       String tweetId,
                                                       ApiCallback _callback)
                                                throws ApiException
        Build call for usersIdBookmarksDelete
        Parameters:
        id - The ID of the user whose bookmark is to be removed. (required)
        tweetId - The ID of the tweet that the user is removing from bookmarks (required)
        _callback - Callback for upload/download progress
        Returns:
        Call to execute
        Throws:
        ApiException - If fail to serialize the request body object
        Http Response Details:
        Status Code Description Response Headers
        200 The request was successful -
        0 The request has failed. -
      • usersIdBookmarksDelete

        public BookmarkMutationResponse usersIdBookmarksDelete​(String id,
                                                               String tweetId)
                                                        throws ApiException
        Remove a bookmarked Tweet Removes a Tweet from the requesting user's bookmarked Tweets.
        Parameters:
        id - The ID of the user whose bookmark is to be removed. (required)
        tweetId - The ID of the tweet that the user is removing from bookmarks (required)
        Returns:
        BookmarkMutationResponse
        Throws:
        ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
        Http Response Details:
        Status Code Description Response Headers
        200 The request was successful -
        0 The request has failed. -
      • usersIdBookmarksDeleteWithHttpInfo

        public ApiResponse<BookmarkMutationResponse> usersIdBookmarksDeleteWithHttpInfo​(String id,
                                                                                        String tweetId)
                                                                                 throws ApiException
        Remove a bookmarked Tweet Removes a Tweet from the requesting user's bookmarked Tweets.
        Parameters:
        id - The ID of the user whose bookmark is to be removed. (required)
        tweetId - The ID of the tweet that the user is removing from bookmarks (required)
        Returns:
        ApiResponse<BookmarkMutationResponse>
        Throws:
        ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
        Http Response Details:
        Status Code Description Response Headers
        200 The request was successful -
        0 The request has failed. -
      • usersIdBookmarksDeleteAsync

        public okhttp3.Call usersIdBookmarksDeleteAsync​(String id,
                                                        String tweetId,
                                                        ApiCallback<BookmarkMutationResponse> _callback)
                                                 throws ApiException
        Remove a bookmarked Tweet (asynchronously) Removes a Tweet from the requesting user's bookmarked Tweets.
        Parameters:
        id - The ID of the user whose bookmark is to be removed. (required)
        tweetId - The ID of the tweet that the user is removing from bookmarks (required)
        _callback - The callback to be executed when the API call finishes
        Returns:
        The request call
        Throws:
        ApiException - If fail to process the API call, e.g. serializing the request body object
        Http Response Details:
        Status Code Description Response Headers
        200 The request was successful -
        0 The request has failed. -