universal-mcp-applications 0.1.13__py3-none-any.whl → 0.1.14__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of universal-mcp-applications might be problematic. Click here for more details.

Files changed (54) hide show
  1. universal_mcp/applications/aws_s3/app.py +71 -71
  2. universal_mcp/applications/calendly/app.py +199 -199
  3. universal_mcp/applications/canva/app.py +189 -189
  4. universal_mcp/applications/domain_checker/app.py +31 -24
  5. universal_mcp/applications/e2b/app.py +6 -7
  6. universal_mcp/applications/elevenlabs/app.py +24 -20
  7. universal_mcp/applications/exa/app.py +25 -20
  8. universal_mcp/applications/falai/app.py +44 -41
  9. universal_mcp/applications/file_system/app.py +20 -12
  10. universal_mcp/applications/firecrawl/app.py +46 -47
  11. universal_mcp/applications/fireflies/app.py +79 -79
  12. universal_mcp/applications/fpl/app.py +83 -74
  13. universal_mcp/applications/github/README.md +0 -1028
  14. universal_mcp/applications/github/app.py +55 -50227
  15. universal_mcp/applications/google_calendar/app.py +63 -65
  16. universal_mcp/applications/google_docs/app.py +78 -78
  17. universal_mcp/applications/google_drive/app.py +361 -440
  18. universal_mcp/applications/google_gemini/app.py +34 -17
  19. universal_mcp/applications/google_mail/app.py +117 -117
  20. universal_mcp/applications/google_searchconsole/app.py +41 -47
  21. universal_mcp/applications/google_sheet/app.py +157 -164
  22. universal_mcp/applications/http_tools/app.py +16 -16
  23. universal_mcp/applications/linkedin/app.py +26 -31
  24. universal_mcp/applications/ms_teams/app.py +190 -190
  25. universal_mcp/applications/openai/app.py +55 -56
  26. universal_mcp/applications/outlook/app.py +57 -57
  27. universal_mcp/applications/perplexity/app.py +17 -17
  28. universal_mcp/applications/reddit/app.py +225 -4053
  29. universal_mcp/applications/replicate/app.py +40 -42
  30. universal_mcp/applications/resend/app.py +157 -154
  31. universal_mcp/applications/scraper/app.py +24 -24
  32. universal_mcp/applications/serpapi/app.py +18 -20
  33. universal_mcp/applications/sharepoint/app.py +46 -36
  34. universal_mcp/applications/slack/app.py +66 -66
  35. universal_mcp/applications/tavily/app.py +7 -7
  36. universal_mcp/applications/twitter/api_segments/compliance_api.py +17 -20
  37. universal_mcp/applications/twitter/api_segments/dm_conversations_api.py +35 -40
  38. universal_mcp/applications/twitter/api_segments/dm_events_api.py +18 -21
  39. universal_mcp/applications/twitter/api_segments/likes_api.py +19 -22
  40. universal_mcp/applications/twitter/api_segments/lists_api.py +59 -68
  41. universal_mcp/applications/twitter/api_segments/spaces_api.py +36 -42
  42. universal_mcp/applications/twitter/api_segments/trends_api.py +7 -8
  43. universal_mcp/applications/twitter/api_segments/tweets_api.py +159 -185
  44. universal_mcp/applications/twitter/api_segments/usage_api.py +5 -6
  45. universal_mcp/applications/twitter/api_segments/users_api.py +230 -264
  46. universal_mcp/applications/unipile/app.py +99 -105
  47. universal_mcp/applications/whatsapp/app.py +86 -82
  48. universal_mcp/applications/whatsapp_business/app.py +147 -147
  49. universal_mcp/applications/youtube/app.py +290 -290
  50. universal_mcp/applications/zenquotes/app.py +6 -6
  51. {universal_mcp_applications-0.1.13.dist-info → universal_mcp_applications-0.1.14.dist-info}/METADATA +1 -1
  52. {universal_mcp_applications-0.1.13.dist-info → universal_mcp_applications-0.1.14.dist-info}/RECORD +54 -54
  53. {universal_mcp_applications-0.1.13.dist-info → universal_mcp_applications-0.1.14.dist-info}/WHEEL +0 -0
  54. {universal_mcp_applications-0.1.13.dist-info → universal_mcp_applications-0.1.14.dist-info}/licenses/LICENSE +0 -0
@@ -18,9 +18,8 @@ class TweetsApi(APISegmentBase):
18
18
  place_fields=None,
19
19
  ) -> dict[str, Any]:
20
20
  """
21
-
22
- Retrieves one or more Tweets by their IDs and returns associated details, supporting optional parameters for specifying additional fields and expansions.
23
-
21
+ Fetches detailed information for multiple tweets, specified by a list of their IDs. Optional parameters allow response customization by including specific fields (e.g., media, user, polls) and expansions. This function handles batch lookups, distinguishing it from `find_tweet_by_id` which retrieves a single tweet.
22
+
24
23
  Args:
25
24
  ids (array): An array of IDs for the tweets to retrieve, required for the operation.
26
25
  tweet_fields (array): A comma separated list of Tweet fields to display. Example: "['article', 'attachments', 'author_id', 'card_uri', 'context_annotations', 'conversation_id', 'created_at', 'edit_controls', 'edit_history_tweet_ids', 'entities', 'geo', 'id', 'in_reply_to_user_id', 'lang', 'non_public_metrics', 'note_tweet', 'organic_metrics', 'possibly_sensitive', 'promoted_metrics', 'public_metrics', 'referenced_tweets', 'reply_settings', 'scopes', 'source', 'text', 'username', 'withheld']".
@@ -29,14 +28,14 @@ class TweetsApi(APISegmentBase):
29
28
  poll_fields (array): A comma separated list of Poll fields to display. Example: "['duration_minutes', 'end_datetime', 'id', 'options', 'voting_status']".
30
29
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
31
30
  place_fields (array): A comma separated list of Place fields to display. Example: "['contained_within', 'country', 'country_code', 'full_name', 'geo', 'id', 'name', 'place_type']".
32
-
31
+
33
32
  Returns:
34
33
  dict[str, Any]: The request has succeeded.
35
-
34
+
36
35
  Raises:
37
36
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
38
37
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
39
-
38
+
40
39
  Tags:
41
40
  Tweets
42
41
  """
@@ -73,9 +72,8 @@ class TweetsApi(APISegmentBase):
73
72
  text=None,
74
73
  ) -> dict[str, Any]:
