Skip to content

Commit 658decb

Browse files
committed
Merge remote-tracking branch 'upstream/main' into feature/add-stream-functionality
2 parents c1c27c6 + 926c988 commit 658decb

File tree

655 files changed

+35843
-19788
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

655 files changed

+35843
-19788
lines changed

README.md

Lines changed: 127 additions & 103 deletions
Large diffs are not rendered by default.

docs/AddBookmarkRequest.md

Lines changed: 0 additions & 13 deletions
This file was deleted.

docs/AddOrDeleteRulesRequest.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55

66
## Properties
77

8-
Name | Type | Description | Notes
9-
------------ | ------------- | ------------- | -------------
10-
**add** | [**List<RuleNoId>**](RuleNoId.md) | |
11-
**delete** | [**DeleteRulesRequestDelete**](DeleteRulesRequestDelete.md) | |
8+
| Name | Type | Description | Notes |
9+
|------------ | ------------- | ------------- | -------------|
10+
|**add** | [**List<RuleNoId>**](RuleNoId.md) | | |
11+
|**delete** | [**DeleteRulesRequestDelete**](DeleteRulesRequestDelete.md) | | |
1212

1313

1414

docs/AddOrDeleteRulesResponse.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ A response from modifying user-specified stream filtering rules.
66

77
## Properties
88

9-
Name | Type | Description | Notes
10-
------------ | ------------- | ------------- | -------------
11-
**data** | [**List<Rule>**](Rule.md) | All user-specified stream filtering rules that were created. | [optional]
12-
**meta** | [**RulesResponseMetadata**](RulesResponseMetadata.md) | |
13-
**errors** | [**List<Problem>**](Problem.md) | | [optional]
9+
| Name | Type | Description | Notes |
10+
|------------ | ------------- | ------------- | -------------|
11+
|**data** | [**List<Rule>**](Rule.md) | All user-specified stream filtering rules that were created. | [optional] |
12+
|**errors** | [**List<Problem>**](Problem.md) | | [optional] |
13+
|**meta** | [**RulesResponseMetadata**](RulesResponseMetadata.md) | | |
1414

1515

1616

docs/AddRulesRequest.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@ A request to add a user-specified stream filtering rule.
66

77
## Properties
88

9-
Name | Type | Description | Notes
10-
------------ | ------------- | ------------- | -------------
11-
**add** | [**List<RuleNoId>**](RuleNoId.md) | |
9+
| Name | Type | Description | Notes |
10+
|------------ | ------------- | ------------- | -------------|
11+
|**add** | [**List<RuleNoId>**](RuleNoId.md) | | |
1212

1313

1414

docs/AnimatedGif.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55

66
## Properties
77

8-
Name | Type | Description | Notes
9-
------------ | ------------- | ------------- | -------------
10-
**previewImageUrl** | **URL** | | [optional]
11-
**variants** | [**List<VideoAllOfVariants>**](VideoAllOfVariants.md) | An array of all available variants of the media | [optional]
8+
| Name | Type | Description | Notes |
9+
|------------ | ------------- | ------------- | -------------|
10+
|**previewImageUrl** | **URL** | | [optional] |
11+
|**variants** | [**List<Variant>**](Variant.md) | An array of all available variants of the media. | [optional] |
1212

1313

1414

docs/AnimatedGifAllOf.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55

66
## Properties
77

8-
Name | Type | Description | Notes
9-
------------ | ------------- | ------------- | -------------
10-
**previewImageUrl** | **URL** | | [optional]
11-
**variants** | [**List<VideoAllOfVariants>**](VideoAllOfVariants.md) | An array of all available variants of the media | [optional]
8+
| Name | Type | Description | Notes |
9+
|------------ | ------------- | ------------- | -------------|
10+
|**previewImageUrl** | **URL** | | [optional] |
11+
|**variants** | [**List<Variant>**](Variant.md) | An array of all available variants of the media. | [optional] |
1212

1313

1414

docs/BlockUserMutationResponse.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
2+
3+
# BlockUserMutationResponse
4+
5+
6+
## Properties
7+
8+
| Name | Type | Description | Notes |
9+
|------------ | ------------- | ------------- | -------------|
10+
|**data** | [**BlockUserMutationResponseData**](BlockUserMutationResponseData.md) | | [optional] |
11+
|**errors** | [**List<Problem>**](Problem.md) | | [optional] |
12+
13+
14+

