twitter-openapi-python-generated 0.0.34__py3-none-any.whl → 0.0.35__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.
- twitter_openapi_python_generated/__init__.py +165 -1
- twitter_openapi_python_generated/api/post_api.py +2079 -203
- twitter_openapi_python_generated/api/tweet_api.py +3207 -231
- twitter_openapi_python_generated/api/user_api.py +969 -66
- twitter_openapi_python_generated/api/user_list_api.py +1907 -0
- twitter_openapi_python_generated/api_client.py +47 -9
- twitter_openapi_python_generated/configuration.py +55 -6
- twitter_openapi_python_generated/models/__init__.py +82 -0
- twitter_openapi_python_generated/models/additional_media_info.py +3 -1
- twitter_openapi_python_generated/models/article_cover_media.py +2 -5
- twitter_openapi_python_generated/models/article_cover_media_color_info.py +1 -2
- twitter_openapi_python_generated/models/article_result.py +3 -7
- twitter_openapi_python_generated/models/badge_counts.py +97 -0
- twitter_openapi_python_generated/models/birdwatch_entity_ref.py +3 -1
- twitter_openapi_python_generated/models/birdwatch_pivot_footer.py +1 -2
- twitter_openapi_python_generated/models/birdwatch_pivot_note.py +2 -5
- twitter_openapi_python_generated/models/birdwatch_pivot_subtitle.py +1 -2
- twitter_openapi_python_generated/models/bookmarks_response.py +1 -2
- twitter_openapi_python_generated/models/cashtag_attachment.py +89 -0
- twitter_openapi_python_generated/models/community.py +4 -9
- twitter_openapi_python_generated/models/community_about_timeline_response.py +1 -2
- twitter_openapi_python_generated/models/community_discovery_timeline_response.py +102 -0
- twitter_openapi_python_generated/models/community_discovery_timeline_response_data.py +93 -0
- twitter_openapi_python_generated/models/community_discovery_timeline_viewer.py +93 -0
- twitter_openapi_python_generated/models/community_join_action_result_union.py +3 -2
- twitter_openapi_python_generated/models/community_media_timeline_response.py +1 -2
- twitter_openapi_python_generated/models/community_relationship.py +2 -5
- twitter_openapi_python_generated/models/community_rule.py +2 -5
- twitter_openapi_python_generated/models/community_tweets_timeline_response.py +1 -2
- twitter_openapi_python_generated/models/community_union.py +3 -2
- twitter_openapi_python_generated/models/connect_tab_timeline_response.py +102 -0
- twitter_openapi_python_generated/models/connect_tab_timeline_response_data.py +93 -0
- twitter_openapi_python_generated/models/content_disclosure_ai_generated_disclosure.py +2 -2
- twitter_openapi_python_generated/models/content_item_type.py +3 -0
- twitter_openapi_python_generated/models/content_union.py +3 -2
- twitter_openapi_python_generated/models/cover_cta.py +1 -2
- twitter_openapi_python_generated/models/create_bookmark_response.py +1 -2
- twitter_openapi_python_generated/models/create_draft_tweet_response.py +102 -0
- twitter_openapi_python_generated/models/create_draft_tweet_response_data.py +93 -0
- twitter_openapi_python_generated/models/create_draft_tweet_response_tweet.py +97 -0
- twitter_openapi_python_generated/models/create_retweet_response.py +1 -2
- twitter_openapi_python_generated/models/create_tweet_response.py +1 -2
- twitter_openapi_python_generated/models/delete_bookmark_response.py +1 -2
- twitter_openapi_python_generated/models/delete_draft_tweets_response.py +102 -0
- twitter_openapi_python_generated/models/delete_draft_tweets_response_data.py +89 -0
- twitter_openapi_python_generated/models/delete_list_response.py +102 -0
- twitter_openapi_python_generated/models/delete_list_response_data.py +89 -0
- twitter_openapi_python_generated/models/delete_retweet.py +1 -2
- twitter_openapi_python_generated/models/delete_retweet_response.py +1 -2
- twitter_openapi_python_generated/models/delete_tweet_response.py +1 -2
- twitter_openapi_python_generated/models/draft_list.py +96 -0
- twitter_openapi_python_generated/models/draft_tweet.py +109 -0
- twitter_openapi_python_generated/models/draft_tweet_create_request.py +99 -0
- twitter_openapi_python_generated/models/draft_tweet_user.py +100 -0
- twitter_openapi_python_generated/models/draft_tweet_user_results.py +93 -0
- twitter_openapi_python_generated/models/draft_tweets_viewer.py +93 -0
- twitter_openapi_python_generated/models/entities.py +7 -9
- twitter_openapi_python_generated/models/error_extensions.py +1 -1
- twitter_openapi_python_generated/models/error_response.py +3 -5
- twitter_openapi_python_generated/models/explore_page.py +95 -0
- twitter_openapi_python_generated/models/explore_page_body.py +104 -0
- twitter_openapi_python_generated/models/explore_page_response.py +102 -0
- twitter_openapi_python_generated/models/explore_page_response_data.py +93 -0
- twitter_openapi_python_generated/models/explore_timeline.py +105 -0
- twitter_openapi_python_generated/models/explore_timeline_scribe_config.py +91 -0
- twitter_openapi_python_generated/models/extended_entities.py +1 -2
- twitter_openapi_python_generated/models/favorite_tweet_response.py +1 -2
- twitter_openapi_python_generated/models/fetch_draft_tweets_response.py +102 -0
- twitter_openapi_python_generated/models/fetch_draft_tweets_response_data.py +93 -0
- twitter_openapi_python_generated/models/fetch_scheduled_tweets_response.py +102 -0
- twitter_openapi_python_generated/models/fetch_scheduled_tweets_response_data.py +93 -0
- twitter_openapi_python_generated/models/follow_response.py +1 -2
- twitter_openapi_python_generated/models/generic_timeline_by_id_response.py +102 -0
- twitter_openapi_python_generated/models/generic_timeline_by_id_response_data.py +93 -0
- twitter_openapi_python_generated/models/grok_share_attachment.py +1 -2
- twitter_openapi_python_generated/models/grok_translated_bio.py +101 -0
- twitter_openapi_python_generated/models/grok_translated_bio_with_availability.py +97 -0
- twitter_openapi_python_generated/models/grok_translated_community_note.py +1 -2
- twitter_openapi_python_generated/models/highlight.py +1 -2
- twitter_openapi_python_generated/models/instruction_union.py +3 -2
- twitter_openapi_python_generated/models/item_content_union.py +68 -10
- twitter_openapi_python_generated/models/list_banner_media.py +93 -0
- twitter_openapi_python_generated/models/list_banner_media_info.py +99 -0
- twitter_openapi_python_generated/models/list_banner_media_salient_rect.py +95 -0
- twitter_openapi_python_generated/models/list_latest_tweets_timeline_response.py +1 -2
- twitter_openapi_python_generated/models/list_members_list.py +93 -0
- twitter_openapi_python_generated/models/list_members_response.py +102 -0
- twitter_openapi_python_generated/models/list_members_response_data.py +93 -0
- twitter_openapi_python_generated/models/list_recommended_users_list.py +93 -0
- twitter_openapi_python_generated/models/list_recommended_users_response.py +102 -0
- twitter_openapi_python_generated/models/list_recommended_users_response_data.py +93 -0
- twitter_openapi_python_generated/models/list_response.py +102 -0
- twitter_openapi_python_generated/models/list_response_data.py +93 -0
- twitter_openapi_python_generated/models/list_subscribers_list.py +93 -0
- twitter_openapi_python_generated/models/list_subscribers_response.py +102 -0
- twitter_openapi_python_generated/models/list_subscribers_response_data.py +93 -0
- twitter_openapi_python_generated/models/media.py +16 -17
- twitter_openapi_python_generated/models/media_extended.py +13 -16
- twitter_openapi_python_generated/models/media_original_info.py +1 -2
- twitter_openapi_python_generated/models/media_video_info.py +1 -2
- twitter_openapi_python_generated/models/module_item.py +2 -5
- twitter_openapi_python_generated/models/note_tweet_result_data.py +2 -5
- twitter_openapi_python_generated/models/note_tweet_result_media.py +1 -2
- twitter_openapi_python_generated/models/note_tweet_result_media_inline_media.py +2 -5
- twitter_openapi_python_generated/models/note_tweet_result_rich_text.py +1 -2
- twitter_openapi_python_generated/models/notifications_result.py +2 -5
- twitter_openapi_python_generated/models/notifications_timeline_response.py +1 -2
- twitter_openapi_python_generated/models/post_create_bookmark_request.py +1 -1
- twitter_openapi_python_generated/models/post_create_bookmark_request_variables.py +2 -2
- twitter_openapi_python_generated/models/post_create_draft_tweet_request.py +95 -0
- twitter_openapi_python_generated/models/post_create_draft_tweet_request_variables.py +93 -0
- twitter_openapi_python_generated/models/post_create_draft_tweet_request_variables_post_tweet_request.py +97 -0
- twitter_openapi_python_generated/models/post_create_list_request.py +101 -0
- twitter_openapi_python_generated/models/post_create_list_request_features.py +97 -0
- twitter_openapi_python_generated/models/post_create_list_request_variables.py +93 -0
- twitter_openapi_python_generated/models/post_create_retweet_request.py +1 -1
- twitter_openapi_python_generated/models/post_create_retweet_request_variables.py +3 -3
- twitter_openapi_python_generated/models/post_create_tweet_request.py +2 -2
- twitter_openapi_python_generated/models/post_create_tweet_request_features.py +43 -41
- twitter_openapi_python_generated/models/post_create_tweet_request_variables.py +4 -4
- twitter_openapi_python_generated/models/post_create_tweet_request_variables_conversation_control.py +2 -2
- twitter_openapi_python_generated/models/post_create_tweet_request_variables_media.py +3 -4
- twitter_openapi_python_generated/models/post_create_tweet_request_variables_media_media_entities_inner.py +2 -2
- twitter_openapi_python_generated/models/post_create_tweet_request_variables_reply.py +2 -2
- twitter_openapi_python_generated/models/post_cta_title_text.py +1 -2
- twitter_openapi_python_generated/models/post_delete_bookmark_request.py +1 -1
- twitter_openapi_python_generated/models/post_delete_draft_tweets_request.py +95 -0
- twitter_openapi_python_generated/models/post_delete_draft_tweets_request_variables.py +89 -0
- twitter_openapi_python_generated/models/post_delete_list_request.py +95 -0
- twitter_openapi_python_generated/models/post_delete_list_request_variables.py +89 -0
- twitter_openapi_python_generated/models/post_delete_retweet_request.py +1 -1
- twitter_openapi_python_generated/models/post_delete_retweet_request_variables.py +3 -3
- twitter_openapi_python_generated/models/post_delete_tweet_request.py +2 -2
- twitter_openapi_python_generated/models/post_favorite_tweet_request.py +1 -1
- twitter_openapi_python_generated/models/post_list_add_member_request.py +101 -0
- twitter_openapi_python_generated/models/post_list_add_member_request_variables.py +91 -0
- twitter_openapi_python_generated/models/post_list_remove_member_request.py +101 -0
- twitter_openapi_python_generated/models/post_unfavorite_tweet_request.py +1 -1
- twitter_openapi_python_generated/models/primary_community_topic.py +2 -5
- twitter_openapi_python_generated/models/profile_bio.py +11 -3
- twitter_openapi_python_generated/models/profile_bio_entities.py +98 -0
- twitter_openapi_python_generated/models/profile_bio_entities_urls.py +96 -0
- twitter_openapi_python_generated/models/profile_response.py +1 -2
- twitter_openapi_python_generated/models/retweet.py +4 -7
- twitter_openapi_python_generated/models/scheduled_tweets_viewer.py +89 -0
- twitter_openapi_python_generated/models/search_timeline_response.py +1 -2
- twitter_openapi_python_generated/models/self_thread.py +2 -5
- twitter_openapi_python_generated/models/session.py +8 -20
- twitter_openapi_python_generated/models/social_context_union.py +3 -2
- twitter_openapi_python_generated/models/text.py +1 -2
- twitter_openapi_python_generated/models/timeline.py +1 -2
- twitter_openapi_python_generated/models/timeline_add_entries.py +1 -2
- twitter_openapi_python_generated/models/timeline_add_entry.py +4 -10
- twitter_openapi_python_generated/models/timeline_add_to_module.py +1 -2
- twitter_openapi_python_generated/models/timeline_frame.py +97 -0
- twitter_openapi_python_generated/models/timeline_half_cover.py +1 -2
- twitter_openapi_python_generated/models/timeline_label.py +101 -0
- twitter_openapi_python_generated/models/timeline_mark_entries_unread_greater_than_sort_index.py +2 -5
- twitter_openapi_python_generated/models/timeline_response.py +1 -2
- twitter_openapi_python_generated/models/timeline_show_alert.py +7 -3
- twitter_openapi_python_generated/models/timeline_timeline_module.py +1 -2
- twitter_openapi_python_generated/models/timeline_trend.py +16 -4
- twitter_openapi_python_generated/models/timeline_twitter_list.py +101 -0
- twitter_openapi_python_generated/models/tombstone_rich_text.py +1 -2
- twitter_openapi_python_generated/models/tracing.py +2 -5
- twitter_openapi_python_generated/models/trend_metadata.py +4 -2
- twitter_openapi_python_generated/models/trend_results.py +2 -5
- twitter_openapi_python_generated/models/tweet.py +17 -6
- twitter_openapi_python_generated/models/tweet_card_legacy.py +2 -4
- twitter_openapi_python_generated/models/tweet_card_platform_device.py +2 -5
- twitter_openapi_python_generated/models/tweet_detail_response.py +1 -2
- twitter_openapi_python_generated/models/tweet_edit_control.py +6 -15
- twitter_openapi_python_generated/models/tweet_edit_control_initial.py +4 -10
- twitter_openapi_python_generated/models/tweet_favoriters_response.py +1 -2
- twitter_openapi_python_generated/models/tweet_interstitial_reveal_text.py +1 -2
- twitter_openapi_python_generated/models/tweet_interstitial_text.py +1 -2
- twitter_openapi_python_generated/models/tweet_legacy.py +15 -36
- twitter_openapi_python_generated/models/tweet_limited_action_results.py +1 -2
- twitter_openapi_python_generated/models/tweet_preview_display_tweet.py +5 -11
- twitter_openapi_python_generated/models/tweet_preview_display_tweet_view_count.py +2 -5
- twitter_openapi_python_generated/models/tweet_result_by_rest_id_response.py +1 -2
- twitter_openapi_python_generated/models/tweet_retweeters_response.py +1 -2
- twitter_openapi_python_generated/models/tweet_union.py +3 -2
- twitter_openapi_python_generated/models/tweet_view.py +2 -5
- twitter_openapi_python_generated/models/twitter_list.py +146 -0
- twitter_openapi_python_generated/models/type_name.py +4 -0
- twitter_openapi_python_generated/models/unfavorite_tweet_response.py +1 -2
- twitter_openapi_python_generated/models/urt_endpoint_options.py +3 -4
- twitter_openapi_python_generated/models/user.py +75 -13
- twitter_openapi_python_generated/models/user_action_counts.py +89 -0
- twitter_openapi_python_generated/models/user_banner.py +89 -0
- twitter_openapi_python_generated/models/user_core.py +3 -6
- twitter_openapi_python_generated/models/user_highlights_tweets_response.py +1 -2
- twitter_openapi_python_generated/models/user_legacy.py +3 -6
- twitter_openapi_python_generated/models/user_notifications_settings.py +89 -0
- twitter_openapi_python_generated/models/user_pinned_items.py +90 -0
- twitter_openapi_python_generated/models/user_professional.py +3 -7
- twitter_openapi_python_generated/models/user_profile_metadata.py +89 -0
- twitter_openapi_python_generated/models/user_profile_translation.py +89 -0
- twitter_openapi_python_generated/models/user_relationship_counts.py +91 -0
- twitter_openapi_python_generated/models/user_relationship_perspectives.py +6 -2
- twitter_openapi_python_generated/models/user_response.py +1 -2
- twitter_openapi_python_generated/models/user_result_by_screen_name.py +2 -5
- twitter_openapi_python_generated/models/user_result_by_screen_name_result.py +8 -12
- twitter_openapi_python_generated/models/user_result_core.py +3 -1
- twitter_openapi_python_generated/models/user_results.py +3 -1
- twitter_openapi_python_generated/models/user_tweet_counts.py +91 -0
- twitter_openapi_python_generated/models/user_tweets_response.py +1 -2
- twitter_openapi_python_generated/models/user_union.py +6 -3
- twitter_openapi_python_generated/models/user_value.py +8 -9
- twitter_openapi_python_generated/models/user_verification_info_reason.py +2 -5
- twitter_openapi_python_generated/models/user_verification_info_reason_description.py +1 -2
- twitter_openapi_python_generated/models/user_website.py +89 -0
- twitter_openapi_python_generated/models/users_response.py +1 -2
- twitter_openapi_python_generated/models/users_response_data.py +1 -2
- twitter_openapi_python_generated/models/viewer_badge_counts_response.py +102 -0
- twitter_openapi_python_generated/models/viewer_badge_counts_response_data.py +93 -0
- twitter_openapi_python_generated/models/viewer_badge_counts_result.py +96 -0
- twitter_openapi_python_generated/models/viewer_badge_counts_user_results.py +93 -0
- twitter_openapi_python_generated/models/viewer_badge_counts_viewer.py +93 -0
- twitter_openapi_python_generated/rest.py +79 -8
- {twitter_openapi_python_generated-0.0.34.dist-info → twitter_openapi_python_generated-0.0.35.dist-info}/METADATA +926 -816
- {twitter_openapi_python_generated-0.0.34.dist-info → twitter_openapi_python_generated-0.0.35.dist-info}/RECORD +227 -145
- {twitter_openapi_python_generated-0.0.34.dist-info → twitter_openapi_python_generated-0.0.35.dist-info}/WHEEL +1 -1
- {twitter_openapi_python_generated-0.0.34.dist-info → twitter_openapi_python_generated-0.0.35.dist-info}/licenses/LICENSE +31 -31
- {twitter_openapi_python_generated-0.0.34.dist-info → twitter_openapi_python_generated-0.0.35.dist-info}/licenses/LICENSE.AGPL +660 -660
- {twitter_openapi_python_generated-0.0.34.dist-info → twitter_openapi_python_generated-0.0.35.dist-info}/top_level.txt +0 -0
|
@@ -18,7 +18,7 @@ import pprint
|
|
|
18
18
|
import re # noqa: F401
|
|
19
19
|
import json
|
|
20
20
|
|
|
21
|
-
from pydantic import BaseModel, ConfigDict, StrictBool
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictBool
|
|
22
22
|
from typing import Any, ClassVar, Dict, List
|
|
23
23
|
from typing import Optional, Set
|
|
24
24
|
from typing_extensions import Self
|
|
@@ -28,43 +28,44 @@ class PostCreateTweetRequestFeatures(BaseModel):
|
|
|
28
28
|
"""
|
|
29
29
|
PostCreateTweetRequestFeatures
|
|
30
30
|
""" # noqa: E501
|
|
31
|
-
articles_preview_enabled: StrictBool
|
|
32
|
-
c9s_tweet_anatomy_moderator_badge_enabled: StrictBool
|
|
33
|
-
communities_web_enable_tweet_community_results_fetch: StrictBool
|
|
34
|
-
content_disclosure_ai_generated_indicator_enabled: StrictBool
|
|
35
|
-
content_disclosure_indicator_enabled: StrictBool
|
|
36
|
-
freedom_of_speech_not_reach_fetch_enabled: StrictBool
|
|
37
|
-
graphql_is_translatable_rweb_tweet_is_translatable_enabled: StrictBool
|
|
38
|
-
longform_notetweets_consumption_enabled: StrictBool
|
|
39
|
-
longform_notetweets_inline_media_enabled: StrictBool
|
|
40
|
-
longform_notetweets_rich_text_read_enabled: StrictBool
|
|
41
|
-
post_ctas_fetch_enabled: StrictBool
|
|
42
|
-
premium_content_api_read_enabled: StrictBool
|
|
43
|
-
profile_label_improvements_pcf_label_in_post_enabled: StrictBool
|
|
44
|
-
responsive_web_edit_tweet_api_enabled: StrictBool
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
responsive_web_profile_redirect_enabled: StrictBool
|
|
58
|
-
responsive_web_twitter_article_tweet_consumption_enabled: StrictBool
|
|
59
|
-
rweb_cashtags_composer_attachment_enabled: StrictBool
|
|
60
|
-
rweb_cashtags_enabled: StrictBool
|
|
61
|
-
rweb_conversational_replies_downvote_enabled: StrictBool
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
31
|
+
articles_preview_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
32
|
+
c9s_tweet_anatomy_moderator_badge_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
33
|
+
communities_web_enable_tweet_community_results_fetch: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
34
|
+
content_disclosure_ai_generated_indicator_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
35
|
+
content_disclosure_indicator_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
36
|
+
freedom_of_speech_not_reach_fetch_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
37
|
+
graphql_is_translatable_rweb_tweet_is_translatable_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
38
|
+
longform_notetweets_consumption_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
39
|
+
longform_notetweets_inline_media_enabled: StrictBool = Field(json_schema_extra={"examples": [False]})
|
|
40
|
+
longform_notetweets_rich_text_read_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
41
|
+
post_ctas_fetch_enabled: StrictBool = Field(json_schema_extra={"examples": [False]})
|
|
42
|
+
premium_content_api_read_enabled: StrictBool = Field(json_schema_extra={"examples": [False]})
|
|
43
|
+
profile_label_improvements_pcf_label_in_post_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
44
|
+
responsive_web_edit_tweet_api_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
45
|
+
responsive_web_graphql_timeline_navigation_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
46
|
+
responsive_web_grok_analysis_button_from_backend: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
47
|
+
responsive_web_grok_analyze_button_fetch_trends_enabled: StrictBool = Field(json_schema_extra={"examples": [False]})
|
|
48
|
+
responsive_web_grok_analyze_post_followups_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
49
|
+
responsive_web_grok_annotations_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
50
|
+
responsive_web_grok_community_note_auto_translation_is_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
51
|
+
responsive_web_grok_image_annotation_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
52
|
+
responsive_web_grok_imagine_annotation_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
53
|
+
responsive_web_grok_share_attachment_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
54
|
+
responsive_web_grok_show_grok_translated_post: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
55
|
+
responsive_web_jetfuel_frame: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
56
|
+
responsive_web_nested_quote_preview_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
57
|
+
responsive_web_profile_redirect_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
58
|
+
responsive_web_twitter_article_tweet_consumption_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
59
|
+
rweb_cashtags_composer_attachment_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
60
|
+
rweb_cashtags_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
61
|
+
rweb_conversational_replies_downvote_enabled: StrictBool = Field(json_schema_extra={"examples": [False]})
|
|
62
|
+
rweb_sports_post_context_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
63
|
+
rweb_tipjar_consumption_enabled: StrictBool = Field(json_schema_extra={"examples": [False]})
|
|
64
|
+
standardized_nudges_misinfo: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
65
|
+
tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
66
|
+
verified_phone_label_enabled: StrictBool = Field(json_schema_extra={"examples": [False]})
|
|
67
|
+
view_counts_everywhere_api_enabled: StrictBool = Field(json_schema_extra={"examples": [True]})
|
|
68
|
+
__properties: ClassVar[List[str]] = ["articles_preview_enabled", "c9s_tweet_anatomy_moderator_badge_enabled", "communities_web_enable_tweet_community_results_fetch", "content_disclosure_ai_generated_indicator_enabled", "content_disclosure_indicator_enabled", "freedom_of_speech_not_reach_fetch_enabled", "graphql_is_translatable_rweb_tweet_is_translatable_enabled", "longform_notetweets_consumption_enabled", "longform_notetweets_inline_media_enabled", "longform_notetweets_rich_text_read_enabled", "post_ctas_fetch_enabled", "premium_content_api_read_enabled", "profile_label_improvements_pcf_label_in_post_enabled", "responsive_web_edit_tweet_api_enabled", "responsive_web_graphql_timeline_navigation_enabled", "responsive_web_grok_analysis_button_from_backend", "responsive_web_grok_analyze_button_fetch_trends_enabled", "responsive_web_grok_analyze_post_followups_enabled", "responsive_web_grok_annotations_enabled", "responsive_web_grok_community_note_auto_translation_is_enabled", "responsive_web_grok_image_annotation_enabled", "responsive_web_grok_imagine_annotation_enabled", "responsive_web_grok_share_attachment_enabled", "responsive_web_grok_show_grok_translated_post", "responsive_web_jetfuel_frame", "responsive_web_nested_quote_preview_enabled", "responsive_web_profile_redirect_enabled", "responsive_web_twitter_article_tweet_consumption_enabled", "rweb_cashtags_composer_attachment_enabled", "rweb_cashtags_enabled", "rweb_conversational_replies_downvote_enabled", "rweb_sports_post_context_enabled", "rweb_tipjar_consumption_enabled", "standardized_nudges_misinfo", "tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled", "verified_phone_label_enabled", "view_counts_everywhere_api_enabled"]
|
|
68
69
|
|
|
69
70
|
model_config = ConfigDict(
|
|
70
71
|
validate_by_name=True,
|
|
@@ -127,11 +128,10 @@ class PostCreateTweetRequestFeatures(BaseModel):
|
|
|
127
128
|
"longform_notetweets_consumption_enabled": obj.get("longform_notetweets_consumption_enabled") if obj.get("longform_notetweets_consumption_enabled") is not None else True,
|
|
128
129
|
"longform_notetweets_inline_media_enabled": obj.get("longform_notetweets_inline_media_enabled") if obj.get("longform_notetweets_inline_media_enabled") is not None else False,
|
|
129
130
|
"longform_notetweets_rich_text_read_enabled": obj.get("longform_notetweets_rich_text_read_enabled") if obj.get("longform_notetweets_rich_text_read_enabled") is not None else True,
|
|
130
|
-
"post_ctas_fetch_enabled": obj.get("post_ctas_fetch_enabled") if obj.get("post_ctas_fetch_enabled") is not None else
|
|
131
|
+
"post_ctas_fetch_enabled": obj.get("post_ctas_fetch_enabled") if obj.get("post_ctas_fetch_enabled") is not None else False,
|
|
131
132
|
"premium_content_api_read_enabled": obj.get("premium_content_api_read_enabled") if obj.get("premium_content_api_read_enabled") is not None else False,
|
|
132
133
|
"profile_label_improvements_pcf_label_in_post_enabled": obj.get("profile_label_improvements_pcf_label_in_post_enabled") if obj.get("profile_label_improvements_pcf_label_in_post_enabled") is not None else True,
|
|
133
134
|
"responsive_web_edit_tweet_api_enabled": obj.get("responsive_web_edit_tweet_api_enabled") if obj.get("responsive_web_edit_tweet_api_enabled") is not None else True,
|
|
134
|
-
"responsive_web_graphql_skip_user_profile_image_extensions_enabled": obj.get("responsive_web_graphql_skip_user_profile_image_extensions_enabled") if obj.get("responsive_web_graphql_skip_user_profile_image_extensions_enabled") is not None else False,
|
|
135
135
|
"responsive_web_graphql_timeline_navigation_enabled": obj.get("responsive_web_graphql_timeline_navigation_enabled") if obj.get("responsive_web_graphql_timeline_navigation_enabled") is not None else True,
|
|
136
136
|
"responsive_web_grok_analysis_button_from_backend": obj.get("responsive_web_grok_analysis_button_from_backend") if obj.get("responsive_web_grok_analysis_button_from_backend") is not None else True,
|
|
137
137
|
"responsive_web_grok_analyze_button_fetch_trends_enabled": obj.get("responsive_web_grok_analyze_button_fetch_trends_enabled") if obj.get("responsive_web_grok_analyze_button_fetch_trends_enabled") is not None else False,
|
|
@@ -143,11 +143,13 @@ class PostCreateTweetRequestFeatures(BaseModel):
|
|
|
143
143
|
"responsive_web_grok_share_attachment_enabled": obj.get("responsive_web_grok_share_attachment_enabled") if obj.get("responsive_web_grok_share_attachment_enabled") is not None else True,
|
|
144
144
|
"responsive_web_grok_show_grok_translated_post": obj.get("responsive_web_grok_show_grok_translated_post") if obj.get("responsive_web_grok_show_grok_translated_post") is not None else True,
|
|
145
145
|
"responsive_web_jetfuel_frame": obj.get("responsive_web_jetfuel_frame") if obj.get("responsive_web_jetfuel_frame") is not None else True,
|
|
146
|
-
"
|
|
146
|
+
"responsive_web_nested_quote_preview_enabled": obj.get("responsive_web_nested_quote_preview_enabled") if obj.get("responsive_web_nested_quote_preview_enabled") is not None else True,
|
|
147
|
+
"responsive_web_profile_redirect_enabled": obj.get("responsive_web_profile_redirect_enabled") if obj.get("responsive_web_profile_redirect_enabled") is not None else True,
|
|
147
148
|
"responsive_web_twitter_article_tweet_consumption_enabled": obj.get("responsive_web_twitter_article_tweet_consumption_enabled") if obj.get("responsive_web_twitter_article_tweet_consumption_enabled") is not None else True,
|
|
148
149
|
"rweb_cashtags_composer_attachment_enabled": obj.get("rweb_cashtags_composer_attachment_enabled") if obj.get("rweb_cashtags_composer_attachment_enabled") is not None else True,
|
|
149
150
|
"rweb_cashtags_enabled": obj.get("rweb_cashtags_enabled") if obj.get("rweb_cashtags_enabled") is not None else True,
|
|
150
151
|
"rweb_conversational_replies_downvote_enabled": obj.get("rweb_conversational_replies_downvote_enabled") if obj.get("rweb_conversational_replies_downvote_enabled") is not None else False,
|
|
152
|
+
"rweb_sports_post_context_enabled": obj.get("rweb_sports_post_context_enabled") if obj.get("rweb_sports_post_context_enabled") is not None else True,
|
|
151
153
|
"rweb_tipjar_consumption_enabled": obj.get("rweb_tipjar_consumption_enabled") if obj.get("rweb_tipjar_consumption_enabled") is not None else False,
|
|
152
154
|
"standardized_nudges_misinfo": obj.get("standardized_nudges_misinfo") if obj.get("standardized_nudges_misinfo") is not None else True,
|
|
153
155
|
"tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled": obj.get("tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled") if obj.get("tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled") is not None else True,
|
|
@@ -18,7 +18,7 @@ import pprint
|
|
|
18
18
|
import re # noqa: F401
|
|
19
19
|
import json
|
|
20
20
|
|
|
21
|
-
from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr
|
|
22
22
|
from typing import Any, ClassVar, Dict, List, Optional
|
|
23
23
|
from twitter_openapi_python_generated.models.post_create_tweet_request_variables_conversation_control import PostCreateTweetRequestVariablesConversationControl
|
|
24
24
|
from twitter_openapi_python_generated.models.post_create_tweet_request_variables_media import PostCreateTweetRequestVariablesMedia
|
|
@@ -31,14 +31,14 @@ class PostCreateTweetRequestVariables(BaseModel):
|
|
|
31
31
|
"""
|
|
32
32
|
PostCreateTweetRequestVariables
|
|
33
33
|
""" # noqa: E501
|
|
34
|
-
attachment_url: Optional[StrictStr] = 'https://x.com/elonmusk/status/1349129669258448897'
|
|
34
|
+
attachment_url: Optional[StrictStr] = Field(default='https://x.com/elonmusk/status/1349129669258448897', json_schema_extra={"examples": ["https://x.com/elonmusk/status/1349129669258448897"]})
|
|
35
35
|
conversation_control: Optional[PostCreateTweetRequestVariablesConversationControl] = None
|
|
36
|
-
dark_request: StrictBool
|
|
36
|
+
dark_request: StrictBool = Field(json_schema_extra={"examples": [False]})
|
|
37
37
|
disallowed_reply_options: Optional[Dict[str, Any]] = None
|
|
38
38
|
media: PostCreateTweetRequestVariablesMedia
|
|
39
39
|
reply: Optional[PostCreateTweetRequestVariablesReply] = None
|
|
40
40
|
semantic_annotation_ids: List[Dict[str, Any]]
|
|
41
|
-
tweet_text: StrictStr
|
|
41
|
+
tweet_text: StrictStr = Field(json_schema_extra={"examples": ["test"]})
|
|
42
42
|
__properties: ClassVar[List[str]] = ["attachment_url", "conversation_control", "dark_request", "disallowed_reply_options", "media", "reply", "semantic_annotation_ids", "tweet_text"]
|
|
43
43
|
|
|
44
44
|
model_config = ConfigDict(
|
twitter_openapi_python_generated/models/post_create_tweet_request_variables_conversation_control.py
CHANGED
|
@@ -18,7 +18,7 @@ import pprint
|
|
|
18
18
|
import re # noqa: F401
|
|
19
19
|
import json
|
|
20
20
|
|
|
21
|
-
from pydantic import BaseModel, ConfigDict, StrictStr
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
22
22
|
from typing import Any, ClassVar, Dict, List
|
|
23
23
|
from typing import Optional, Set
|
|
24
24
|
from typing_extensions import Self
|
|
@@ -28,7 +28,7 @@ class PostCreateTweetRequestVariablesConversationControl(BaseModel):
|
|
|
28
28
|
"""
|
|
29
29
|
PostCreateTweetRequestVariablesConversationControl
|
|
30
30
|
""" # noqa: E501
|
|
31
|
-
mode: StrictStr
|
|
31
|
+
mode: StrictStr = Field(json_schema_extra={"examples": ["Community"]})
|
|
32
32
|
__properties: ClassVar[List[str]] = ["mode"]
|
|
33
33
|
|
|
34
34
|
model_config = ConfigDict(
|
|
@@ -18,7 +18,7 @@ import pprint
|
|
|
18
18
|
import re # noqa: F401
|
|
19
19
|
import json
|
|
20
20
|
|
|
21
|
-
from pydantic import BaseModel, ConfigDict, StrictBool
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictBool
|
|
22
22
|
from typing import Any, ClassVar, Dict, List, Optional
|
|
23
23
|
from twitter_openapi_python_generated.models.post_create_tweet_request_variables_media_media_entities_inner import PostCreateTweetRequestVariablesMediaMediaEntitiesInner
|
|
24
24
|
from typing import Optional, Set
|
|
@@ -30,7 +30,7 @@ class PostCreateTweetRequestVariablesMedia(BaseModel):
|
|
|
30
30
|
PostCreateTweetRequestVariablesMedia
|
|
31
31
|
""" # noqa: E501
|
|
32
32
|
media_entities: Optional[List[PostCreateTweetRequestVariablesMediaMediaEntitiesInner]] = None
|
|
33
|
-
possibly_sensitive: StrictBool
|
|
33
|
+
possibly_sensitive: StrictBool = Field(json_schema_extra={"examples": [False]})
|
|
34
34
|
__properties: ClassVar[List[str]] = ["media_entities", "possibly_sensitive"]
|
|
35
35
|
|
|
36
36
|
model_config = ConfigDict(
|
|
@@ -76,8 +76,7 @@ class PostCreateTweetRequestVariablesMedia(BaseModel):
|
|
|
76
76
|
_items = []
|
|
77
77
|
if self.media_entities:
|
|
78
78
|
for _item_media_entities in self.media_entities:
|
|
79
|
-
if _item_media_entities
|
|
80
|
-
_items.append(_item_media_entities.to_dict())
|
|
79
|
+
_items.append(_item_media_entities.to_dict() if _item_media_entities is not None else None)
|
|
81
80
|
_dict['media_entities'] = _items
|
|
82
81
|
return _dict
|
|
83
82
|
|
|
@@ -18,7 +18,7 @@ import pprint
|
|
|
18
18
|
import re # noqa: F401
|
|
19
19
|
import json
|
|
20
20
|
|
|
21
|
-
from pydantic import BaseModel, ConfigDict, StrictStr
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
22
22
|
from typing import Any, ClassVar, Dict, List
|
|
23
23
|
from typing import Optional, Set
|
|
24
24
|
from typing_extensions import Self
|
|
@@ -28,7 +28,7 @@ class PostCreateTweetRequestVariablesMediaMediaEntitiesInner(BaseModel):
|
|
|
28
28
|
"""
|
|
29
29
|
PostCreateTweetRequestVariablesMediaMediaEntitiesInner
|
|
30
30
|
""" # noqa: E501
|
|
31
|
-
media_id: StrictStr
|
|
31
|
+
media_id: StrictStr = Field(json_schema_extra={"examples": ["1111111111111111111"]})
|
|
32
32
|
tagged_users: List[StrictStr]
|
|
33
33
|
__properties: ClassVar[List[str]] = ["media_id", "tagged_users"]
|
|
34
34
|
|
|
@@ -18,7 +18,7 @@ import pprint
|
|
|
18
18
|
import re # noqa: F401
|
|
19
19
|
import json
|
|
20
20
|
|
|
21
|
-
from pydantic import BaseModel, ConfigDict, StrictStr
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
22
22
|
from typing import Any, ClassVar, Dict, List
|
|
23
23
|
from typing import Optional, Set
|
|
24
24
|
from typing_extensions import Self
|
|
@@ -29,7 +29,7 @@ class PostCreateTweetRequestVariablesReply(BaseModel):
|
|
|
29
29
|
PostCreateTweetRequestVariablesReply
|
|
30
30
|
""" # noqa: E501
|
|
31
31
|
exclude_reply_user_ids: List[Dict[str, Any]]
|
|
32
|
-
in_reply_to_tweet_id: StrictStr
|
|
32
|
+
in_reply_to_tweet_id: StrictStr = Field(json_schema_extra={"examples": ["1111111111111111111"]})
|
|
33
33
|
__properties: ClassVar[List[str]] = ["exclude_reply_user_ids", "in_reply_to_tweet_id"]
|
|
34
34
|
|
|
35
35
|
model_config = ConfigDict(
|
|
@@ -76,8 +76,7 @@ class PostCtaTitleText(BaseModel):
|
|
|
76
76
|
_items = []
|
|
77
77
|
if self.entities:
|
|
78
78
|
for _item_entities in self.entities:
|
|
79
|
-
if _item_entities
|
|
80
|
-
_items.append(_item_entities.to_dict())
|
|
79
|
+
_items.append(_item_entities.to_dict() if _item_entities is not None else None)
|
|
81
80
|
_dict['entities'] = _items
|
|
82
81
|
return _dict
|
|
83
82
|
|
|
@@ -29,7 +29,7 @@ class PostDeleteBookmarkRequest(BaseModel):
|
|
|
29
29
|
"""
|
|
30
30
|
PostDeleteBookmarkRequest
|
|
31
31
|
""" # noqa: E501
|
|
32
|
-
query_id: StrictStr = Field(alias="queryId")
|
|
32
|
+
query_id: StrictStr = Field(alias="queryId", json_schema_extra={"examples": ["Wlmlj2-xzyS1GN3a6cj-mQ"]})
|
|
33
33
|
variables: PostCreateBookmarkRequestVariables
|
|
34
34
|
__properties: ClassVar[List[str]] = ["queryId", "variables"]
|
|
35
35
|
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Twitter OpenAPI
|
|
5
|
+
|
|
6
|
+
Twitter OpenAPI(Swagger) specification
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 0.0.1
|
|
9
|
+
Contact: yuki@yuki0311.com
|
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
|
+
|
|
12
|
+
Do not edit the class manually.
|
|
13
|
+
""" # noqa: E501
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import pprint
|
|
18
|
+
import re # noqa: F401
|
|
19
|
+
import json
|
|
20
|
+
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
22
|
+
from typing import Any, ClassVar, Dict, List
|
|
23
|
+
from twitter_openapi_python_generated.models.post_delete_draft_tweets_request_variables import PostDeleteDraftTweetsRequestVariables
|
|
24
|
+
from typing import Optional, Set
|
|
25
|
+
from typing_extensions import Self
|
|
26
|
+
from pydantic_core import to_jsonable_python
|
|
27
|
+
|
|
28
|
+
class PostDeleteDraftTweetsRequest(BaseModel):
|
|
29
|
+
"""
|
|
30
|
+
PostDeleteDraftTweetsRequest
|
|
31
|
+
""" # noqa: E501
|
|
32
|
+
query_id: StrictStr = Field(alias="queryId", json_schema_extra={"examples": ["h0rzaIYc9-v3zTQvx1J8OA"]})
|
|
33
|
+
variables: PostDeleteDraftTweetsRequestVariables
|
|
34
|
+
__properties: ClassVar[List[str]] = ["queryId", "variables"]
|
|
35
|
+
|
|
36
|
+
model_config = ConfigDict(
|
|
37
|
+
validate_by_name=True,
|
|
38
|
+
validate_by_alias=True,
|
|
39
|
+
validate_assignment=True,
|
|
40
|
+
protected_namespaces=(),
|
|
41
|
+
)
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
def to_str(self) -> str:
|
|
45
|
+
"""Returns the string representation of the model using alias"""
|
|
46
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
47
|
+
|
|
48
|
+
def to_json(self) -> str:
|
|
49
|
+
"""Returns the JSON representation of the model using alias"""
|
|
50
|
+
return json.dumps(to_jsonable_python(self.to_dict()))
|
|
51
|
+
|
|
52
|
+
@classmethod
|
|
53
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
54
|
+
"""Create an instance of PostDeleteDraftTweetsRequest from a JSON string"""
|
|
55
|
+
return cls.from_dict(json.loads(json_str))
|
|
56
|
+
|
|
57
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
58
|
+
"""Return the dictionary representation of the model using alias.
|
|
59
|
+
|
|
60
|
+
This has the following differences from calling pydantic's
|
|
61
|
+
`self.model_dump(by_alias=True)`:
|
|
62
|
+
|
|
63
|
+
* `None` is only added to the output dict for nullable fields that
|
|
64
|
+
were set at model initialization. Other fields with value `None`
|
|
65
|
+
are ignored.
|
|
66
|
+
"""
|
|
67
|
+
excluded_fields: Set[str] = set([
|
|
68
|
+
])
|
|
69
|
+
|
|
70
|
+
_dict = self.model_dump(
|
|
71
|
+
by_alias=True,
|
|
72
|
+
exclude=excluded_fields,
|
|
73
|
+
exclude_none=True,
|
|
74
|
+
)
|
|
75
|
+
# override the default output from pydantic by calling `to_dict()` of variables
|
|
76
|
+
if self.variables:
|
|
77
|
+
_dict['variables'] = self.variables.to_dict()
|
|
78
|
+
return _dict
|
|
79
|
+
|
|
80
|
+
@classmethod
|
|
81
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
82
|
+
"""Create an instance of PostDeleteDraftTweetsRequest from a dict"""
|
|
83
|
+
if obj is None:
|
|
84
|
+
return None
|
|
85
|
+
|
|
86
|
+
if not isinstance(obj, dict):
|
|
87
|
+
return cls.model_validate(obj)
|
|
88
|
+
|
|
89
|
+
_obj = cls.model_validate({
|
|
90
|
+
"queryId": obj.get("queryId") if obj.get("queryId") is not None else 'h0rzaIYc9-v3zTQvx1J8OA',
|
|
91
|
+
"variables": PostDeleteDraftTweetsRequestVariables.from_dict(obj["variables"]) if obj.get("variables") is not None else None
|
|
92
|
+
})
|
|
93
|
+
return _obj
|
|
94
|
+
|
|
95
|
+
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Twitter OpenAPI
|
|
5
|
+
|
|
6
|
+
Twitter OpenAPI(Swagger) specification
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 0.0.1
|
|
9
|
+
Contact: yuki@yuki0311.com
|
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
|
+
|
|
12
|
+
Do not edit the class manually.
|
|
13
|
+
""" # noqa: E501
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import pprint
|
|
18
|
+
import re # noqa: F401
|
|
19
|
+
import json
|
|
20
|
+
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, StrictStr
|
|
22
|
+
from typing import Any, ClassVar, Dict, List
|
|
23
|
+
from typing import Optional, Set
|
|
24
|
+
from typing_extensions import Self
|
|
25
|
+
from pydantic_core import to_jsonable_python
|
|
26
|
+
|
|
27
|
+
class PostDeleteDraftTweetsRequestVariables(BaseModel):
|
|
28
|
+
"""
|
|
29
|
+
PostDeleteDraftTweetsRequestVariables
|
|
30
|
+
""" # noqa: E501
|
|
31
|
+
draft_tweet_ids: List[StrictStr]
|
|
32
|
+
__properties: ClassVar[List[str]] = ["draft_tweet_ids"]
|
|
33
|
+
|
|
34
|
+
model_config = ConfigDict(
|
|
35
|
+
validate_by_name=True,
|
|
36
|
+
validate_by_alias=True,
|
|
37
|
+
validate_assignment=True,
|
|
38
|
+
protected_namespaces=(),
|
|
39
|
+
)
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
def to_str(self) -> str:
|
|
43
|
+
"""Returns the string representation of the model using alias"""
|
|
44
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
45
|
+
|
|
46
|
+
def to_json(self) -> str:
|
|
47
|
+
"""Returns the JSON representation of the model using alias"""
|
|
48
|
+
return json.dumps(to_jsonable_python(self.to_dict()))
|
|
49
|
+
|
|
50
|
+
@classmethod
|
|
51
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
52
|
+
"""Create an instance of PostDeleteDraftTweetsRequestVariables from a JSON string"""
|
|
53
|
+
return cls.from_dict(json.loads(json_str))
|
|
54
|
+
|
|
55
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
56
|
+
"""Return the dictionary representation of the model using alias.
|
|
57
|
+
|
|
58
|
+
This has the following differences from calling pydantic's
|
|
59
|
+
`self.model_dump(by_alias=True)`:
|
|
60
|
+
|
|
61
|
+
* `None` is only added to the output dict for nullable fields that
|
|
62
|
+
were set at model initialization. Other fields with value `None`
|
|
63
|
+
are ignored.
|
|
64
|
+
"""
|
|
65
|
+
excluded_fields: Set[str] = set([
|
|
66
|
+
])
|
|
67
|
+
|
|
68
|
+
_dict = self.model_dump(
|
|
69
|
+
by_alias=True,
|
|
70
|
+
exclude=excluded_fields,
|
|
71
|
+
exclude_none=True,
|
|
72
|
+
)
|
|
73
|
+
return _dict
|
|
74
|
+
|
|
75
|
+
@classmethod
|
|
76
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
77
|
+
"""Create an instance of PostDeleteDraftTweetsRequestVariables from a dict"""
|
|
78
|
+
if obj is None:
|
|
79
|
+
return None
|
|
80
|
+
|
|
81
|
+
if not isinstance(obj, dict):
|
|
82
|
+
return cls.model_validate(obj)
|
|
83
|
+
|
|
84
|
+
_obj = cls.model_validate({
|
|
85
|
+
"draft_tweet_ids": obj.get("draft_tweet_ids")
|
|
86
|
+
})
|
|
87
|
+
return _obj
|
|
88
|
+
|
|
89
|
+
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Twitter OpenAPI
|
|
5
|
+
|
|
6
|
+
Twitter OpenAPI(Swagger) specification
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 0.0.1
|
|
9
|
+
Contact: yuki@yuki0311.com
|
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
|
+
|
|
12
|
+
Do not edit the class manually.
|
|
13
|
+
""" # noqa: E501
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import pprint
|
|
18
|
+
import re # noqa: F401
|
|
19
|
+
import json
|
|
20
|
+
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
22
|
+
from typing import Any, ClassVar, Dict, List
|
|
23
|
+
from twitter_openapi_python_generated.models.post_delete_list_request_variables import PostDeleteListRequestVariables
|
|
24
|
+
from typing import Optional, Set
|
|
25
|
+
from typing_extensions import Self
|
|
26
|
+
from pydantic_core import to_jsonable_python
|
|
27
|
+
|
|
28
|
+
class PostDeleteListRequest(BaseModel):
|
|
29
|
+
"""
|
|
30
|
+
PostDeleteListRequest
|
|
31
|
+
""" # noqa: E501
|
|
32
|
+
query_id: StrictStr = Field(alias="queryId", json_schema_extra={"examples": ["UnN9Th1BDbeLjpgjGSpL3Q"]})
|
|
33
|
+
variables: PostDeleteListRequestVariables
|
|
34
|
+
__properties: ClassVar[List[str]] = ["queryId", "variables"]
|
|
35
|
+
|
|
36
|
+
model_config = ConfigDict(
|
|
37
|
+
validate_by_name=True,
|
|
38
|
+
validate_by_alias=True,
|
|
39
|
+
validate_assignment=True,
|
|
40
|
+
protected_namespaces=(),
|
|
41
|
+
)
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
def to_str(self) -> str:
|
|
45
|
+
"""Returns the string representation of the model using alias"""
|
|
46
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
47
|
+
|
|
48
|
+
def to_json(self) -> str:
|
|
49
|
+
"""Returns the JSON representation of the model using alias"""
|
|
50
|
+
return json.dumps(to_jsonable_python(self.to_dict()))
|
|
51
|
+
|
|
52
|
+
@classmethod
|
|
53
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
54
|
+
"""Create an instance of PostDeleteListRequest from a JSON string"""
|
|
55
|
+
return cls.from_dict(json.loads(json_str))
|
|
56
|
+
|
|
57
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
58
|
+
"""Return the dictionary representation of the model using alias.
|
|
59
|
+
|
|
60
|
+
This has the following differences from calling pydantic's
|
|
61
|
+
`self.model_dump(by_alias=True)`:
|
|
62
|
+
|
|
63
|
+
* `None` is only added to the output dict for nullable fields that
|
|
64
|
+
were set at model initialization. Other fields with value `None`
|
|
65
|
+
are ignored.
|
|
66
|
+
"""
|
|
67
|
+
excluded_fields: Set[str] = set([
|
|
68
|
+
])
|
|
69
|
+
|
|
70
|
+
_dict = self.model_dump(
|
|
71
|
+
by_alias=True,
|
|
72
|
+
exclude=excluded_fields,
|
|
73
|
+
exclude_none=True,
|
|
74
|
+
)
|
|
75
|
+
# override the default output from pydantic by calling `to_dict()` of variables
|
|
76
|
+
if self.variables:
|
|
77
|
+
_dict['variables'] = self.variables.to_dict()
|
|
78
|
+
return _dict
|
|
79
|
+
|
|
80
|
+
@classmethod
|
|
81
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
82
|
+
"""Create an instance of PostDeleteListRequest from a dict"""
|
|
83
|
+
if obj is None:
|
|
84
|
+
return None
|
|
85
|
+
|
|
86
|
+
if not isinstance(obj, dict):
|
|
87
|
+
return cls.model_validate(obj)
|
|
88
|
+
|
|
89
|
+
_obj = cls.model_validate({
|
|
90
|
+
"queryId": obj.get("queryId") if obj.get("queryId") is not None else 'UnN9Th1BDbeLjpgjGSpL3Q',
|
|
91
|
+
"variables": PostDeleteListRequestVariables.from_dict(obj["variables"]) if obj.get("variables") is not None else None
|
|
92
|
+
})
|
|
93
|
+
return _obj
|
|
94
|
+
|
|
95
|
+
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Twitter OpenAPI
|
|
5
|
+
|
|
6
|
+
Twitter OpenAPI(Swagger) specification
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 0.0.1
|
|
9
|
+
Contact: yuki@yuki0311.com
|
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
|
+
|
|
12
|
+
Do not edit the class manually.
|
|
13
|
+
""" # noqa: E501
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import pprint
|
|
18
|
+
import re # noqa: F401
|
|
19
|
+
import json
|
|
20
|
+
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
22
|
+
from typing import Any, ClassVar, Dict, List
|
|
23
|
+
from typing import Optional, Set
|
|
24
|
+
from typing_extensions import Self
|
|
25
|
+
from pydantic_core import to_jsonable_python
|
|
26
|
+
|
|
27
|
+
class PostDeleteListRequestVariables(BaseModel):
|
|
28
|
+
"""
|
|
29
|
+
PostDeleteListRequestVariables
|
|
30
|
+
""" # noqa: E501
|
|
31
|
+
list_id: StrictStr = Field(alias="listId", json_schema_extra={"examples": ["1141162794290520064"]})
|
|
32
|
+
__properties: ClassVar[List[str]] = ["listId"]
|
|
33
|
+
|
|
34
|
+
model_config = ConfigDict(
|
|
35
|
+
validate_by_name=True,
|
|
36
|
+
validate_by_alias=True,
|
|
37
|
+
validate_assignment=True,
|
|
38
|
+
protected_namespaces=(),
|
|
39
|
+
)
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
def to_str(self) -> str:
|
|
43
|
+
"""Returns the string representation of the model using alias"""
|
|
44
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
45
|
+
|
|
46
|
+
def to_json(self) -> str:
|
|
47
|
+
"""Returns the JSON representation of the model using alias"""
|
|
48
|
+
return json.dumps(to_jsonable_python(self.to_dict()))
|
|
49
|
+
|
|
50
|
+
@classmethod
|
|
51
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
52
|
+
"""Create an instance of PostDeleteListRequestVariables from a JSON string"""
|
|
53
|
+
return cls.from_dict(json.loads(json_str))
|
|
54
|
+
|
|
55
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
56
|
+
"""Return the dictionary representation of the model using alias.
|
|
57
|
+
|
|
58
|
+
This has the following differences from calling pydantic's
|
|
59
|
+
`self.model_dump(by_alias=True)`:
|
|
60
|
+
|
|
61
|
+
* `None` is only added to the output dict for nullable fields that
|
|
62
|
+
were set at model initialization. Other fields with value `None`
|
|
63
|
+
are ignored.
|
|
64
|
+
"""
|
|
65
|
+
excluded_fields: Set[str] = set([
|
|
66
|
+
])
|
|
67
|
+
|
|
68
|
+
_dict = self.model_dump(
|
|
69
|
+
by_alias=True,
|
|
70
|
+
exclude=excluded_fields,
|
|
71
|
+
exclude_none=True,
|
|
72
|
+
)
|
|
73
|
+
return _dict
|
|
74
|
+
|
|
75
|
+
@classmethod
|
|
76
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
77
|
+
"""Create an instance of PostDeleteListRequestVariables from a dict"""
|
|
78
|
+
if obj is None:
|
|
79
|
+
return None
|
|
80
|
+
|
|
81
|
+
if not isinstance(obj, dict):
|
|
82
|
+
return cls.model_validate(obj)
|
|
83
|
+
|
|
84
|
+
_obj = cls.model_validate({
|
|
85
|
+
"listId": obj.get("listId") if obj.get("listId") is not None else '1141162794290520064'
|
|
86
|
+
})
|
|
87
|
+
return _obj
|
|
88
|
+
|
|
89
|
+
|
|
@@ -29,7 +29,7 @@ class PostDeleteRetweetRequest(BaseModel):
|
|
|
29
29
|
"""
|
|
30
30
|
PostDeleteRetweetRequest
|
|
31
31
|
""" # noqa: E501
|
|
32
|
-
query_id: StrictStr = Field(alias="queryId")
|
|
32
|
+
query_id: StrictStr = Field(alias="queryId", json_schema_extra={"examples": ["ZyZigVsNiFO6v1dEks1eWg"]})
|
|
33
33
|
variables: PostDeleteRetweetRequestVariables
|
|
34
34
|
__properties: ClassVar[List[str]] = ["queryId", "variables"]
|
|
35
35
|
|