75
74
  """
76
-
77
- Creates a new tweet using the Twitter API v2, requiring an application/json payload and OAuth2 user token for authentication, and returns a 201 status upon successful creation.
78
-
75
+ Posts a new tweet for an authenticated user, supporting optional parameters like text, media, polls, replies, and quote tweets. This function constructs a POST request to the `/2/tweets` endpoint, enabling the creation of diverse tweet formats with specific visibility and reply settings.
76
+
79
77
  Args:
80
78
  card_uri (string): Card Uri Parameter. This is mutually exclusive from Quote Tweet Id, Poll, Media, and Direct Message Deep Link.
81
79
  direct_message_deep_link (string): Link to take the conversation from the public timeline to a private Direct Message.
@@ -87,15 +85,15 @@ class TweetsApi(APISegmentBase):
87
85
  quote_tweet_id (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. Example: '1346889436626259968'.
88
86
  reply (object): Tweet information of the Tweet being replied to.
89
87
  reply_settings (string): Settings to indicate who can reply to the Tweet.
90
- text (string): The content of the Tweet. Example: 'Learn how to use the user Tweet timeline and user mention timeline endpoints in the X API v2 to explore Tweet\\u2026 https:\\/\\/t.co\\/56a0vZUx7i'.
91
-
88
+ text (string): The content of the Tweet. Example: 'Learn how to use the user Tweet timeline and user mention timeline endpoints in the X API v2 to explore Tweet\u2026 https:\/\/t.co\/56a0vZUx7i'.
89
+
92
90
  Returns:
93
91
  dict[str, Any]: The request has succeeded.
94
-
92
+
95
93
  Raises:
96
94
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
97
95
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
98
-
96
+
99
97
  Tags:
100
98
  Tweets
101
99
  """
@@ -131,22 +129,21 @@ class TweetsApi(APISegmentBase):
131
129
  self, partition, backfill_minutes=None, start_time=None, end_time=None
132
130
  ) -> Any:
133
131
  """
134
-
135
- Streams compliance events for tweets in real-time, allowing for the retrieval of events such as post deletions, edits, and withholdings, as well as user account changes, using parameters like partition, backfill_minutes, start_time, and end_time.
136
-
132
+ Streams real-time compliance events for tweets, such as deletions and user updates, from a specified partition. Unlike other stream functions that return tweet content, this provides metadata about content and user status changes, supporting optional time-based filtering and backfilling.
133
+
137
134
  Args:
138
135
  partition (integer): Specifies the partition number from which to retrieve compliance stream events, with a required integer value between 1 and 4.
139
136
  backfill_minutes (integer): Optional integer parameter to specify the number of minutes of data to recover from a stream disconnection, allowing retrieval of missed tweets.
140
137
  start_time (string): Optional string parameter specifying the earliest UTC timestamp from which compliance events will be provided, formatted as YYYY-MM-DDTHH:mm:ssZ. Example: '2021-02-01T18:40:40.000Z'.
141
138
  end_time (string): The `end_time` parameter specifies the latest UTC timestamp (in ISO 8601 format) until which compliance events will be streamed. Example: '2021-02-14T18:40:40.000Z'.
142
-
139
+
143
140
  Returns:
144
141
  Any: The request has succeeded.
145
-
142
+
146
143
  Raises:
147
144
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
148
145
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
149
-
146
+
150
147
  Tags:
151
148
  Compliance
152
149
  """
@@ -178,9 +175,8 @@ class TweetsApi(APISegmentBase):
178
175
  search_count_fields=None,
179
176
  ) -> dict[str, Any]:
180
177
  """
181
-
182
- Retrieves the full-archive count of tweets for a specified query using the "/2/tweets/counts/all" endpoint, allowing optional filtering by start and end times, granularity, and pagination.
183
-
178
+ Calculates the number of tweets from the entire historical archive that match a given search query. Results can be aggregated by minute, hour, or day over a specific time range to analyze historical tweet volume trends.
179
+
184
180
  Args:
185
181
  query (string): The "query" parameter is a required string used to filter tweets by specifying keywords or phrases, allowing users to retrieve counts for specific topics or hashtags. Example: '(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet'.
186
182
  start_time (string): The start_time parameter sets the earliest timestamp from which to begin counting Tweets in the full-archive matching the query, formatted as an ISO 8601 string.
@@ -191,14 +187,14 @@ class TweetsApi(APISegmentBase):
191
187
  pagination_token (string): Used to request the next page of results, providing the value of `next_token` from the previous response to paginate through data.
192
188
  granularity (string): The **granularity** parameter specifies the time unit for retrieving tweet counts, allowing options of "minute", "hour", or "day", with "hour" as the default.
193
189
  search_count_fields (array): A comma separated list of SearchCount fields to display. Example: "['end', 'start', 'tweet_count']".
194
-
190
+
195
191
  Returns:
196
192
  dict[str, Any]: The request has succeeded.
197
-
193
+
198
194
  Raises:
199
195
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
200
196
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
201
-
197
+
202
198
  Tags:
203
199
  Tweets
204
200
  """
@@ -235,9 +231,8 @@ class TweetsApi(APISegmentBase):
235
231
  search_count_fields=None,
236
232
  ) -> dict[str, Any]:
237
233
  """
238
-
239
- Retrieves the count of recent Tweets that match a search query over the last seven days, using the "GET" method with optional parameters for specifying start and end times, granularity, and pagination.
240
-
234
+ Retrieves the total count of tweets from the last seven days matching a specified query. Results can be aggregated by minute, hour, or day and filtered by time range or tweet ID. This function contrasts with `tweet_counts_full_archive_search`, which queries the entire tweet history.
235
+
241
236
  Args:
242
237
  query (string): The search query to filter recent tweets for counting matching tweets. Example: '(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet'.
243
238
  start_time (string): Optional start time for the recent Tweet counts query, specified in ISO 8601 format, which determines the beginning of the time window for which Tweet counts are returned.
@@ -248,14 +243,14 @@ class TweetsApi(APISegmentBase):
248
243
  pagination_token (string): Optional parameter to paginate through the results, used by passing the `next_token` value from the previous response to retrieve the next page of tweet count data.
249
244
  granularity (string): The granularity parameter specifies the time interval for aggregating Tweet counts in the response, with possible values of "minute," "hour" (default), or "day".
250
245
  search_count_fields (array): A comma separated list of SearchCount fields to display. Example: "['end', 'start', 'tweet_count']".
251
-
246
+
252
247
  Returns:
253
248
  dict[str, Any]: The request has succeeded.
254
-
249
+
255
250
  Raises:
256
251
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
257
252
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
258
-
253
+
259
254
  Tags:
260
255
  Tweets
261
256
  """
@@ -293,9 +288,8 @@ class TweetsApi(APISegmentBase):
293
288
  place_fields=None,