docs/BlockUserMutationResponseData.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
2+
3+
# BlockUserMutationResponseData
4+
5+
6+
## Properties
7+
8+
| Name | Type | Description | Notes |
9+
|------------ | ------------- | ------------- | -------------|
10+
|**blocking** | **Boolean** | | [optional] |
11+
12+
13+

docs/BlockUserRequest.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
2+
3+
# BlockUserRequest
4+
5+
6+
## Properties
7+
8+
| Name | Type | Description | Notes |
9+
|------------ | ------------- | ------------- | -------------|
10+
|**targetUserId** | **String** | Unique identifier of this User. This is returned as a string in order to avoid complications with languages and tools that cannot handle large integers. | |
11+
12+
13+

docs/BookmarkAddRequest.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
2+
3+
# BookmarkAddRequest
4+
5+
6+
## Properties
7+
8+
| Name | Type | Description | Notes |
9+
|------------ | ------------- | ------------- | -------------|
10+
|**tweetId** | **String** | Unique identifier of this Tweet. This is returned as a string in order to avoid complications with languages and tools that cannot handle large integers. | |
11+
12+
13+

docs/BookmarkMutationResponse.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55

66
## Properties
77

8-
Name | Type | Description | Notes
9-
------------ | ------------- | ------------- | -------------
10-
**data** | [**BookmarkMutationResponseData**](BookmarkMutationResponseData.md) | | [optional]
11-
**errors** | [**List<Problem>**](Problem.md) | | [optional]
8+
| Name | Type | Description | Notes |
9+
|------------ | ------------- | ------------- | -------------|
10+
|**data** | [**BookmarkMutationResponseData**](BookmarkMutationResponseData.md) | | [optional] |
11+
|**errors** | [**List<Problem>**](Problem.md) | | [optional] |
1212

1313

1414

docs/BookmarkMutationResponseData.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55

66
## Properties
77

8-
Name | Type | Description | Notes
9-
------------ | ------------- | ------------- | -------------
10-
**bookmarked** | **Boolean** | | [optional]
8+
| Name | Type | Description | Notes |
9+
|------------ | ------------- | ------------- | -------------|
10+
|**bookmarked** | **Boolean** | | [optional] |
1111

1212

1313

docs/BookmarksApi.md

Lines changed: 48 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@ All URIs are relative to *https://api.twitter.com*
1111

1212
<a name="getUsersIdBookmarks"></a>
1313
# **getUsersIdBookmarks**
14-
> GenericTweetsTimelineResponse getUsersIdBookmarks(id, maxResults, paginationToken, expansions, tweetFields, userFields, mediaFields, placeFields, pollFields)
14+
> Get2UsersIdBookmarksResponse getUsersIdBookmarks(id).maxResults(maxResults).paginationToken(paginationToken).tweetFields(tweetFields).expansions(expansions).mediaFields(mediaFields).pollFields(pollFields).userFields(userFields).placeFields(placeFields).execute();
1515
1616
Bookmarks by User
1717

18-
Returns Tweet objects that have been bookmarked by the requesting user
18+
Returns Tweet objects that have been bookmarked by the requesting User
1919