294
289
  ) -> dict[str, Any]:
295
290
  """
296
-
297
- Streams all tweets in real-time using the Firehose API, allowing parameters such as partition, backfill minutes, start and end time, and various field expansions to customize the data retrieved, which requires authentication via a Bearer Token.
298
-
291
+ Streams all public tweets in real-time from the Firehose API for a specified partition. This unfiltered feed can be customized with optional parameters to backfill data, define a time window, and specify desired tweet, user, and media fields.
292
+
299
293
  Args:
300
294
  partition (integer): A required integer parameter that specifies the partition from which to retrieve the firehose stream data.
301
295
  backfill_minutes (integer): The backfill_minutes parameter allows requesting up to five minutes of missed streaming data to be delivered upon reconnection, helping recover Tweets lost during short disconnections; it accepts an integer value from 1 to 5 and is available only with Academic Research access.
@@ -307,14 +301,14 @@ class TweetsApi(APISegmentBase):
307
301
  poll_fields (array): A comma separated list of Poll fields to display. Example: "['duration_minutes', 'end_datetime', 'id', 'options', 'voting_status']".
308
302
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
309
303
  place_fields (array): A comma separated list of Place fields to display. Example: "['contained_within', 'country', 'country_code', 'full_name', 'geo', 'id', 'name', 'place_type']".
310
-
304
+
311
305
  Returns:
312
306
  dict[str, Any]: The request has succeeded.
313
-
307
+
314
308
  Raises:
315
309
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
316
310
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
317
-
311
+
318
312
  Tags:
319
313
  Tweets
320
314
  """
@@ -339,7 +333,7 @@ class TweetsApi(APISegmentBase):
339
333
  response.raise_for_status()
340
334
  return response.json()
341
335
 
342
- def get_tweets_firehose_stream_lang_en(
336
+ def stream_english_tweets_firehose(
343
337
  self,
344
338
  partition,
345
339
  backfill_minutes=None,
@@ -353,9 +347,8 @@ class TweetsApi(APISegmentBase):
353
347
  place_fields=None,
354
348
  ) -> dict[str, Any]:
355
349
  """
356
-
357
- Connects to the Twitter Firehose streaming API to receive a real-time stream of English-language tweets with optional filtering and data field expansions.
358
-
350
+ Streams real-time public tweets from the Firehose API, specifically filtered for the English language. Requires a partition number and supports optional parameters to customize the data payload. It is distinct from other language-specific (`_ja`, `_ko`, `_pt`) or the unfiltered `get_tweets_firehose_stream` functions.
351
+
359
352
  Args:
360
353
  partition (integer): The `partition` parameter is an integer value required in the query for the GET operation at path "/2/tweets/firehose/stream/lang/en", specifying the partition number for the stream.
361
354
  backfill_minutes (integer): Requests up to five minutes of missed streaming data to be delivered upon reconnection, useful for recovering data lost during brief disconnections.
@@ -367,14 +360,14 @@ class TweetsApi(APISegmentBase):
367
360
  poll_fields (array): A comma separated list of Poll fields to display. Example: "['duration_minutes', 'end_datetime', 'id', 'options', 'voting_status']".
368
361
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
369
362
  place_fields (array): A comma separated list of Place fields to display. Example: "['contained_within', 'country', 'country_code', 'full_name', 'geo', 'id', 'name', 'place_type']".
370
-
363
+
371
364
  Returns:
372
365
  dict[str, Any]: The request has succeeded.
373
-
366
+
374
367
  Raises:
375
368
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
376
369
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
377
-
370
+
378
371
  Tags:
379
372
  Tweets
380
373
  """
@@ -413,9 +406,8 @@ class TweetsApi(APISegmentBase):
413
406
  place_fields=None,
414
407
  ) -> dict[str, Any]:
415
408
  """
416
-
417
- Retrieves a stream of Tweets in Japanese using the Firehose API, allowing for real-time access to a high-volume stream of Tweets based on specified parameters such as partitions and optional backfill minutes, start and end times, and customizable fields for Tweets, users, and media.
418
-
409
+ Streams real-time tweets specifically in Japanese from the Twitter Firehose API, requiring a partition number. It supports optional parameters for time ranges, backfill, and customizable fields. This method is distinct from other `get_tweets_firehose_stream` variants, which target different languages or the entire stream.
410
+
419
411
  Args:
420
412
  partition (integer): The partition number used to identify and organize the data stream, which is required for this operation.
421
413
  backfill_minutes (integer): The number of minutes (1 to 5) of missed streaming data to backfill and recover upon reconnection, available only with Academic Research access.
@@ -427,14 +419,14 @@ class TweetsApi(APISegmentBase):
427
419
  poll_fields (array): A comma separated list of Poll fields to display. Example: "['duration_minutes', 'end_datetime', 'id', 'options', 'voting_status']".
428
420
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
429
421
  place_fields (array): A comma separated list of Place fields to display. Example: "['contained_within', 'country', 'country_code', 'full_name', 'geo', 'id', 'name', 'place_type']".
430
-
422
+
431
423
  Returns:
432
424
  dict[str, Any]: The request has succeeded.
433
-
425
+
434
426
  Raises:
435
427
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
436
428
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
437
-
429
+
438
430
  Tags:
439
431
  Tweets
440
432
  """
@@ -459,7 +451,7 @@ class TweetsApi(APISegmentBase):
459
451
  response.raise_for_status()
460
452
  return response.json()
461
453
 
462
- def get_tweets_firehose_stream_lang_ko(
454
+ def stream_korean_firehose_tweets(
463
455
  self,
464
456
  partition,
465
457
  backfill_minutes=None,
@@ -473,9 +465,8 @@ class TweetsApi(APISegmentBase):
473
465
  place_fields=None,
474
466
  ) -> dict[str, Any]:
475
467
  """
476
-
477
- Streams real-time tweets in Korean from the Twitter firehose, allowing for optional backfill, specific partitions, and customizable start and end times, with support for various tweet, media, poll, user, and place fields.
478
-
468
+ Streams real-time tweets filtered for the Korean language from the Firehose API. This function allows customization via parameters for partitions, time range, backfill, and specific data fields for tweets, users, and media, distinguishing it from other language-specific stream functions.
469
+
479
470
  Args:
480
471
  partition (integer): The partition parameter specifies the integer partition number to use for streaming tweets.
481
472
  backfill_minutes (integer): The number of minutes (1 to 5) of previously missed Tweets to backfill and deliver upon reconnection, allowing recovery of up to five minutes of data missed during a disconnection; duplicates may occur and this feature requires Academic Research access.
@@ -487,14 +478,14 @@ class TweetsApi(APISegmentBase):
487
478
  poll_fields (array): A comma separated list of Poll fields to display. Example: "['duration_minutes', 'end_datetime', 'id', 'options', 'voting_status']".
488
479
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
489
480
  place_fields (array): A comma separated list of Place fields to display. Example: "['contained_within', 'country', 'country_code', 'full_name', 'geo', 'id', 'name', 'place_type']".
490
-
481
+
491
482
  Returns:
492
483
  dict[str, Any]: The request has succeeded.
493
-
484
+
494
485
  Raises:
495
486
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
496
487
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
497
-
488
+
498
489
  Tags:
499
490
  Tweets
500
491
  """
@@ -533,9 +524,8 @@ class TweetsApi(APISegmentBase):
533
524
  place_fields=None,
534
525
  ) -> dict[str, Any]:
535
526
  """
536
-
537
- Streams real-time Tweets in Portuguese using the Firehose API, allowing for filtering by specific parameters such as tweet fields, expansions, media, polls, users, and places, and requires a partition number for the stream.
538
-
527
+ Streams real-time tweets in Portuguese from the Firehose API, requiring a partition number. It allows data customization via optional parameters for time ranges and fields, specifically targeting the Portuguese language stream, unlike other general or language-specific firehose functions.
528
+
539
529
  Args:
540
530
  partition (integer): The **partition** parameter is a required integer that specifies the partition number for the GET operation at the "/2/tweets/firehose/stream/lang/pt" path, used to distribute the stream of tweets across multiple partitions for efficient processing.
541
531
  backfill_minutes (integer): The number of minutes (1-5) of missed streaming data to recover and deliver upon reconnection, available only for Academic Research access.
@@ -547,14 +537,14 @@ class TweetsApi(APISegmentBase):
547
537
  poll_fields (array): A comma separated list of Poll fields to display. Example: "['duration_minutes', 'end_datetime', 'id', 'options', 'voting_status']".
548
538
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
549
539
  place_fields (array): A comma separated list of Place fields to display. Example: "['contained_within', 'country', 'country_code', 'full_name', 'geo', 'id', 'name', 'place_type']".
550
-
540
+
551
541
  Returns:
552
542
  dict[str, Any]: The request has succeeded.
553
-
543
+
554
544
  Raises:
555
545
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
556
546
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
557
-
547
+
558
548
  Tags:
559
549
  Tweets
560
550
  """
@@ -579,25 +569,24 @@ class TweetsApi(APISegmentBase):
579
569
  response.raise_for_status()
580
570
  return response.json()
581
571
 
582
- def get_tweets_label_stream(
572
+ def stream_labeled_tweets(
583
573
  self, backfill_minutes=None, start_time=None, end_time=None
584
574
  ) -> Any:
585
575
  """
586
-
587
- Streams tweets labeled with a specific identifier in real-time using the Twitter API, allowing for optional parameters to specify backfill minutes, start time, and end time, and requires authentication via a Bearer Token.
588
-
576
+ Streams real-time Tweet objects labeled for compliance reasons, such as withheld content. Unlike `get_tweets_compliance_stream`, which provides events, this returns the actual tweets. Supports filtering by a time window and backfilling missed data upon reconnection.
577
+
589
578
  Args:
590
579
  backfill_minutes (integer): The number of minutes (up to five) of missed tweet data to recover and backfill after a disconnection, available for Academic Research access.
591
580
  start_time (string): Optional parameter specifying the earliest UTC timestamp (in ISO 8601/RFC 3339 format) from which to retrieve tweets, allowing filtering by creation time. Example: '2021-02-01T18:40:40.000Z'.
592
581
  end_time (string): Optional parameter specifying the end time in ISO 8601 format for retrieving tweets from a label stream, used to filter tweets created before this time. Example: '2021-02-01T18:40:40.000Z'.
593
-
582
+
594
583
  Returns:
595
584
  Any: The request has succeeded.
596
-
585
+
597
586
  Raises:
598
587
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
599
588
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
600
-
589
+
601
590
  Tags:
602
591
  Compliance
603
592
  """
@@ -626,9 +615,8 @@ class TweetsApi(APISegmentBase):
626
615
  place_fields=None,
627
616
  ) -> dict[str, Any]:
628
617
  """
629
-
630
- Retrieves a real-time sampled stream of public Tweets with optional parameters to specify Tweet, user, media, poll, and place fields, supporting backfill for missed data.
631
-
618
+ Streams a real-time, random sample of public tweets from the API. It allows data customization through optional field and expansion parameters. This function targets the standard (~1%) sample stream, distinct from `get_tweets_sample_stream` which accesses the partitioned 10% stream.
619
+
632
620
  Args:
633
621
  backfill_minutes (integer): The number of minutes (1 to 5) of missed streaming Tweets to backfill and receive upon reconnection, available for Academic Research access.
634
622
  tweet_fields (array): A comma separated list of Tweet fields to display. Example: "['article', 'attachments', 'author_id', 'card_uri', 'context_annotations', 'conversation_id', 'created_at', 'edit_controls', 'edit_history_tweet_ids', 'entities', 'geo', 'id', 'in_reply_to_user_id', 'lang', 'non_public_metrics', 'note_tweet', 'organic_metrics', 'possibly_sensitive', 'promoted_metrics', 'public_metrics', 'referenced_tweets', 'reply_settings', 'scopes', 'source', 'text', 'username', 'withheld']".
@@ -637,14 +625,14 @@ class TweetsApi(APISegmentBase):
637
625
  poll_fields (array): A comma separated list of Poll fields to display. Example: "['duration_minutes', 'end_datetime', 'id', 'options', 'voting_status']".
638
626
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
639
627
  place_fields (array): A comma separated list of Place fields to display. Example: "['contained_within', 'country', 'country_code', 'full_name', 'geo', 'id', 'name', 'place_type']".
640
-
628
+
641
629
  Returns:
642
630
  dict[str, Any]: The request has succeeded.
643
-
631
+
644
632
  Raises:
645
633
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
646
634
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
647
-
635
+
648
636
  Tags:
649
637
  Tweets
650
638
  """
@@ -666,7 +654,7 @@ class TweetsApi(APISegmentBase):
666
654
  response.raise_for_status()
667
655
  return response.json()
668
656
 