2020
### Example
2121
```java
@@ -38,7 +38,6 @@ import java.time.OffsetDateTime;
3838

3939
public class Example {
4040
public static void main(String[] args) {
41-
TwitterApi apiInstance = new TwitterApi();
4241
// Set the credentials based on the API's "security" tag values.
4342
// Check the API definition in https://api.twitter.com/2/openapi.json
4443
// When multiple options exist, the SDK supports only "OAuth2UserToken" or "BearerToken"
@@ -50,20 +49,29 @@ public class Example {
5049
// System.getenv("TWITTER_OAUTH2_CLIENT_SECRET"),
5150
// System.getenv("TWITTER_OAUTH2_ACCESS_TOKEN"),
5251
// System.getenv("TWITTER_OAUTH2_REFRESH_TOKEN"));
53-
// apiInstance.setTwitterCredentials(credentials);
52+
TwitterApi apiInstance = new TwitterApi(credentials);
5453

5554
// Set the params values
56-
String id = "id_example"; // String | The ID of the user for whom to return results
57-
Integer maxResults = 56; // Integer | The maximum number of results
55+
String id = "id_example"; // String | The ID of the authenticated source User for whom to return results.
56+
Integer maxResults = 56; // Integer | The maximum number of results.
5857
String paginationToken = "paginationToken_example"; // String | This parameter is used to get the next 'page' of results.
59-
Set<String> expansions = new HashSet<>(Arrays.asList()); // Set<String> | A comma separated list of fields to expand.
6058
Set<String> tweetFields = new HashSet<>(Arrays.asList()); // Set<String> | A comma separated list of Tweet fields to display.
61-
Set<String> userFields = new HashSet<>(Arrays.asList()); // Set<String> | A comma separated list of User fields to display.
59+
Set<String> expansions = new HashSet<>(Arrays.asList()); // Set<String> | A comma separated list of fields to expand.
6260
Set<String> mediaFields = new HashSet<>(Arrays.asList()); // Set<String> | A comma separated list of Media fields to display.
63-
Set<String> placeFields = new HashSet<>(Arrays.asList()); // Set<String> | A comma separated list of Place fields to display.
6461
Set<String> pollFields = new HashSet<>(Arrays.asList()); // Set<String> | A comma separated list of Poll fields to display.
62+
Set<String> userFields = new HashSet<>(Arrays.asList()); // Set<String> | A comma separated list of User fields to display.
63+
Set<String> placeFields = new HashSet<>(Arrays.asList()); // Set<String> | A comma separated list of Place fields to display.
6564
try {
66-
GenericTweetsTimelineResponse result = apiInstance.bookmarks().getUsersIdBookmarks(id, maxResults, paginationToken, expansions, tweetFields, userFields, mediaFields, placeFields, pollFields);
65+
Get2UsersIdBookmarksResponse result = apiInstance.bookmarks().getUsersIdBookmarks(id)
66+
.maxResults(maxResults)
67+
.paginationToken(paginationToken)
68+
.tweetFields(tweetFields)
69+
.expansions(expansions)
70+
.mediaFields(mediaFields)
71+
.pollFields(pollFields)
72+
.userFields(userFields)
73+
.placeFields(placeFields)
74+
.execute();
6775
System.out.println(result);
6876
} catch (ApiException e) {
6977
System.err.println("Exception when calling BookmarksApi#getUsersIdBookmarks");
@@ -80,19 +88,19 @@ public class Example {
8088

8189
| Name | Type | Description | Notes |
8290
|------------- | ------------- | ------------- | -------------|
83-
| **id** | **String**| The ID of the user for whom to return results | |
84-
| **maxResults** | **Integer**| The maximum number of results | [optional] |
91+
| **id** | **String**| The ID of the authenticated source User for whom to return results. | |
92+
| **maxResults** | **Integer**| The maximum number of results. | [optional] |
8593
| **paginationToken** | **String**| This parameter is used to get the next &#39;page&#39; of results. | [optional] |
86-
| **expansions** | [**Set&lt;String&gt;**](String.md)| A comma separated list of fields to expand. | [optional] [enum: author_id, referenced_tweets.id, in_reply_to_user_id, geo.place_id, attachments.media_keys, attachments.poll_ids, entities.mentions.username, referenced_tweets.id.author_id] |
87-
| **tweetFields** | [**Set&lt;String&gt;**](String.md)| A comma separated list of Tweet fields to display. | [optional] [enum: id, created_at, text, author_id, in_reply_to_user_id, referenced_tweets, attachments, withheld, geo, entities, public_metrics, possibly_sensitive, source, lang, context_annotations, non_public_metrics, promoted_metrics, organic_metrics, conversation_id, reply_settings] |
88-
| **userFields** | [**Set&lt;String&gt;**](String.md)| A comma separated list of User fields to display. | [optional] [enum: id, created_at, name, username, protected, verified, withheld, profile_image_url, location, url, description, entities, pinned_tweet_id, public_metrics] |
89-
| **mediaFields** | [**Set&lt;String&gt;**](String.md)| A comma separated list of Media fields to display. | [optional] [enum: media_key, duration_ms, height, preview_image_url, type, url, width, public_metrics, non_public_metrics, organic_metrics, promoted_metrics, alt_text, variants] |
90-
| **placeFields** | [**Set&lt;String&gt;**](String.md)| A comma separated list of Place fields to display. | [optional] [enum: id, name, country_code, place_type, full_name, country, contained_within, geo] |
91-
| **pollFields** | [**Set&lt;String&gt;**](String.md)| A comma separated list of Poll fields to display. | [optional] [enum: id, options, voting_status, end_datetime, duration_minutes] |
94+
| **tweetFields** | [**Set&lt;String&gt;**](String.md)| A comma separated list of Tweet fields to display. | [optional] [enum: attachments, author_id, context_annotations, conversation_id, created_at, entities, geo, id, in_reply_to_user_id, lang, non_public_metrics, organic_metrics, possibly_sensitive, promoted_metrics, public_metrics, referenced_tweets, reply_settings, source, text, withheld] |
95+
| **expansions** | [**Set&lt;String&gt;**](String.md)| A comma separated list of fields to expand. | [optional] [enum: attachments.media_keys, attachments.poll_ids, author_id, entities.mentions.username, geo.place_id, in_reply_to_user_id, referenced_tweets.id, referenced_tweets.id.author_id] |
96+
| **mediaFields** | [**Set&lt;String&gt;**](String.md)| A comma separated list of Media fields to display. | [optional] [enum: alt_text, duration_ms, height, media_key, non_public_metrics, organic_metrics, preview_image_url, promoted_metrics, public_metrics, type, url, variants, width] |
97+
| **pollFields** | [**Set&lt;String&gt;**](String.md)| A comma separated list of Poll fields to display. | [optional] [enum: duration_minutes, end_datetime, id, options, voting_status] |
98+
| **userFields** | [**Set&lt;String&gt;**](String.md)| A comma separated list of User fields to display. | [optional] [enum: created_at, description, entities, id, location, name, pinned_tweet_id, profile_image_url, protected, public_metrics, url, username, verified, withheld] |
99+
| **placeFields** | [**Set&lt;String&gt;**](String.md)| A comma separated list of Place fields to display. | [optional] [enum: contained_within, country, country_code, full_name, geo, id, name, place_type] |
92100

93101
### Return type
94102

95-
[**GenericTweetsTimelineResponse**](GenericTweetsTimelineResponse.md)
103+
[**Get2UsersIdBookmarksResponse**](Get2UsersIdBookmarksResponse.md)
96104

97105
### Authorization
98106

@@ -106,16 +114,16 @@ public class Example {
106114
### HTTP response details
107115
| Status code | Description | Response headers |
108116
|-------------|-------------|------------------|
109-
| **200** | The request was successful | - |
117+
| **200** | The request has succeeded. | - |
110118
| **0** | The request has failed. | - |
111119

112120
<a name="postUsersIdBookmarks"></a>
113121
# **postUsersIdBookmarks**
114-
> BookmarkMutationResponse postUsersIdBookmarks(addBookmarkRequest, id)
122+
> BookmarkMutationResponse postUsersIdBookmarks(bookmarkAddRequest, id).execute();
115123
116124
Add Tweet to Bookmarks
117125

118-
Adds a Tweet (ID in the body) to the requesting user&#39;s (in the path) bookmarks
126+
Adds a Tweet (ID in the body) to the requesting User&#39;s (in the path) bookmarks
119127

120128
### Example
121129
```java
@@ -138,7 +146,6 @@ import java.time.OffsetDateTime;
138146