669
- def get_tweets_sample_stream(
657
+ def get_tweets_sample10_stream(
670
658
  self,
671
659
  partition,
672
660
  backfill_minutes=None,
@@ -680,9 +668,8 @@ class TweetsApi(APISegmentBase):
680
668
  place_fields=None,
681
669
  ) -> dict[str, Any]:
682
670
  """
683
-
684
- Streams a random sample of 10% of all Tweets in real-time, allowing optional filtering by specifying additional parameters such as backfill minutes, partition, start and end times, and various field expansions for tweets, media, polls, users, and places.
685
-
671
+ Streams a 10% random sample of real-time tweets from a specified partition, offering a larger volume than `sample_stream`. It supports optional time-based filtering and customization of returned data for tweets, media, users, and places using field selectors and expansions.
672
+
686
673
  Args:
687
674
  partition (integer): The "partition" parameter specifies the partition number for the stream, which is required for the GET operation at path "/2/tweets/sample10/stream".
688
675
  backfill_minutes (integer): The `backfill_minutes` parameter allows you to request up to five minutes of missed streaming data to be delivered upon reconnection, helping recover data lost during disconnections; it is only available for Academic Research access.
@@ -694,14 +681,14 @@ class TweetsApi(APISegmentBase):
694
681
  poll_fields (array): A comma separated list of Poll fields to display. Example: "['duration_minutes', 'end_datetime', 'id', 'options', 'voting_status']".
695
682
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
696
683
  place_fields (array): A comma separated list of Place fields to display. Example: "['contained_within', 'country', 'country_code', 'full_name', 'geo', 'id', 'name', 'place_type']".
697
-
684
+
698
685
  Returns:
699
686
  dict[str, Any]: The request has succeeded.
700
-
687
+
701
688
  Raises:
702
689
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
703
690
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
704
-
691
+
705
692
  Tags:
706
693
  Tweets
707
694
  """
@@ -745,9 +732,8 @@ class TweetsApi(APISegmentBase):
745
732
  place_fields=None,
746
733
  ) -> dict[str, Any]:
747
734
  """
748
-
749
- Retrieves and returns a list of historical Tweets matching a specified query, allowing for filtering by time range, tweet ID, and other parameters.
750
-
735
+ Searches the entire historical archive of public Tweets using a specific query. It supports filtering by time range and pagination, allowing customization of returned fields. This differs from `tweets_recent_search`, which only covers the last seven days, and `tweet_counts_full_archive_search`, which returns counts instead of tweet data.
736
+
751
737
  Args:
752
738
  query (string): The "query" parameter is a required string input used to specify the search criteria for retrieving tweets. Example: '(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet'.
753
739
  start_time (string): Optional timestamp specifying the earliest date and time from which to retrieve Tweets, formatted as YYYY-MM-DDTHH:mm:ssZ in ISO 8601/RFC 3339 format; if not specified and end_time is provided, it defaults to 30 days before end_time.
@@ -764,14 +750,14 @@ class TweetsApi(APISegmentBase):
764
750
  poll_fields (array): A comma separated list of Poll fields to display. Example: "['duration_minutes', 'end_datetime', 'id', 'options', 'voting_status']".
765
751
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
766
752
  place_fields (array): A comma separated list of Place fields to display. Example: "['contained_within', 'country', 'country_code', 'full_name', 'geo', 'id', 'name', 'place_type']".
767
-
753
+
768
754
  Returns:
769
755
  dict[str, Any]: The request has succeeded.
770
-
756
+
771
757
  Raises:
772
758
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
773
759
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
774
-
760
+
775
761
  Tags:
776
762
  Tweets
777
763
  """
@@ -820,9 +806,8 @@ class TweetsApi(APISegmentBase):
820
806
  place_fields=None,
821
807
  ) -> dict[str, Any]:
822
808
  """
823
-
824
- Retrieves recent tweets based on a specified search query, allowing for optional filtering by time range and additional parameters such as tweet fields, expansions, and user details.
825
-
809
+ Searches for tweets from the past seven days matching a specific query. Allows advanced filtering, pagination, and data expansions to customize results. Unlike `tweet_counts_recent_search`, it returns full tweet objects instead of just a count.
810
+
826
811
  Args:
827
812
  query (string): A string parameter used to specify the search query for retrieving recent tweets. Example: '(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet'.
828
813
  start_time (string): Optional parameter to specify the earliest time to search for tweets, formatted as ISO8601/RFC3339 (e.g., 2023-05-12T00:00:00Z).
@@ -839,14 +824,14 @@ class TweetsApi(APISegmentBase):
839
824
  poll_fields (array): A comma separated list of Poll fields to display. Example: "['duration_minutes', 'end_datetime', 'id', 'options', 'voting_status']".
840
825
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
841
826
  place_fields (array): A comma separated list of Place fields to display. Example: "['contained_within', 'country', 'country_code', 'full_name', 'geo', 'id', 'name', 'place_type']".
842
-
827
+
843
828
  Returns:
844
829
  dict[str, Any]: The request has succeeded.
845
-
830
+
846
831
  Raises:
847
832
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
848
833
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
849
-
834
+
850
835
  Tags:
851
836
  Tweets
852
837
  """
@@ -876,7 +861,7 @@ class TweetsApi(APISegmentBase):
876
861
  response.raise_for_status()
877
862
  return response.json()
878
863
 