139147
public class Example {
140148
public static void main(String[] args) {
141-
TwitterApi apiInstance = new TwitterApi();
142149
// Set the credentials based on the API's "security" tag values.
143150
// Check the API definition in https://api.twitter.com/2/openapi.json
144151
// When multiple options exist, the SDK supports only "OAuth2UserToken" or "BearerToken"
@@ -150,13 +157,14 @@ public class Example {
150157
// System.getenv("TWITTER_OAUTH2_CLIENT_SECRET"),
151158
// System.getenv("TWITTER_OAUTH2_ACCESS_TOKEN"),
152159
// System.getenv("TWITTER_OAUTH2_REFRESH_TOKEN"));
153-
// apiInstance.setTwitterCredentials(credentials);
160+
TwitterApi apiInstance = new TwitterApi(credentials);
154161

155162
// Set the params values
156-
AddBookmarkRequest addBookmarkRequest = new AddBookmarkRequest(); // AddBookmarkRequest |
157-
String id = "id_example"; // String | The ID of the user for whom to add bookmarks
163+
BookmarkAddRequest bookmarkAddRequest = new BookmarkAddRequest(); // BookmarkAddRequest |
164+
String id = "id_example"; // String | The ID of the authenticated source User for whom to add bookmarks.
158165
try {
159-
BookmarkMutationResponse result = apiInstance.bookmarks().postUsersIdBookmarks(addBookmarkRequest, id);
166+
BookmarkMutationResponse result = apiInstance.bookmarks().postUsersIdBookmarks(bookmarkAddRequest, id)
167+
.execute();
160168
System.out.println(result);
161169
} catch (ApiException e) {
162170
System.err.println("Exception when calling BookmarksApi#postUsersIdBookmarks");
@@ -173,8 +181,8 @@ public class Example {
173181

174182
| Name | Type | Description | Notes |
175183
|------------- | ------------- | ------------- | -------------|
176-
| **addBookmarkRequest** | [**AddBookmarkRequest**](AddBookmarkRequest.md)| | |
177-
| **id** | **String**| The ID of the user for whom to add bookmarks | |
184+
| **bookmarkAddRequest** | [**BookmarkAddRequest**](BookmarkAddRequest.md)| | |
185+
| **id** | **String**| The ID of the authenticated source User for whom to add bookmarks. | |
178186

179187
### Return type
180188

@@ -192,16 +200,16 @@ public class Example {
192200
### HTTP response details
193201
| Status code | Description | Response headers |
194202
|-------------|-------------|------------------|
195-
| **200** | The request was successful | - |
203+
| **200** | The request has succeeded. | - |
196204
| **0** | The request has failed. | - |
197205

198206
<a name="usersIdBookmarksDelete"></a>
199207
# **usersIdBookmarksDelete**
200-
> BookmarkMutationResponse usersIdBookmarksDelete(id, tweetId)
208+
> BookmarkMutationResponse usersIdBookmarksDelete(id, tweetId).execute();
201209
202210
Remove a bookmarked Tweet
203211

204-
Removes a Tweet from the requesting user&#39;s bookmarked Tweets.
212+
Removes a Tweet from the requesting User&#39;s bookmarked Tweets.
205213

206214
### Example
207215
```java
@@ -224,7 +232,6 @@ import java.time.OffsetDateTime;
224232

225233
public class Example {
226234
public static void main(String[] args) {
227-
TwitterApi apiInstance = new TwitterApi();
228235
// Set the credentials based on the API's "security" tag values.
229236
// Check the API definition in https://api.twitter.com/2/openapi.json
230237
// When multiple options exist, the SDK supports only "OAuth2UserToken" or "BearerToken"
@@ -236,13 +243,14 @@ public class Example {
236243
// System.getenv("TWITTER_OAUTH2_CLIENT_SECRET"),
237244
// System.getenv("TWITTER_OAUTH2_ACCESS_TOKEN"),
238245
// System.getenv("TWITTER_OAUTH2_REFRESH_TOKEN"));
239-
// apiInstance.setTwitterCredentials(credentials);
246+
TwitterApi apiInstance = new TwitterApi(credentials);
240247

241248
// Set the params values
242-
String id = "id_example"; // String | The ID of the user whose bookmark is to be removed.
243-
String tweetId = "tweetId_example"; // String | The ID of the tweet that the user is removing from bookmarks
249+
String id = "id_example"; // String | The ID of the authenticated source User whose bookmark is to be removed.
250+
String tweetId = "tweetId_example"; // String | The ID of the Tweet that the source User is removing from bookmarks.
244251
try {
245-
BookmarkMutationResponse result = apiInstance.bookmarks().usersIdBookmarksDelete(id, tweetId);
252+
BookmarkMutationResponse result = apiInstance.bookmarks().usersIdBookmarksDelete(id, tweetId)
253+
.execute();
246254
System.out.println(result);
247255
} catch (ApiException e) {
248256
System.err.println("Exception when calling BookmarksApi#usersIdBookmarksDelete");
@@ -259,8 +267,8 @@ public class Example {
259267

260268
| Name | Type | Description | Notes |
261269
|------------- | ------------- | ------------- | -------------|
262-
| **id** | **String**| The ID of the user whose bookmark is to be removed. | |
263-
| **tweetId** | **String**| The ID of the tweet that the user is removing from bookmarks | |
270+
| **id** | **String**| The ID of the authenticated source User whose bookmark is to be removed. | |
271+
| **tweetId** | **String**| The ID of the Tweet that the source User is removing from bookmarks. | |
264272

265273
### Return type
266274

@@ -278,6 +286,6 @@ public class Example {
278286
### HTTP response details
279287
| Status code | Description | Response headers |
280288
|-------------|-------------|------------------|
281-
| **200** | The request was successful | - |
289+
| **200** | The request has succeeded. | - |
282290
| **0** | The request has failed. | - |
283291

0 commit comments

Comments
 (0)