879
- def search_stream(
864
+ def get_filtered_stream(
880
865
  self,
881
866
  backfill_minutes=None,
882
867
  start_time=None,
@@ -889,9 +874,8 @@ class TweetsApi(APISegmentBase):
889
874
  place_fields=None,
890
875
  ) -> dict[str, Any]:
891
876
  """
892
-
893
- Streams tweets based on predefined rules using the Twitter API v2, allowing for real-time filtering and retrieval of tweets with optional parameters for backfill minutes, start and end times, and various tweet, media, poll, user, and place fields.
894
-
877
+ Streams real-time tweets matching a user's pre-configured filtering rules from the Twitter API. Unlike `sample_stream` or `get_tweets_firehose_stream`, this provides a targeted feed. Optional parameters can customize returned data fields and specify a time window.
878
+
895
879
  Args:
896
880
  backfill_minutes (integer): The "backfill_minutes" parameter allows clients to request up to five minutes of missed data upon reconnection, helping to recover Tweets that were missed due to a disconnection.
897
881
  start_time (string): The "start_time" parameter specifies the earliest UTC timestamp (in ISO 8601 format) from which to include Tweets in the search results. Example: '2021-02-01T18:40:40.000Z'.
@@ -902,14 +886,14 @@ class TweetsApi(APISegmentBase):
902
886
  poll_fields (array): A comma separated list of Poll fields to display. Example: "['duration_minutes', 'end_datetime', 'id', 'options', 'voting_status']".
903
887
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
904
888
  place_fields (array): A comma separated list of Place fields to display. Example: "['contained_within', 'country', 'country_code', 'full_name', 'geo', 'id', 'name', 'place_type']".
905
-
889
+
906
890
  Returns:
907
891
  dict[str, Any]: The request has succeeded.
908
-
892
+
909
893
  Raises:
910
894
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
911
895
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
912
-
896
+
913
897
  Tags:
914
898
  Tweets
915
899
  """
@@ -933,25 +917,24 @@ class TweetsApi(APISegmentBase):
933
917
  response.raise_for_status()
934
918
  return response.json()
935
919
 
936
- def get_rules(
920
+ def get_filtered_stream_rules(
937
921
  self, ids=None, max_results=None, pagination_token=None
938
922
  ) -> dict[str, Any]:
939
923
  """
940
-
941
- Retrieves the active stream filtering rules for a user's Twitter API v2 filtered stream, optionally filtered by rule IDs, with support for pagination and maximum results.
942
-
924
+ Retrieves the active filtering rules for a Twitter API v2 filtered stream. It can fetch all rules or a subset specified by rule IDs, with support for pagination to manage large rule sets, complementing the `add_or_delete_rules` and `search_stream` functions.
925
+
943
926
  Args:
944
927
  ids (array): Optional array of rule IDs to fetch a subset of rules from the user's active rule set.
945
928
  max_results (integer): The maximum number of stream filtering rules to return per response, up to 1000; defaults to 1000 if not specified.
946
929
  pagination_token (string): The `pagination_token` parameter is a string used to request the next page of results in a paginated response, typically obtained from the `next_token` value in the previous response.
947
-
930
+
948
931
  Returns:
949
932
  dict[str, Any]: The request has succeeded.
950
-
933
+
951
934
  Raises:
952
935
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
953
936
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
954
-
937
+
955
938
  Tags:
956
939
  Tweets
957
940
  """
@@ -969,26 +952,25 @@ class TweetsApi(APISegmentBase):
969
952
  response.raise_for_status()
970
953
  return response.json()
971
954
 
972
- def add_or_delete_rules(
955
+ def update_stream_rules(
973
956
  self, dry_run=None, delete_all=None, add=None, delete=None
974
957
  ) -> dict[str, Any]:
975
958
  """
976
-
977
- Adds or removes rules from a Twitter API v2 filtered stream using a POST request, allowing for optional dry-run or delete-all parameters.
978
-
959
+ Adds or removes filtering rules for a tweet stream. Supports a dry-run mode to validate rule syntax without application and an option to delete all existing rules. This function directly modifies the active rule set used by the `search_stream` function.
960
+
979
961
  Args:
980
962
  dry_run (boolean): Indicates whether to test the syntax of the rule without applying it to the stream, allowing validation of rule changes without taking effect.
981
963
  delete_all (boolean): Indicates whether to delete all existing rules for the user before applying new rules; if true, all existing rules will be deleted.
982
964
  add (array): add
983
965
  delete (object): IDs and values of all deleted user-specified stream filtering rules.
984
-
966
+
985
967
  Returns:
986
968
  dict[str, Any]: The request has succeeded.
987
-
969
+
988
970
  Raises:
989
971
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
990
972
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
991
-
973
+
992
974
  Tags:
993
975
  Tweets
994
976
  """
@@ -1012,21 +994,20 @@ class TweetsApi(APISegmentBase):
1012
994
  response.raise_for_status()
1013
995
  return response.json()
1014
996
 
1015
- def get_rule_count(self, rules_count_fields=None) -> dict[str, Any]:
997
+ def get_stream_rule_usage(self, rules_count_fields=None) -> dict[str, Any]:
1016
998
  """
1017
-
1018
- Retrieves the counts of Tweets matching specific search rules using the "GET" method, providing a way to analyze the volume of Tweets based on predefined criteria.
1019
-
999
+ Retrieves the number of active filtered stream rules for the user's project and app. This helps manage usage against API limits by providing metadata about rule counts, not the number of tweets matching those rules.
1000
+
1020
1001
  Args:
1021
1002
  rules_count_fields (array): A comma separated list of RulesCount fields to display. Example: "['all_project_client_apps', 'cap_per_client_app', 'cap_per_project', 'client_app_rules_count', 'project_rules_count']".
1022
-
1003
+
1023
1004
  Returns:
1024
1005
  dict[str, Any]: The request has succeeded.
1025
-
1006
+
1026
1007
  Raises:
1027
1008
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
1028
1009
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
1029
-
1010
+
1030
1011
  Tags:
1031
1012
  General
1032
1013
  """
@@ -1042,19 +1023,18 @@ class TweetsApi(APISegmentBase):
1042
1023
 
1043
1024
  def delete_tweet_by_id(self, id) -> dict[str, Any]:
1044
1025
  """
1045
-
1046
- Deletes a specified Tweet by its ID on behalf of an authenticated user.
1047
-
1026
+ Deletes a specific Tweet, identified by its unique ID, on behalf of the authenticated user. This function permanently removes the targeted Tweet by sending a DELETE request to the API's corresponding endpoint.
1027
+
1048
1028
  Args:
1049
1029
  id (string): id
1050
-
1030
+
1051
1031
  Returns:
1052
1032
  dict[str, Any]: The request has succeeded.
1053
-
1033
+
1054
1034
  Raises:
1055
1035
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
1056
1036
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
1057
-
1037
+
1058
1038
  Tags:
1059
1039
  Tweets
1060
1040
  """
@@ -1066,7 +1046,7 @@ class TweetsApi(APISegmentBase):
1066
1046
  response.raise_for_status()
1067
1047
  return response.json()
1068
1048
 
1069
- def find_tweet_by_id(
1049
+ def get_tweet_by_id(
1070
1050
  self,
1071
1051
  id,
1072
1052
  tweet_fields=None,
@@ -1077,9 +1057,8 @@ class TweetsApi(APISegmentBase):
1077
1057
  place_fields=None,
1078
1058
  ) -> dict[str, Any]:
1079
1059
  """
1080
-
1081
- Retrieves detailed information about a single Tweet specified by its unique ID, with optional expansions for fields related to the Tweet, user, media, polls, and places.
1082
-
1060
+ Retrieves detailed information for a single Tweet by its unique ID. It supports optional parameters to customize the response by specifying fields for the tweet, user, and media. Unlike `find_tweets_by_id`, which retrieves a batch of tweets, this function fetches exactly one.
1061
+
1083
1062
  Args:
1084
1063
  id (string): id
1085
1064
  tweet_fields (array): A comma separated list of Tweet fields to display. Example: "['article', 'attachments', 'author_id', 'card_uri', 'context_annotations', 'conversation_id', 'created_at', 'edit_controls', 'edit_history_tweet_ids', 'entities', 'geo', 'id', 'in_reply_to_user_id', 'lang', 'non_public_metrics', 'note_tweet', 'organic_metrics', 'possibly_sensitive', 'promoted_metrics', 'public_metrics', 'referenced_tweets', 'reply_settings', 'scopes', 'source', 'text', 'username', 'withheld']".
@@ -1088,14 +1067,14 @@ class TweetsApi(APISegmentBase):
1088
1067
  poll_fields (array): A comma separated list of Poll fields to display. Example: "['duration_minutes', 'end_datetime', 'id', 'options', 'voting_status']".
1089
1068
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
1090
1069
  place_fields (array): A comma separated list of Place fields to display. Example: "['contained_within', 'country', 'country_code', 'full_name', 'geo', 'id', 'name', 'place_type']".
1091
-
1070
+
1092
1071
  Returns:
1093
1072
  dict[str, Any]: The request has succeeded.
1094
-
1073
+
1095
1074
  Raises:
1096
1075
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
1097
1076
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
1098
-
1077
+
1099
1078
  Tags:
1100
1079
  Tweets
1101
1080
  """
@@ -1118,7 +1097,7 @@ class TweetsApi(APISegmentBase):
1118
1097
  response.raise_for_status()
1119
1098
  return response.json()
1120
1099
 
1121
- def tweets_id_liking_users(
1100
+ def get_tweet_liking_users(
1122
1101
  self,
1123
1102
  id,
1124
1103
  max_results=None,
@@ -1128,9 +1107,8 @@ class TweetsApi(APISegmentBase):
1128
1107
  tweet_fields=None,
1129
1108
  ) -> dict[str, Any]:
1130
1109
  """
1131
-
1132
- Retrieves a list of users who have liked a specified tweet using the provided tweet ID.
1133
-
1110
+ Retrieves a list of users who have liked a specific tweet, identified by its ID. Supports pagination and allows for customization of the returned data fields for users and tweets, including expansions for related objects.
1111
+
1134
1112
  Args:
1135
1113
  id (string): id
1136
1114
  max_results (integer): Specifies the maximum number of liking users to return in a response, with a default value of 100 and a maximum allowed value of 100.
@@ -1138,14 +1116,14 @@ class TweetsApi(APISegmentBase):
1138
1116
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
1139
1117
  expansions (array): A comma separated list of fields to expand. Example: "['affiliation.user_id', 'most_recent_tweet_id', 'pinned_tweet_id']".
1140
1118
  tweet_fields (array): A comma separated list of Tweet fields to display. Example: "['article', 'attachments', 'author_id', 'card_uri', 'context_annotations', 'conversation_id', 'created_at', 'edit_controls', 'edit_history_tweet_ids', 'entities', 'geo', 'id', 'in_reply_to_user_id', 'lang', 'non_public_metrics', 'note_tweet', 'organic_metrics', 'possibly_sensitive', 'promoted_metrics', 'public_metrics', 'referenced_tweets', 'reply_settings', 'scopes', 'source', 'text', 'username', 'withheld']".
1141
-
1119
+
1142
1120
  Returns:
1143
1121
  dict[str, Any]: The request has succeeded.
1144
-
1122
+
1145
1123
  Raises:
1146
1124
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
1147
1125
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
1148
-
1126
+
1149
1127
  Tags:
1150
1128
  Users
1151
1129
  """
@@ -1167,7 +1145,7 @@ class TweetsApi(APISegmentBase):
1167
1145
  response.raise_for_status()
1168
1146
  return response.json()
1169
1147
 
1170
- def find_tweets_that_quote_atweet(
1148
+ def get_quote_tweets_by_id(
1171
1149
  self,
1172
1150
  id,
1173
1151
  max_results=None,
@@ -1181,9 +1159,8 @@ class TweetsApi(APISegmentBase):
1181
1159
  place_fields=None,
1182
1160
  ) -> dict[str, Any]:
1183
1161
  """
1184
-
1185
- Retrieves a list of quote Tweets for a specified Tweet ID, allowing for optional parameters to customize the results with fields like tweet fields, media fields, and user expansions, and supports pagination for handling large responses.
1186
-
1162
+ Retrieves a list of tweets that have quoted a specified tweet ID. Supports pagination and allows for response customization by specifying additional data fields for tweets, media, users, polls, and places through various expansion parameters.
1163
+
1187
1164
  Args:
1188
1165
  id (string): id
1189
1166
  max_results (integer): Specifies the maximum number of quote Tweets to return in the response, ranging from 1 to 100, with a default of 10.
@@ -1195,14 +1172,14 @@ class TweetsApi(APISegmentBase):
1195
1172
  poll_fields (array): A comma separated list of Poll fields to display. Example: "['duration_minutes', 'end_datetime', 'id', 'options', 'voting_status']".
1196
1173
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
1197
1174
  place_fields (array): A comma separated list of Place fields to display. Example: "['contained_within', 'country', 'country_code', 'full_name', 'geo', 'id', 'name', 'place_type']".
1198
-
1175
+
1199
1176
  Returns:
1200
1177
  dict[str, Any]: The request has succeeded.
1201
-
1178
+
1202
1179
  Raises:
1203
1180
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
1204
1181
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
1205
-
1182
+
1206
1183
  Tags:
1207
1184
  Tweets
1208
1185
  """
@@ -1228,7 +1205,7 @@ class TweetsApi(APISegmentBase):
1228
1205
  response.raise_for_status()
1229
1206
  return response.json()
1230
1207
 
1231
- def tweets_id_retweeting_users(
1208
+ def get_retweeting_users_by_tweet_id(
1232
1209
  self,
1233
1210
  id,
1234
1211
  max_results=None,
@@ -1238,9 +1215,8 @@ class TweetsApi(APISegmentBase):
1238
1215
  tweet_fields=None,
1239
1216
  ) -> dict[str, Any]:
1240
1217
  """
1241
-
1242
- Retrieves a list of User objects representing users who have retweeted the Tweet specified by the given Tweet ID.
1243
-
1218
+ Retrieves a list of users who retweeted a specific tweet, identified by its ID. Supports pagination and allows customizing the response with optional fields. This function returns user objects, unlike `find_tweets_that_retweet_atweet` which returns the actual retweet objects.
1219
+
1244
1220
  Args:
1245
1221
  id (string): id
1246
1222
  max_results (integer): The `max_results` parameter specifies the maximum number of users to return who have retweeted the specified Tweet, with a default value of 100 and a required range of 1 to 100.
@@ -1248,14 +1224,14 @@ class TweetsApi(APISegmentBase):
1248
1224
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
1249
1225
  expansions (array): A comma separated list of fields to expand. Example: "['affiliation.user_id', 'most_recent_tweet_id', 'pinned_tweet_id']".
1250
1226
  tweet_fields (array): A comma separated list of Tweet fields to display. Example: "['article', 'attachments', 'author_id', 'card_uri', 'context_annotations', 'conversation_id', 'created_at', 'edit_controls', 'edit_history_tweet_ids', 'entities', 'geo', 'id', 'in_reply_to_user_id', 'lang', 'non_public_metrics', 'note_tweet', 'organic_metrics', 'possibly_sensitive', 'promoted_metrics', 'public_metrics', 'referenced_tweets', 'reply_settings', 'scopes', 'source', 'text', 'username', 'withheld']".
1251
-
1227
+
1252
1228
  Returns:
1253
1229
  dict[str, Any]: The request has succeeded.
1254
-
1230
+
1255
1231
  Raises:
1256
1232
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
1257
1233
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
1258
-
1234
+
1259
1235
  Tags:
1260
1236
  Users
1261
1237
  """
@@ -1277,7 +1253,7 @@ class TweetsApi(APISegmentBase):
1277
1253
  response.raise_for_status()
1278
1254
  return response.json()
1279
1255
 
1280
- def find_tweets_that_retweet_atweet(
1256
+ def get_retweets_by_id(
1281
1257
  self,
1282
1258
  id,
1283
1259
  max_results=None,
@@ -1290,9 +1266,8 @@ class TweetsApi(APISegmentBase):
1290
1266
  place_fields=None,
1291
1267
  ) -> dict[str, Any]:
1292
1268
  """
1293
-
1294
- Retrieves a list of retweets for a specified Tweet ID, optionally allowing for pagination and customization of returned fields via query parameters.
1295
-
1269
+ Retrieves Tweet objects that are retweets of a specified tweet ID, supporting pagination and data customization. This function returns the actual retweets, distinguishing it from `tweets_id_retweeting_users` which returns the users who retweeted.
1270
+
1296
1271
  Args:
1297
1272
  id (string): id
1298
1273
  max_results (integer): Specifies the maximum number of retweets to return per request, with a default of 100 and a maximum value of 100.
@@ -1303,14 +1278,14 @@ class TweetsApi(APISegmentBase):
1303
1278
  poll_fields (array): A comma separated list of Poll fields to display. Example: "['duration_minutes', 'end_datetime', 'id', 'options', 'voting_status']".
1304
1279
  user_fields (array): A comma separated list of User fields to display. Example: "['affiliation', 'connection_status', 'created_at', 'description', 'entities', 'id', 'location', 'most_recent_tweet_id', 'name', 'pinned_tweet_id', 'profile_banner_url', 'profile_image_url', 'protected', 'public_metrics', 'receives_your_dm', 'subscription_type', 'url', 'username', 'verified', 'verified_type', 'withheld']".
1305
1280
  place_fields (array): A comma separated list of Place fields to display. Example: "['contained_within', 'country', 'country_code', 'full_name', 'geo', 'id', 'name', 'place_type']".
1306
-
1281
+
1307
1282
  Returns:
1308
1283
  dict[str, Any]: The request has succeeded.
1309
-
1284
+
1310
1285
  Raises:
1311
1286
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
1312
1287
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
1313
-
1288
+
1314
1289
  Tags:
1315
1290
  Tweets
1316
1291
  """
@@ -1335,22 +1310,21 @@ class TweetsApi(APISegmentBase):
1335
1310
  response.raise_for_status()
1336
1311
  return response.json()
1337
1312
 
1338
- def hide_reply_by_id(self, tweet_id, hidden=None) -> dict[str, Any]:
1313
+ def set_reply_visibility(self, tweet_id, hidden=None) -> dict[str, Any]:
1339
1314
  """
1340
-
1341
- Hides or unhides a reply to a specified Tweet by its tweet_id.
1342
-
1315
+ Updates the visibility of a specific reply tweet. This function sends a PUT request to hide or unhide a reply, identified by its `tweet_id`, based on the provided boolean `hidden` parameter, thus managing its state within a conversation.
1316
+
1343
1317
  Args:
1344
1318
  tweet_id (string): tweet_id
1345
1319
  hidden (boolean): hidden
1346
-
1320
+
1347
1321
  Returns:
1348
1322
  dict[str, Any]: The request has succeeded.
1349
-
1323
+
1350
1324
  Raises:
1351
1325
  HTTPError: Raised when the API request fails (e.g., non-2XX status code).
1352
1326
  JSONDecodeError: Raised if the response body cannot be parsed as JSON.
1353
-
1327
+
1354
1328
  Tags:
1355
1329
  Tweets
1356
1330
  """
@@ -1380,24 +1354,24 @@ class TweetsApi(APISegmentBase):
1380
1354
  self.tweet_counts_full_archive_search,
1381
1355
  self.tweet_counts_recent_search,
1382
1356
  self.get_tweets_firehose_stream,
1383
- self.get_tweets_firehose_stream_lang_en,
1357
+ self.stream_english_tweets_firehose,
1384
1358
  self.get_tweets_firehose_stream_lang_ja,
1385
- self.get_tweets_firehose_stream_lang_ko,
1359
+ self.stream_korean_firehose_tweets,
1386
1360
  self.get_tweets_firehose_stream_lang_pt,
1387
- self.get_tweets_label_stream,
1361
+ self.stream_labeled_tweets,
1388
1362
  self.sample_stream,
1389
- self.get_tweets_sample_stream,
1363
+ self.get_tweets_sample10_stream,
1390
1364
  self.tweets_fullarchive_search,
1391
1365
  self.tweets_recent_search,
1392
- self.search_stream,
1393
- self.get_rules,
1394
- self.add_or_delete_rules,
1395
- self.get_rule_count,
1366
+ self.get_filtered_stream,
1367
+ self.get_filtered_stream_rules,
1368
+ self.update_stream_rules,
1369
+ self.get_stream_rule_usage,
1396
1370
  self.delete_tweet_by_id,
1397
- self.find_tweet_by_id,
1398
- self.tweets_id_liking_users,
1399
- self.find_tweets_that_quote_atweet,
1400
- self.tweets_id_retweeting_users,
1401
- self.find_tweets_that_retweet_atweet,
1402
- self.hide_reply_by_id,
1371
+ self.get_tweet_by_id,
1372
+ self.get_tweet_liking_users,
1373
+ self.get_quote_tweets_by_id,
1374
+ self.get_retweeting_users_by_tweet_id,
1375
+ self.get_retweets_by_id,
1376
+ self.set_reply_visibility,
1403
1377
  ]