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.
Files changed (227) hide show
  1. twitter_openapi_python_generated/__init__.py +165 -1
  2. twitter_openapi_python_generated/api/post_api.py +2079 -203
  3. twitter_openapi_python_generated/api/tweet_api.py +3207 -231
  4. twitter_openapi_python_generated/api/user_api.py +969 -66
  5. twitter_openapi_python_generated/api/user_list_api.py +1907 -0
  6. twitter_openapi_python_generated/api_client.py +47 -9
  7. twitter_openapi_python_generated/configuration.py +55 -6
  8. twitter_openapi_python_generated/models/__init__.py +82 -0
  9. twitter_openapi_python_generated/models/additional_media_info.py +3 -1
  10. twitter_openapi_python_generated/models/article_cover_media.py +2 -5
  11. twitter_openapi_python_generated/models/article_cover_media_color_info.py +1 -2
  12. twitter_openapi_python_generated/models/article_result.py +3 -7
  13. twitter_openapi_python_generated/models/badge_counts.py +97 -0
  14. twitter_openapi_python_generated/models/birdwatch_entity_ref.py +3 -1
  15. twitter_openapi_python_generated/models/birdwatch_pivot_footer.py +1 -2
  16. twitter_openapi_python_generated/models/birdwatch_pivot_note.py +2 -5
  17. twitter_openapi_python_generated/models/birdwatch_pivot_subtitle.py +1 -2
  18. twitter_openapi_python_generated/models/bookmarks_response.py +1 -2
  19. twitter_openapi_python_generated/models/cashtag_attachment.py +89 -0
  20. twitter_openapi_python_generated/models/community.py +4 -9
  21. twitter_openapi_python_generated/models/community_about_timeline_response.py +1 -2
  22. twitter_openapi_python_generated/models/community_discovery_timeline_response.py +102 -0
  23. twitter_openapi_python_generated/models/community_discovery_timeline_response_data.py +93 -0
  24. twitter_openapi_python_generated/models/community_discovery_timeline_viewer.py +93 -0
  25. twitter_openapi_python_generated/models/community_join_action_result_union.py +3 -2
  26. twitter_openapi_python_generated/models/community_media_timeline_response.py +1 -2
  27. twitter_openapi_python_generated/models/community_relationship.py +2 -5
  28. twitter_openapi_python_generated/models/community_rule.py +2 -5
  29. twitter_openapi_python_generated/models/community_tweets_timeline_response.py +1 -2
  30. twitter_openapi_python_generated/models/community_union.py +3 -2
  31. twitter_openapi_python_generated/models/connect_tab_timeline_response.py +102 -0
  32. twitter_openapi_python_generated/models/connect_tab_timeline_response_data.py +93 -0
  33. twitter_openapi_python_generated/models/content_disclosure_ai_generated_disclosure.py +2 -2
  34. twitter_openapi_python_generated/models/content_item_type.py +3 -0
  35. twitter_openapi_python_generated/models/content_union.py +3 -2
  36. twitter_openapi_python_generated/models/cover_cta.py +1 -2
  37. twitter_openapi_python_generated/models/create_bookmark_response.py +1 -2
  38. twitter_openapi_python_generated/models/create_draft_tweet_response.py +102 -0
  39. twitter_openapi_python_generated/models/create_draft_tweet_response_data.py +93 -0
  40. twitter_openapi_python_generated/models/create_draft_tweet_response_tweet.py +97 -0
  41. twitter_openapi_python_generated/models/create_retweet_response.py +1 -2
  42. twitter_openapi_python_generated/models/create_tweet_response.py +1 -2
  43. twitter_openapi_python_generated/models/delete_bookmark_response.py +1 -2
  44. twitter_openapi_python_generated/models/delete_draft_tweets_response.py +102 -0
  45. twitter_openapi_python_generated/models/delete_draft_tweets_response_data.py +89 -0
  46. twitter_openapi_python_generated/models/delete_list_response.py +102 -0
  47. twitter_openapi_python_generated/models/delete_list_response_data.py +89 -0
  48. twitter_openapi_python_generated/models/delete_retweet.py +1 -2
  49. twitter_openapi_python_generated/models/delete_retweet_response.py +1 -2
  50. twitter_openapi_python_generated/models/delete_tweet_response.py +1 -2
  51. twitter_openapi_python_generated/models/draft_list.py +96 -0
  52. twitter_openapi_python_generated/models/draft_tweet.py +109 -0
  53. twitter_openapi_python_generated/models/draft_tweet_create_request.py +99 -0
  54. twitter_openapi_python_generated/models/draft_tweet_user.py +100 -0
  55. twitter_openapi_python_generated/models/draft_tweet_user_results.py +93 -0
  56. twitter_openapi_python_generated/models/draft_tweets_viewer.py +93 -0
  57. twitter_openapi_python_generated/models/entities.py +7 -9
  58. twitter_openapi_python_generated/models/error_extensions.py +1 -1
  59. twitter_openapi_python_generated/models/error_response.py +3 -5
  60. twitter_openapi_python_generated/models/explore_page.py +95 -0
  61. twitter_openapi_python_generated/models/explore_page_body.py +104 -0
  62. twitter_openapi_python_generated/models/explore_page_response.py +102 -0
  63. twitter_openapi_python_generated/models/explore_page_response_data.py +93 -0
  64. twitter_openapi_python_generated/models/explore_timeline.py +105 -0
  65. twitter_openapi_python_generated/models/explore_timeline_scribe_config.py +91 -0
  66. twitter_openapi_python_generated/models/extended_entities.py +1 -2
  67. twitter_openapi_python_generated/models/favorite_tweet_response.py +1 -2
  68. twitter_openapi_python_generated/models/fetch_draft_tweets_response.py +102 -0
  69. twitter_openapi_python_generated/models/fetch_draft_tweets_response_data.py +93 -0
  70. twitter_openapi_python_generated/models/fetch_scheduled_tweets_response.py +102 -0
  71. twitter_openapi_python_generated/models/fetch_scheduled_tweets_response_data.py +93 -0
  72. twitter_openapi_python_generated/models/follow_response.py +1 -2
  73. twitter_openapi_python_generated/models/generic_timeline_by_id_response.py +102 -0
  74. twitter_openapi_python_generated/models/generic_timeline_by_id_response_data.py +93 -0
  75. twitter_openapi_python_generated/models/grok_share_attachment.py +1 -2
  76. twitter_openapi_python_generated/models/grok_translated_bio.py +101 -0
  77. twitter_openapi_python_generated/models/grok_translated_bio_with_availability.py +97 -0
  78. twitter_openapi_python_generated/models/grok_translated_community_note.py +1 -2
  79. twitter_openapi_python_generated/models/highlight.py +1 -2
  80. twitter_openapi_python_generated/models/instruction_union.py +3 -2
  81. twitter_openapi_python_generated/models/item_content_union.py +68 -10
  82. twitter_openapi_python_generated/models/list_banner_media.py +93 -0
  83. twitter_openapi_python_generated/models/list_banner_media_info.py +99 -0
  84. twitter_openapi_python_generated/models/list_banner_media_salient_rect.py +95 -0
  85. twitter_openapi_python_generated/models/list_latest_tweets_timeline_response.py +1 -2
  86. twitter_openapi_python_generated/models/list_members_list.py +93 -0
  87. twitter_openapi_python_generated/models/list_members_response.py +102 -0
  88. twitter_openapi_python_generated/models/list_members_response_data.py +93 -0
  89. twitter_openapi_python_generated/models/list_recommended_users_list.py +93 -0
  90. twitter_openapi_python_generated/models/list_recommended_users_response.py +102 -0
  91. twitter_openapi_python_generated/models/list_recommended_users_response_data.py +93 -0
  92. twitter_openapi_python_generated/models/list_response.py +102 -0
  93. twitter_openapi_python_generated/models/list_response_data.py +93 -0
  94. twitter_openapi_python_generated/models/list_subscribers_list.py +93 -0
  95. twitter_openapi_python_generated/models/list_subscribers_response.py +102 -0
  96. twitter_openapi_python_generated/models/list_subscribers_response_data.py +93 -0
  97. twitter_openapi_python_generated/models/media.py +16 -17
  98. twitter_openapi_python_generated/models/media_extended.py +13 -16
  99. twitter_openapi_python_generated/models/media_original_info.py +1 -2
  100. twitter_openapi_python_generated/models/media_video_info.py +1 -2
  101. twitter_openapi_python_generated/models/module_item.py +2 -5
  102. twitter_openapi_python_generated/models/note_tweet_result_data.py +2 -5
  103. twitter_openapi_python_generated/models/note_tweet_result_media.py +1 -2
  104. twitter_openapi_python_generated/models/note_tweet_result_media_inline_media.py +2 -5
  105. twitter_openapi_python_generated/models/note_tweet_result_rich_text.py +1 -2
  106. twitter_openapi_python_generated/models/notifications_result.py +2 -5
  107. twitter_openapi_python_generated/models/notifications_timeline_response.py +1 -2
  108. twitter_openapi_python_generated/models/post_create_bookmark_request.py +1 -1
  109. twitter_openapi_python_generated/models/post_create_bookmark_request_variables.py +2 -2
  110. twitter_openapi_python_generated/models/post_create_draft_tweet_request.py +95 -0
  111. twitter_openapi_python_generated/models/post_create_draft_tweet_request_variables.py +93 -0
  112. twitter_openapi_python_generated/models/post_create_draft_tweet_request_variables_post_tweet_request.py +97 -0
  113. twitter_openapi_python_generated/models/post_create_list_request.py +101 -0
  114. twitter_openapi_python_generated/models/post_create_list_request_features.py +97 -0
  115. twitter_openapi_python_generated/models/post_create_list_request_variables.py +93 -0
  116. twitter_openapi_python_generated/models/post_create_retweet_request.py +1 -1
  117. twitter_openapi_python_generated/models/post_create_retweet_request_variables.py +3 -3
  118. twitter_openapi_python_generated/models/post_create_tweet_request.py +2 -2
  119. twitter_openapi_python_generated/models/post_create_tweet_request_features.py +43 -41
  120. twitter_openapi_python_generated/models/post_create_tweet_request_variables.py +4 -4
  121. twitter_openapi_python_generated/models/post_create_tweet_request_variables_conversation_control.py +2 -2
  122. twitter_openapi_python_generated/models/post_create_tweet_request_variables_media.py +3 -4
  123. twitter_openapi_python_generated/models/post_create_tweet_request_variables_media_media_entities_inner.py +2 -2
  124. twitter_openapi_python_generated/models/post_create_tweet_request_variables_reply.py +2 -2
  125. twitter_openapi_python_generated/models/post_cta_title_text.py +1 -2
  126. twitter_openapi_python_generated/models/post_delete_bookmark_request.py +1 -1
  127. twitter_openapi_python_generated/models/post_delete_draft_tweets_request.py +95 -0
  128. twitter_openapi_python_generated/models/post_delete_draft_tweets_request_variables.py +89 -0
  129. twitter_openapi_python_generated/models/post_delete_list_request.py +95 -0
  130. twitter_openapi_python_generated/models/post_delete_list_request_variables.py +89 -0
  131. twitter_openapi_python_generated/models/post_delete_retweet_request.py +1 -1
  132. twitter_openapi_python_generated/models/post_delete_retweet_request_variables.py +3 -3
  133. twitter_openapi_python_generated/models/post_delete_tweet_request.py +2 -2
  134. twitter_openapi_python_generated/models/post_favorite_tweet_request.py +1 -1
  135. twitter_openapi_python_generated/models/post_list_add_member_request.py +101 -0
  136. twitter_openapi_python_generated/models/post_list_add_member_request_variables.py +91 -0
  137. twitter_openapi_python_generated/models/post_list_remove_member_request.py +101 -0
  138. twitter_openapi_python_generated/models/post_unfavorite_tweet_request.py +1 -1
  139. twitter_openapi_python_generated/models/primary_community_topic.py +2 -5
  140. twitter_openapi_python_generated/models/profile_bio.py +11 -3
  141. twitter_openapi_python_generated/models/profile_bio_entities.py +98 -0
  142. twitter_openapi_python_generated/models/profile_bio_entities_urls.py +96 -0
  143. twitter_openapi_python_generated/models/profile_response.py +1 -2
  144. twitter_openapi_python_generated/models/retweet.py +4 -7
  145. twitter_openapi_python_generated/models/scheduled_tweets_viewer.py +89 -0
  146. twitter_openapi_python_generated/models/search_timeline_response.py +1 -2
  147. twitter_openapi_python_generated/models/self_thread.py +2 -5
  148. twitter_openapi_python_generated/models/session.py +8 -20
  149. twitter_openapi_python_generated/models/social_context_union.py +3 -2
  150. twitter_openapi_python_generated/models/text.py +1 -2
  151. twitter_openapi_python_generated/models/timeline.py +1 -2
  152. twitter_openapi_python_generated/models/timeline_add_entries.py +1 -2
  153. twitter_openapi_python_generated/models/timeline_add_entry.py +4 -10
  154. twitter_openapi_python_generated/models/timeline_add_to_module.py +1 -2
  155. twitter_openapi_python_generated/models/timeline_frame.py +97 -0
  156. twitter_openapi_python_generated/models/timeline_half_cover.py +1 -2
  157. twitter_openapi_python_generated/models/timeline_label.py +101 -0
  158. twitter_openapi_python_generated/models/timeline_mark_entries_unread_greater_than_sort_index.py +2 -5
  159. twitter_openapi_python_generated/models/timeline_response.py +1 -2
  160. twitter_openapi_python_generated/models/timeline_show_alert.py +7 -3
  161. twitter_openapi_python_generated/models/timeline_timeline_module.py +1 -2
  162. twitter_openapi_python_generated/models/timeline_trend.py +16 -4
  163. twitter_openapi_python_generated/models/timeline_twitter_list.py +101 -0
  164. twitter_openapi_python_generated/models/tombstone_rich_text.py +1 -2
  165. twitter_openapi_python_generated/models/tracing.py +2 -5
  166. twitter_openapi_python_generated/models/trend_metadata.py +4 -2
  167. twitter_openapi_python_generated/models/trend_results.py +2 -5
  168. twitter_openapi_python_generated/models/tweet.py +17 -6
  169. twitter_openapi_python_generated/models/tweet_card_legacy.py +2 -4
  170. twitter_openapi_python_generated/models/tweet_card_platform_device.py +2 -5
  171. twitter_openapi_python_generated/models/tweet_detail_response.py +1 -2
  172. twitter_openapi_python_generated/models/tweet_edit_control.py +6 -15
  173. twitter_openapi_python_generated/models/tweet_edit_control_initial.py +4 -10
  174. twitter_openapi_python_generated/models/tweet_favoriters_response.py +1 -2
  175. twitter_openapi_python_generated/models/tweet_interstitial_reveal_text.py +1 -2
  176. twitter_openapi_python_generated/models/tweet_interstitial_text.py +1 -2
  177. twitter_openapi_python_generated/models/tweet_legacy.py +15 -36
  178. twitter_openapi_python_generated/models/tweet_limited_action_results.py +1 -2
  179. twitter_openapi_python_generated/models/tweet_preview_display_tweet.py +5 -11
  180. twitter_openapi_python_generated/models/tweet_preview_display_tweet_view_count.py +2 -5
  181. twitter_openapi_python_generated/models/tweet_result_by_rest_id_response.py +1 -2
  182. twitter_openapi_python_generated/models/tweet_retweeters_response.py +1 -2
  183. twitter_openapi_python_generated/models/tweet_union.py +3 -2
  184. twitter_openapi_python_generated/models/tweet_view.py +2 -5
  185. twitter_openapi_python_generated/models/twitter_list.py +146 -0
  186. twitter_openapi_python_generated/models/type_name.py +4 -0
  187. twitter_openapi_python_generated/models/unfavorite_tweet_response.py +1 -2
  188. twitter_openapi_python_generated/models/urt_endpoint_options.py +3 -4
  189. twitter_openapi_python_generated/models/user.py +75 -13
  190. twitter_openapi_python_generated/models/user_action_counts.py +89 -0
  191. twitter_openapi_python_generated/models/user_banner.py +89 -0
  192. twitter_openapi_python_generated/models/user_core.py +3 -6
  193. twitter_openapi_python_generated/models/user_highlights_tweets_response.py +1 -2
  194. twitter_openapi_python_generated/models/user_legacy.py +3 -6
  195. twitter_openapi_python_generated/models/user_notifications_settings.py +89 -0
  196. twitter_openapi_python_generated/models/user_pinned_items.py +90 -0
  197. twitter_openapi_python_generated/models/user_professional.py +3 -7
  198. twitter_openapi_python_generated/models/user_profile_metadata.py +89 -0
  199. twitter_openapi_python_generated/models/user_profile_translation.py +89 -0
  200. twitter_openapi_python_generated/models/user_relationship_counts.py +91 -0
  201. twitter_openapi_python_generated/models/user_relationship_perspectives.py +6 -2
  202. twitter_openapi_python_generated/models/user_response.py +1 -2
  203. twitter_openapi_python_generated/models/user_result_by_screen_name.py +2 -5
  204. twitter_openapi_python_generated/models/user_result_by_screen_name_result.py +8 -12
  205. twitter_openapi_python_generated/models/user_result_core.py +3 -1
  206. twitter_openapi_python_generated/models/user_results.py +3 -1
  207. twitter_openapi_python_generated/models/user_tweet_counts.py +91 -0
  208. twitter_openapi_python_generated/models/user_tweets_response.py +1 -2
  209. twitter_openapi_python_generated/models/user_union.py +6 -3
  210. twitter_openapi_python_generated/models/user_value.py +8 -9
  211. twitter_openapi_python_generated/models/user_verification_info_reason.py +2 -5
  212. twitter_openapi_python_generated/models/user_verification_info_reason_description.py +1 -2
  213. twitter_openapi_python_generated/models/user_website.py +89 -0
  214. twitter_openapi_python_generated/models/users_response.py +1 -2
  215. twitter_openapi_python_generated/models/users_response_data.py +1 -2
  216. twitter_openapi_python_generated/models/viewer_badge_counts_response.py +102 -0
  217. twitter_openapi_python_generated/models/viewer_badge_counts_response_data.py +93 -0
  218. twitter_openapi_python_generated/models/viewer_badge_counts_result.py +96 -0
  219. twitter_openapi_python_generated/models/viewer_badge_counts_user_results.py +93 -0
  220. twitter_openapi_python_generated/models/viewer_badge_counts_viewer.py +93 -0
  221. twitter_openapi_python_generated/rest.py +79 -8
  222. {twitter_openapi_python_generated-0.0.34.dist-info → twitter_openapi_python_generated-0.0.35.dist-info}/METADATA +926 -816
  223. {twitter_openapi_python_generated-0.0.34.dist-info → twitter_openapi_python_generated-0.0.35.dist-info}/RECORD +227 -145
  224. {twitter_openapi_python_generated-0.0.34.dist-info → twitter_openapi_python_generated-0.0.35.dist-info}/WHEEL +1 -1
  225. {twitter_openapi_python_generated-0.0.34.dist-info → twitter_openapi_python_generated-0.0.35.dist-info}/licenses/LICENSE +31 -31
  226. {twitter_openapi_python_generated-0.0.34.dist-info → twitter_openapi_python_generated-0.0.35.dist-info}/licenses/LICENSE.AGPL +660 -660
  227. {twitter_openapi_python_generated-0.0.34.dist-info → twitter_openapi_python_generated-0.0.35.dist-info}/top_level.txt +0 -0
@@ -17,7 +17,10 @@ from typing import Any, Dict, List, Optional, Tuple, Union
17
17
  from typing_extensions import Annotated
18
18
 
19
19
  from pydantic import StrictStr
20
+ from twitter_openapi_python_generated.models.fetch_draft_tweets_response import FetchDraftTweetsResponse
21
+ from twitter_openapi_python_generated.models.fetch_scheduled_tweets_response import FetchScheduledTweetsResponse
20
22
  from twitter_openapi_python_generated.models.user_response import UserResponse
23
+ from twitter_openapi_python_generated.models.viewer_badge_counts_response import ViewerBadgeCountsResponse
21
24
 
22
25
  from twitter_openapi_python_generated.api_client import ApiClient, RequestSerialized
23
26
  from twitter_openapi_python_generated.api_response import ApiResponse
@@ -37,6 +40,606 @@ class UserApi:
37
40
  self.api_client = api_client
38
41
 
39
42
 
43
+ @validate_call
44
+ def get_fetch_draft_tweets(
45
+ self,
46
+ path_query_id: StrictStr,
47
+ variables: StrictStr,
48
+ _request_timeout: Union[
49
+ None,
50
+ Annotated[StrictFloat, Field(gt=0)],
51
+ Tuple[
52
+ Annotated[StrictFloat, Field(gt=0)],
53
+ Annotated[StrictFloat, Field(gt=0)]
54
+ ]
55
+ ] = None,
56
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
57
+ _content_type: Optional[StrictStr] = None,
58
+ _headers: Optional[Dict[StrictStr, Any]] = None,
59
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
60
+ ) -> FetchDraftTweetsResponse:
61
+ """get_fetch_draft_tweets
62
+
63
+ get drafts (unsent posts)
64
+
65
+ :param path_query_id: (required)
66
+ :type path_query_id: str
67
+ :param variables: (required)
68
+ :type variables: str
69
+ :param _request_timeout: timeout setting for this request. If one
70
+ number provided, it will be total request
71
+ timeout. It can also be a pair (tuple) of
72
+ (connection, read) timeouts.
73
+ :type _request_timeout: int, tuple(int, int), optional
74
+ :param _request_auth: set to override the auth_settings for an a single
75
+ request; this effectively ignores the
76
+ authentication in the spec for a single request.
77
+ :type _request_auth: dict, optional
78
+ :param _content_type: force content-type for the request.
79
+ :type _content_type: str, Optional
80
+ :param _headers: set to override the headers for a single
81
+ request; this effectively ignores the headers
82
+ in the spec for a single request.
83
+ :type _headers: dict, optional
84
+ :param _host_index: set to override the host_index for a single
85
+ request; this effectively ignores the host_index
86
+ in the spec for a single request.
87
+ :type _host_index: int, optional
88
+ :return: Returns the result object.
89
+ """ # noqa: E501
90
+
91
+ _param = self._get_fetch_draft_tweets_serialize(
92
+ path_query_id=path_query_id,
93
+ variables=variables,
94
+ _request_auth=_request_auth,
95
+ _content_type=_content_type,
96
+ _headers=_headers,
97
+ _host_index=_host_index
98
+ )
99
+
100
+ _response_types_map: Dict[str, Optional[str]] = {
101
+ '200': "FetchDraftTweetsResponse",
102
+ }
103
+ response_data = self.api_client.call_api(
104
+ *_param,
105
+ _request_timeout=_request_timeout
106
+ )
107
+ response_data.read()
108
+ return self.api_client.response_deserialize(
109
+ response_data=response_data,
110
+ response_types_map=_response_types_map,
111
+ ).data
112
+
113
+
114
+ @validate_call
115
+ def get_fetch_draft_tweets_with_http_info(
116
+ self,
117
+ path_query_id: StrictStr,
118
+ variables: StrictStr,
119
+ _request_timeout: Union[
120
+ None,
121
+ Annotated[StrictFloat, Field(gt=0)],
122
+ Tuple[
123
+ Annotated[StrictFloat, Field(gt=0)],
124
+ Annotated[StrictFloat, Field(gt=0)]
125
+ ]
126
+ ] = None,
127
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
128
+ _content_type: Optional[StrictStr] = None,
129
+ _headers: Optional[Dict[StrictStr, Any]] = None,
130
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
131
+ ) -> ApiResponse[FetchDraftTweetsResponse]:
132
+ """get_fetch_draft_tweets
133
+
134
+ get drafts (unsent posts)
135
+
136
+ :param path_query_id: (required)
137
+ :type path_query_id: str
138
+ :param variables: (required)
139
+ :type variables: str
140
+ :param _request_timeout: timeout setting for this request. If one
141
+ number provided, it will be total request
142
+ timeout. It can also be a pair (tuple) of
143
+ (connection, read) timeouts.
144
+ :type _request_timeout: int, tuple(int, int), optional
145
+ :param _request_auth: set to override the auth_settings for an a single
146
+ request; this effectively ignores the
147
+ authentication in the spec for a single request.
148
+ :type _request_auth: dict, optional
149
+ :param _content_type: force content-type for the request.
150
+ :type _content_type: str, Optional
151
+ :param _headers: set to override the headers for a single
152
+ request; this effectively ignores the headers
153
+ in the spec for a single request.
154
+ :type _headers: dict, optional
155
+ :param _host_index: set to override the host_index for a single
156
+ request; this effectively ignores the host_index
157
+ in the spec for a single request.
158
+ :type _host_index: int, optional
159
+ :return: Returns the result object.
160
+ """ # noqa: E501
161
+
162
+ _param = self._get_fetch_draft_tweets_serialize(
163
+ path_query_id=path_query_id,
164
+ variables=variables,
165
+ _request_auth=_request_auth,
166
+ _content_type=_content_type,
167
+ _headers=_headers,
168
+ _host_index=_host_index
169
+ )
170
+
171
+ _response_types_map: Dict[str, Optional[str]] = {
172
+ '200': "FetchDraftTweetsResponse",
173
+ }
174
+ response_data = self.api_client.call_api(
175
+ *_param,
176
+ _request_timeout=_request_timeout
177
+ )
178
+ response_data.read()
179
+ return self.api_client.response_deserialize(
180
+ response_data=response_data,
181
+ response_types_map=_response_types_map,
182
+ )
183
+
184
+
185
+ @validate_call
186
+ def get_fetch_draft_tweets_without_preload_content(
187
+ self,
188
+ path_query_id: StrictStr,
189
+ variables: StrictStr,
190
+ _request_timeout: Union[
191
+ None,
192
+ Annotated[StrictFloat, Field(gt=0)],
193
+ Tuple[
194
+ Annotated[StrictFloat, Field(gt=0)],
195
+ Annotated[StrictFloat, Field(gt=0)]
196
+ ]
197
+ ] = None,
198
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
199
+ _content_type: Optional[StrictStr] = None,
200
+ _headers: Optional[Dict[StrictStr, Any]] = None,
201
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
202
+ ) -> RESTResponseType:
203
+ """get_fetch_draft_tweets
204
+
205
+ get drafts (unsent posts)
206
+
207
+ :param path_query_id: (required)
208
+ :type path_query_id: str
209
+ :param variables: (required)
210
+ :type variables: str
211
+ :param _request_timeout: timeout setting for this request. If one
212
+ number provided, it will be total request
213
+ timeout. It can also be a pair (tuple) of
214
+ (connection, read) timeouts.
215
+ :type _request_timeout: int, tuple(int, int), optional
216
+ :param _request_auth: set to override the auth_settings for an a single
217
+ request; this effectively ignores the
218
+ authentication in the spec for a single request.
219
+ :type _request_auth: dict, optional
220
+ :param _content_type: force content-type for the request.
221
+ :type _content_type: str, Optional
222
+ :param _headers: set to override the headers for a single
223
+ request; this effectively ignores the headers
224
+ in the spec for a single request.
225
+ :type _headers: dict, optional
226
+ :param _host_index: set to override the host_index for a single
227
+ request; this effectively ignores the host_index
228
+ in the spec for a single request.
229
+ :type _host_index: int, optional
230
+ :return: Returns the result object.
231
+ """ # noqa: E501
232
+
233
+ _param = self._get_fetch_draft_tweets_serialize(
234
+ path_query_id=path_query_id,
235
+ variables=variables,
236
+ _request_auth=_request_auth,
237
+ _content_type=_content_type,
238
+ _headers=_headers,
239
+ _host_index=_host_index
240
+ )
241
+
242
+ _response_types_map: Dict[str, Optional[str]] = {
243
+ '200': "FetchDraftTweetsResponse",
244
+ }
245
+ response_data = self.api_client.call_api(
246
+ *_param,
247
+ _request_timeout=_request_timeout
248
+ )
249
+ return response_data.response
250
+
251
+
252
+ def _get_fetch_draft_tweets_serialize(
253
+ self,
254
+ path_query_id,
255
+ variables,
256
+ _request_auth,
257
+ _content_type,
258
+ _headers,
259
+ _host_index,
260
+ ) -> RequestSerialized:
261
+
262
+ _host = None
263
+
264
+ _collection_formats: Dict[str, str] = {
265
+ }
266
+
267
+ _path_params: Dict[str, str] = {}
268
+ _query_params: List[Tuple[str, str]] = []
269
+ _header_params: Dict[str, Optional[str]] = _headers or {}
270
+ _form_params: List[Tuple[str, str]] = []
271
+ _files: Dict[
272
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
273
+ ] = {}
274
+ _body_params: Optional[bytes] = None
275
+
276
+ # process the path parameters
277
+ if path_query_id is not None:
278
+ _path_params['pathQueryId'] = path_query_id
279
+ # process the query parameters
280
+ if variables is not None:
281
+
282
+ _query_params.append(('variables', variables))
283
+
284
+ # process the header parameters
285
+ # process the form parameters
286
+ # process the body parameter
287
+
288
+
289
+ # set the HTTP header `Accept`
290
+ if 'Accept' not in _header_params:
291
+ _header_params['Accept'] = self.api_client.select_header_accept(
292
+ [
293
+ 'application/json'
294
+ ]
295
+ )
296
+
297
+
298
+ # authentication setting
299
+ _auth_settings: List[str] = [
300
+ 'Accept',
301
+ 'ClientLanguage',
302
+ 'Priority',
303
+ 'Referer',
304
+ 'SecFetchDest',
305
+ 'SecChUaPlatform',
306
+ 'SecFetchMode',
307
+ 'CsrfToken',
308
+ 'ClientUuid',
309
+ 'BearerAuth',
310
+ 'GuestToken',
311
+ 'SecChUa',
312
+ 'CookieGt0',
313
+ 'ClientTransactionId',
314
+ 'ActiveUser',
315
+ 'CookieCt0',
316
+ 'UserAgent',
317
+ 'AcceptLanguage',
318
+ 'SecFetchSite',
319
+ 'AuthType',
320
+ 'CookieAuthToken',
321
+ 'SecChUaMobile',
322
+ 'AcceptEncoding'
323
+ ]
324
+
325
+ return self.api_client.param_serialize(
326
+ method='GET',
327
+ resource_path='/graphql/{pathQueryId}/FetchDraftTweets',
328
+ path_params=_path_params,
329
+ query_params=_query_params,
330
+ header_params=_header_params,
331
+ body=_body_params,
332
+ post_params=_form_params,
333
+ files=_files,
334
+ auth_settings=_auth_settings,
335
+ collection_formats=_collection_formats,
336
+ _host=_host,
337
+ _request_auth=_request_auth
338
+ )
339
+
340
+
341
+
342
+
343
+ @validate_call
344
+ def get_fetch_scheduled_tweets(
345
+ self,
346
+ path_query_id: StrictStr,
347
+ variables: StrictStr,
348
+ _request_timeout: Union[
349
+ None,
350
+ Annotated[StrictFloat, Field(gt=0)],
351
+ Tuple[
352
+ Annotated[StrictFloat, Field(gt=0)],
353
+ Annotated[StrictFloat, Field(gt=0)]
354
+ ]
355
+ ] = None,
356
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
357
+ _content_type: Optional[StrictStr] = None,
358
+ _headers: Optional[Dict[StrictStr, Any]] = None,
359
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
360
+ ) -> FetchScheduledTweetsResponse:
361
+ """get_fetch_scheduled_tweets
362
+
363
+ get scheduled posts
364
+
365
+ :param path_query_id: (required)
366
+ :type path_query_id: str
367
+ :param variables: (required)
368
+ :type variables: str
369
+ :param _request_timeout: timeout setting for this request. If one
370
+ number provided, it will be total request
371
+ timeout. It can also be a pair (tuple) of
372
+ (connection, read) timeouts.
373
+ :type _request_timeout: int, tuple(int, int), optional
374
+ :param _request_auth: set to override the auth_settings for an a single
375
+ request; this effectively ignores the
376
+ authentication in the spec for a single request.
377
+ :type _request_auth: dict, optional
378
+ :param _content_type: force content-type for the request.
379
+ :type _content_type: str, Optional
380
+ :param _headers: set to override the headers for a single
381
+ request; this effectively ignores the headers
382
+ in the spec for a single request.
383
+ :type _headers: dict, optional
384
+ :param _host_index: set to override the host_index for a single
385
+ request; this effectively ignores the host_index
386
+ in the spec for a single request.
387
+ :type _host_index: int, optional
388
+ :return: Returns the result object.
389
+ """ # noqa: E501
390
+
391
+ _param = self._get_fetch_scheduled_tweets_serialize(
392
+ path_query_id=path_query_id,
393
+ variables=variables,
394
+ _request_auth=_request_auth,
395
+ _content_type=_content_type,
396
+ _headers=_headers,
397
+ _host_index=_host_index
398
+ )
399
+
400
+ _response_types_map: Dict[str, Optional[str]] = {
401
+ '200': "FetchScheduledTweetsResponse",
402
+ }
403
+ response_data = self.api_client.call_api(
404
+ *_param,
405
+ _request_timeout=_request_timeout
406
+ )
407
+ response_data.read()
408
+ return self.api_client.response_deserialize(
409
+ response_data=response_data,
410
+ response_types_map=_response_types_map,
411
+ ).data
412
+
413
+
414
+ @validate_call
415
+ def get_fetch_scheduled_tweets_with_http_info(
416
+ self,
417
+ path_query_id: StrictStr,
418
+ variables: StrictStr,
419
+ _request_timeout: Union[
420
+ None,
421
+ Annotated[StrictFloat, Field(gt=0)],
422
+ Tuple[
423
+ Annotated[StrictFloat, Field(gt=0)],
424
+ Annotated[StrictFloat, Field(gt=0)]
425
+ ]
426
+ ] = None,
427
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
428
+ _content_type: Optional[StrictStr] = None,
429
+ _headers: Optional[Dict[StrictStr, Any]] = None,
430
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
431
+ ) -> ApiResponse[FetchScheduledTweetsResponse]:
432
+ """get_fetch_scheduled_tweets
433
+
434
+ get scheduled posts
435
+
436
+ :param path_query_id: (required)
437
+ :type path_query_id: str
438
+ :param variables: (required)
439
+ :type variables: str
440
+ :param _request_timeout: timeout setting for this request. If one
441
+ number provided, it will be total request
442
+ timeout. It can also be a pair (tuple) of
443
+ (connection, read) timeouts.
444
+ :type _request_timeout: int, tuple(int, int), optional
445
+ :param _request_auth: set to override the auth_settings for an a single
446
+ request; this effectively ignores the
447
+ authentication in the spec for a single request.
448
+ :type _request_auth: dict, optional
449
+ :param _content_type: force content-type for the request.
450
+ :type _content_type: str, Optional
451
+ :param _headers: set to override the headers for a single
452
+ request; this effectively ignores the headers
453
+ in the spec for a single request.
454
+ :type _headers: dict, optional
455
+ :param _host_index: set to override the host_index for a single
456
+ request; this effectively ignores the host_index
457
+ in the spec for a single request.
458
+ :type _host_index: int, optional
459
+ :return: Returns the result object.
460
+ """ # noqa: E501
461
+
462
+ _param = self._get_fetch_scheduled_tweets_serialize(
463
+ path_query_id=path_query_id,
464
+ variables=variables,
465
+ _request_auth=_request_auth,
466
+ _content_type=_content_type,
467
+ _headers=_headers,
468
+ _host_index=_host_index
469
+ )
470
+
471
+ _response_types_map: Dict[str, Optional[str]] = {
472
+ '200': "FetchScheduledTweetsResponse",
473
+ }
474
+ response_data = self.api_client.call_api(
475
+ *_param,
476
+ _request_timeout=_request_timeout
477
+ )
478
+ response_data.read()
479
+ return self.api_client.response_deserialize(
480
+ response_data=response_data,
481
+ response_types_map=_response_types_map,
482
+ )
483
+
484
+
485
+ @validate_call
486
+ def get_fetch_scheduled_tweets_without_preload_content(
487
+ self,
488
+ path_query_id: StrictStr,
489
+ variables: StrictStr,
490
+ _request_timeout: Union[
491
+ None,
492
+ Annotated[StrictFloat, Field(gt=0)],
493
+ Tuple[
494
+ Annotated[StrictFloat, Field(gt=0)],
495
+ Annotated[StrictFloat, Field(gt=0)]
496
+ ]
497
+ ] = None,
498
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
499
+ _content_type: Optional[StrictStr] = None,
500
+ _headers: Optional[Dict[StrictStr, Any]] = None,
501
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
502
+ ) -> RESTResponseType:
503
+ """get_fetch_scheduled_tweets
504
+
505
+ get scheduled posts
506
+
507
+ :param path_query_id: (required)
508
+ :type path_query_id: str
509
+ :param variables: (required)
510
+ :type variables: str
511
+ :param _request_timeout: timeout setting for this request. If one
512
+ number provided, it will be total request
513
+ timeout. It can also be a pair (tuple) of
514
+ (connection, read) timeouts.
515
+ :type _request_timeout: int, tuple(int, int), optional
516
+ :param _request_auth: set to override the auth_settings for an a single
517
+ request; this effectively ignores the
518
+ authentication in the spec for a single request.
519
+ :type _request_auth: dict, optional
520
+ :param _content_type: force content-type for the request.
521
+ :type _content_type: str, Optional
522
+ :param _headers: set to override the headers for a single
523
+ request; this effectively ignores the headers
524
+ in the spec for a single request.
525
+ :type _headers: dict, optional
526
+ :param _host_index: set to override the host_index for a single
527
+ request; this effectively ignores the host_index
528
+ in the spec for a single request.
529
+ :type _host_index: int, optional
530
+ :return: Returns the result object.
531
+ """ # noqa: E501
532
+
533
+ _param = self._get_fetch_scheduled_tweets_serialize(
534
+ path_query_id=path_query_id,
535
+ variables=variables,
536
+ _request_auth=_request_auth,
537
+ _content_type=_content_type,
538
+ _headers=_headers,
539
+ _host_index=_host_index
540
+ )
541
+
542
+ _response_types_map: Dict[str, Optional[str]] = {
543
+ '200': "FetchScheduledTweetsResponse",
544
+ }
545
+ response_data = self.api_client.call_api(
546
+ *_param,
547
+ _request_timeout=_request_timeout
548
+ )
549
+ return response_data.response
550
+
551
+
552
+ def _get_fetch_scheduled_tweets_serialize(
553
+ self,
554
+ path_query_id,
555
+ variables,
556
+ _request_auth,
557
+ _content_type,
558
+ _headers,
559
+ _host_index,
560
+ ) -> RequestSerialized:
561
+
562
+ _host = None
563
+
564
+ _collection_formats: Dict[str, str] = {
565
+ }
566
+
567
+ _path_params: Dict[str, str] = {}
568
+ _query_params: List[Tuple[str, str]] = []
569
+ _header_params: Dict[str, Optional[str]] = _headers or {}
570
+ _form_params: List[Tuple[str, str]] = []
571
+ _files: Dict[
572
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
573
+ ] = {}
574
+ _body_params: Optional[bytes] = None
575
+
576
+ # process the path parameters
577
+ if path_query_id is not None:
578
+ _path_params['pathQueryId'] = path_query_id
579
+ # process the query parameters
580
+ if variables is not None:
581
+
582
+ _query_params.append(('variables', variables))
583
+
584
+ # process the header parameters
585
+ # process the form parameters
586
+ # process the body parameter
587
+
588
+
589
+ # set the HTTP header `Accept`
590
+ if 'Accept' not in _header_params:
591
+ _header_params['Accept'] = self.api_client.select_header_accept(
592
+ [
593
+ 'application/json'
594
+ ]
595
+ )
596
+
597
+
598
+ # authentication setting
599
+ _auth_settings: List[str] = [
600
+ 'Accept',
601
+ 'ClientLanguage',
602
+ 'Priority',
603
+ 'Referer',
604
+ 'SecFetchDest',
605
+ 'SecChUaPlatform',
606
+ 'SecFetchMode',
607
+ 'CsrfToken',
608
+ 'ClientUuid',
609
+ 'BearerAuth',
610
+ 'GuestToken',
611
+ 'SecChUa',
612
+ 'CookieGt0',
613
+ 'ClientTransactionId',
614
+ 'ActiveUser',
615
+ 'CookieCt0',
616
+ 'UserAgent',
617
+ 'AcceptLanguage',
618
+ 'SecFetchSite',
619
+ 'AuthType',
620
+ 'CookieAuthToken',
621
+ 'SecChUaMobile',
622
+ 'AcceptEncoding'
623
+ ]
624
+
625
+ return self.api_client.param_serialize(
626
+ method='GET',
627
+ resource_path='/graphql/{pathQueryId}/FetchScheduledTweets',
628
+ path_params=_path_params,
629
+ query_params=_query_params,
630
+ header_params=_header_params,
631
+ body=_body_params,
632
+ post_params=_form_params,
633
+ files=_files,
634
+ auth_settings=_auth_settings,
635
+ collection_formats=_collection_formats,
636
+ _host=_host,
637
+ _request_auth=_request_auth
638
+ )
639
+
640
+
641
+
642
+
40
643
  @validate_call
41
644
  def get_user_by_rest_id(
42
645
  self,
@@ -56,9 +659,327 @@ class UserApi:
56
659
  _headers: Optional[Dict[StrictStr, Any]] = None,
57
660
  _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
58
661
  ) -> UserResponse:
59
- """get_user_by_rest_id
662
+ """get_user_by_rest_id
663
+
664
+ get user by rest id
665
+
666
+ :param path_query_id: (required)
667
+ :type path_query_id: str
668
+ :param variables: (required)
669
+ :type variables: str
670
+ :param features: (required)
671
+ :type features: str
672
+ :param _request_timeout: timeout setting for this request. If one
673
+ number provided, it will be total request
674
+ timeout. It can also be a pair (tuple) of
675
+ (connection, read) timeouts.
676
+ :type _request_timeout: int, tuple(int, int), optional
677
+ :param _request_auth: set to override the auth_settings for an a single
678
+ request; this effectively ignores the
679
+ authentication in the spec for a single request.
680
+ :type _request_auth: dict, optional
681
+ :param _content_type: force content-type for the request.
682
+ :type _content_type: str, Optional
683
+ :param _headers: set to override the headers for a single
684
+ request; this effectively ignores the headers
685
+ in the spec for a single request.
686
+ :type _headers: dict, optional
687
+ :param _host_index: set to override the host_index for a single
688
+ request; this effectively ignores the host_index
689
+ in the spec for a single request.
690
+ :type _host_index: int, optional
691
+ :return: Returns the result object.
692
+ """ # noqa: E501
693
+
694
+ _param = self._get_user_by_rest_id_serialize(
695
+ path_query_id=path_query_id,
696
+ variables=variables,
697
+ features=features,
698
+ _request_auth=_request_auth,
699
+ _content_type=_content_type,
700
+ _headers=_headers,
701
+ _host_index=_host_index
702
+ )
703
+
704
+ _response_types_map: Dict[str, Optional[str]] = {
705
+ '200': "UserResponse",
706
+ }
707
+ response_data = self.api_client.call_api(
708
+ *_param,
709
+ _request_timeout=_request_timeout
710
+ )
711
+ response_data.read()
712
+ return self.api_client.response_deserialize(
713
+ response_data=response_data,
714
+ response_types_map=_response_types_map,
715
+ ).data
716
+
717
+
718
+ @validate_call
719
+ def get_user_by_rest_id_with_http_info(
720
+ self,
721
+ path_query_id: StrictStr,
722
+ variables: StrictStr,
723
+ features: StrictStr,
724
+ _request_timeout: Union[
725
+ None,
726
+ Annotated[StrictFloat, Field(gt=0)],
727
+ Tuple[
728
+ Annotated[StrictFloat, Field(gt=0)],
729
+ Annotated[StrictFloat, Field(gt=0)]
730
+ ]
731
+ ] = None,
732
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
733
+ _content_type: Optional[StrictStr] = None,
734
+ _headers: Optional[Dict[StrictStr, Any]] = None,
735
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
736
+ ) -> ApiResponse[UserResponse]:
737
+ """get_user_by_rest_id
738
+
739
+ get user by rest id
740
+
741
+ :param path_query_id: (required)
742
+ :type path_query_id: str
743
+ :param variables: (required)
744
+ :type variables: str
745
+ :param features: (required)
746
+ :type features: str
747
+ :param _request_timeout: timeout setting for this request. If one
748
+ number provided, it will be total request
749
+ timeout. It can also be a pair (tuple) of
750
+ (connection, read) timeouts.
751
+ :type _request_timeout: int, tuple(int, int), optional
752
+ :param _request_auth: set to override the auth_settings for an a single
753
+ request; this effectively ignores the
754
+ authentication in the spec for a single request.
755
+ :type _request_auth: dict, optional
756
+ :param _content_type: force content-type for the request.
757
+ :type _content_type: str, Optional
758
+ :param _headers: set to override the headers for a single
759
+ request; this effectively ignores the headers
760
+ in the spec for a single request.
761
+ :type _headers: dict, optional
762
+ :param _host_index: set to override the host_index for a single
763
+ request; this effectively ignores the host_index
764
+ in the spec for a single request.
765
+ :type _host_index: int, optional
766
+ :return: Returns the result object.
767
+ """ # noqa: E501
768
+
769
+ _param = self._get_user_by_rest_id_serialize(
770
+ path_query_id=path_query_id,
771
+ variables=variables,
772
+ features=features,
773
+ _request_auth=_request_auth,
774
+ _content_type=_content_type,
775
+ _headers=_headers,
776
+ _host_index=_host_index
777
+ )
778
+
779
+ _response_types_map: Dict[str, Optional[str]] = {
780
+ '200': "UserResponse",
781
+ }
782
+ response_data = self.api_client.call_api(
783
+ *_param,
784
+ _request_timeout=_request_timeout
785
+ )
786
+ response_data.read()
787
+ return self.api_client.response_deserialize(
788
+ response_data=response_data,
789
+ response_types_map=_response_types_map,
790
+ )
791
+
792
+
793
+ @validate_call
794
+ def get_user_by_rest_id_without_preload_content(
795
+ self,
796
+ path_query_id: StrictStr,
797
+ variables: StrictStr,
798
+ features: StrictStr,
799
+ _request_timeout: Union[
800
+ None,
801
+ Annotated[StrictFloat, Field(gt=0)],
802
+ Tuple[
803
+ Annotated[StrictFloat, Field(gt=0)],
804
+ Annotated[StrictFloat, Field(gt=0)]
805
+ ]
806
+ ] = None,
807
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
808
+ _content_type: Optional[StrictStr] = None,
809
+ _headers: Optional[Dict[StrictStr, Any]] = None,
810
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
811
+ ) -> RESTResponseType:
812
+ """get_user_by_rest_id
813
+
814
+ get user by rest id
815
+
816
+ :param path_query_id: (required)
817
+ :type path_query_id: str
818
+ :param variables: (required)
819
+ :type variables: str
820
+ :param features: (required)
821
+ :type features: str
822
+ :param _request_timeout: timeout setting for this request. If one
823
+ number provided, it will be total request
824
+ timeout. It can also be a pair (tuple) of
825
+ (connection, read) timeouts.
826
+ :type _request_timeout: int, tuple(int, int), optional
827
+ :param _request_auth: set to override the auth_settings for an a single
828
+ request; this effectively ignores the
829
+ authentication in the spec for a single request.
830
+ :type _request_auth: dict, optional
831
+ :param _content_type: force content-type for the request.
832
+ :type _content_type: str, Optional
833
+ :param _headers: set to override the headers for a single
834
+ request; this effectively ignores the headers
835
+ in the spec for a single request.
836
+ :type _headers: dict, optional
837
+ :param _host_index: set to override the host_index for a single
838
+ request; this effectively ignores the host_index
839
+ in the spec for a single request.
840
+ :type _host_index: int, optional
841
+ :return: Returns the result object.
842
+ """ # noqa: E501
843
+
844
+ _param = self._get_user_by_rest_id_serialize(
845
+ path_query_id=path_query_id,
846
+ variables=variables,
847
+ features=features,
848
+ _request_auth=_request_auth,
849
+ _content_type=_content_type,
850
+ _headers=_headers,
851
+ _host_index=_host_index
852
+ )
853
+
854
+ _response_types_map: Dict[str, Optional[str]] = {
855
+ '200': "UserResponse",
856
+ }
857
+ response_data = self.api_client.call_api(
858
+ *_param,
859
+ _request_timeout=_request_timeout
860
+ )
861
+ return response_data.response
862
+
863
+
864
+ def _get_user_by_rest_id_serialize(
865
+ self,
866
+ path_query_id,
867
+ variables,
868
+ features,
869
+ _request_auth,
870
+ _content_type,
871
+ _headers,
872
+ _host_index,
873
+ ) -> RequestSerialized:
874
+
875
+ _host = None
876
+
877
+ _collection_formats: Dict[str, str] = {
878
+ }
879
+
880
+ _path_params: Dict[str, str] = {}
881
+ _query_params: List[Tuple[str, str]] = []
882
+ _header_params: Dict[str, Optional[str]] = _headers or {}
883
+ _form_params: List[Tuple[str, str]] = []
884
+ _files: Dict[
885
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
886
+ ] = {}
887
+ _body_params: Optional[bytes] = None
888
+
889
+ # process the path parameters
890
+ if path_query_id is not None:
891
+ _path_params['pathQueryId'] = path_query_id
892
+ # process the query parameters
893
+ if variables is not None:
894
+
895
+ _query_params.append(('variables', variables))
896
+
897
+ if features is not None:
898
+
899
+ _query_params.append(('features', features))
900
+
901
+ # process the header parameters
902
+ # process the form parameters
903
+ # process the body parameter
904
+
905
+
906
+ # set the HTTP header `Accept`
907
+ if 'Accept' not in _header_params:
908
+ _header_params['Accept'] = self.api_client.select_header_accept(
909
+ [
910
+ 'application/json'
911
+ ]
912
+ )
913
+
914
+
915
+ # authentication setting
916
+ _auth_settings: List[str] = [
917
+ 'Accept',
918
+ 'ClientLanguage',
919
+ 'Priority',
920
+ 'Referer',
921
+ 'SecFetchDest',
922
+ 'SecChUaPlatform',
923
+ 'SecFetchMode',
924
+ 'CsrfToken',
925
+ 'ClientUuid',
926
+ 'BearerAuth',
927
+ 'GuestToken',
928
+ 'SecChUa',
929
+ 'CookieGt0',
930
+ 'ClientTransactionId',
931
+ 'ActiveUser',
932
+ 'CookieCt0',
933
+ 'UserAgent',
934
+ 'AcceptLanguage',
935
+ 'SecFetchSite',
936
+ 'AuthType',
937
+ 'CookieAuthToken',
938
+ 'SecChUaMobile',
939
+ 'AcceptEncoding'
940
+ ]
941
+
942
+ return self.api_client.param_serialize(
943
+ method='GET',
944
+ resource_path='/graphql/{pathQueryId}/UserByRestId',
945
+ path_params=_path_params,
946
+ query_params=_query_params,
947
+ header_params=_header_params,
948
+ body=_body_params,
949
+ post_params=_form_params,
950
+ files=_files,
951
+ auth_settings=_auth_settings,
952
+ collection_formats=_collection_formats,
953
+ _host=_host,
954
+ _request_auth=_request_auth
955
+ )
956
+
957
+
958
+
959
+
960
+ @validate_call
961
+ def get_user_by_screen_name(
962
+ self,
963
+ path_query_id: StrictStr,
964
+ variables: StrictStr,
965
+ features: StrictStr,
966
+ field_toggles: StrictStr,
967
+ _request_timeout: Union[
968
+ None,
969
+ Annotated[StrictFloat, Field(gt=0)],
970
+ Tuple[
971
+ Annotated[StrictFloat, Field(gt=0)],
972
+ Annotated[StrictFloat, Field(gt=0)]
973
+ ]
974
+ ] = None,
975
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
976
+ _content_type: Optional[StrictStr] = None,
977
+ _headers: Optional[Dict[StrictStr, Any]] = None,
978
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
979
+ ) -> UserResponse:
980
+ """get_user_by_screen_name
60
981
 
61
- get user by rest id
982
+ get user by screen name
62
983
 
63
984
  :param path_query_id: (required)
64
985
  :type path_query_id: str
@@ -66,6 +987,8 @@ class UserApi:
66
987
  :type variables: str
67
988
  :param features: (required)
68
989
  :type features: str
990
+ :param field_toggles: (required)
991
+ :type field_toggles: str
69
992
  :param _request_timeout: timeout setting for this request. If one
70
993
  number provided, it will be total request
71
994
  timeout. It can also be a pair (tuple) of
@@ -88,10 +1011,11 @@ class UserApi:
88
1011
  :return: Returns the result object.
89
1012
  """ # noqa: E501
90
1013
 
91
- _param = self._get_user_by_rest_id_serialize(
1014
+ _param = self._get_user_by_screen_name_serialize(
92
1015
  path_query_id=path_query_id,
93
1016
  variables=variables,
94
1017
  features=features,
1018
+ field_toggles=field_toggles,
95
1019
  _request_auth=_request_auth,
96
1020
  _content_type=_content_type,
97
1021
  _headers=_headers,
@@ -113,11 +1037,12 @@ class UserApi:
113
1037
 
114
1038
 
115
1039
  @validate_call
116
- def get_user_by_rest_id_with_http_info(
1040
+ def get_user_by_screen_name_with_http_info(
117
1041
  self,
118
1042
  path_query_id: StrictStr,
119
1043
  variables: StrictStr,
120
1044
  features: StrictStr,
1045
+ field_toggles: StrictStr,
121
1046
  _request_timeout: Union[
122
1047
  None,
123
1048
  Annotated[StrictFloat, Field(gt=0)],
@@ -131,9 +1056,9 @@ class UserApi:
131
1056
  _headers: Optional[Dict[StrictStr, Any]] = None,
132
1057
  _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
133
1058
  ) -> ApiResponse[UserResponse]:
134
- """get_user_by_rest_id
1059
+ """get_user_by_screen_name
135
1060
 
136
- get user by rest id
1061
+ get user by screen name
137
1062
 
138
1063
  :param path_query_id: (required)
139
1064
  :type path_query_id: str
@@ -141,6 +1066,8 @@ class UserApi:
141
1066
  :type variables: str
142
1067
  :param features: (required)
143
1068
  :type features: str
1069
+ :param field_toggles: (required)
1070
+ :type field_toggles: str
144
1071
  :param _request_timeout: timeout setting for this request. If one
145
1072
  number provided, it will be total request
146
1073
  timeout. It can also be a pair (tuple) of
@@ -163,10 +1090,11 @@ class UserApi:
163
1090
  :return: Returns the result object.
164
1091
  """ # noqa: E501
165
1092
 
166
- _param = self._get_user_by_rest_id_serialize(
1093
+ _param = self._get_user_by_screen_name_serialize(
167
1094
  path_query_id=path_query_id,
168
1095
  variables=variables,
169
1096
  features=features,
1097
+ field_toggles=field_toggles,
170
1098
  _request_auth=_request_auth,
171
1099
  _content_type=_content_type,
172
1100
  _headers=_headers,
@@ -188,11 +1116,12 @@ class UserApi:
188
1116
 
189
1117
 
190
1118
  @validate_call
191
- def get_user_by_rest_id_without_preload_content(
1119
+ def get_user_by_screen_name_without_preload_content(
192
1120
  self,
193
1121
  path_query_id: StrictStr,
194
1122
  variables: StrictStr,
195
1123
  features: StrictStr,
1124
+ field_toggles: StrictStr,
196
1125
  _request_timeout: Union[
197
1126
  None,
198
1127
  Annotated[StrictFloat, Field(gt=0)],
@@ -206,9 +1135,9 @@ class UserApi:
206
1135
  _headers: Optional[Dict[StrictStr, Any]] = None,
207
1136
  _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
208
1137
  ) -> RESTResponseType:
209
- """get_user_by_rest_id
1138
+ """get_user_by_screen_name
210
1139
 
211
- get user by rest id
1140
+ get user by screen name
212
1141
 
213
1142
  :param path_query_id: (required)
214
1143
  :type path_query_id: str
@@ -216,6 +1145,8 @@ class UserApi:
216
1145
  :type variables: str
217
1146
  :param features: (required)
218
1147
  :type features: str
1148
+ :param field_toggles: (required)
1149
+ :type field_toggles: str
219
1150
  :param _request_timeout: timeout setting for this request. If one
220
1151
  number provided, it will be total request
221
1152
  timeout. It can also be a pair (tuple) of
@@ -238,10 +1169,11 @@ class UserApi:
238
1169
  :return: Returns the result object.
239
1170
  """ # noqa: E501
240
1171
 
241
- _param = self._get_user_by_rest_id_serialize(
1172
+ _param = self._get_user_by_screen_name_serialize(
242
1173
  path_query_id=path_query_id,
243
1174
  variables=variables,
244
1175
  features=features,
1176
+ field_toggles=field_toggles,
245
1177
  _request_auth=_request_auth,
246
1178
  _content_type=_content_type,
247
1179
  _headers=_headers,
@@ -258,11 +1190,12 @@ class UserApi:
258
1190
  return response_data.response
259
1191
 
260
1192
 
261
- def _get_user_by_rest_id_serialize(
1193
+ def _get_user_by_screen_name_serialize(
262
1194
  self,
263
1195
  path_query_id,
264
1196
  variables,
265
1197
  features,
1198
+ field_toggles,
266
1199
  _request_auth,
267
1200
  _content_type,
268
1201
  _headers,
@@ -295,6 +1228,10 @@ class UserApi:
295
1228
 
296
1229
  _query_params.append(('features', features))
297
1230
 
1231
+ if field_toggles is not None:
1232
+
1233
+ _query_params.append(('fieldToggles', field_toggles))
1234
+
298
1235
  # process the header parameters
299
1236
  # process the form parameters
300
1237
  # process the body parameter
@@ -338,7 +1275,7 @@ class UserApi:
338
1275
 
339
1276
  return self.api_client.param_serialize(
340
1277
  method='GET',
341
- resource_path='/graphql/{pathQueryId}/UserByRestId',
1278
+ resource_path='/graphql/{pathQueryId}/UserByScreenName',
342
1279
  path_params=_path_params,
343
1280
  query_params=_query_params,
344
1281
  header_params=_header_params,
@@ -355,12 +1292,10 @@ class UserApi:
355
1292
 
356
1293
 
357
1294
  @validate_call
358
- def get_user_by_screen_name(
1295
+ def get_viewer_badge_counts(
359
1296
  self,
360
1297
  path_query_id: StrictStr,
361
1298
  variables: StrictStr,
362
- features: StrictStr,
363
- field_toggles: StrictStr,
364
1299
  _request_timeout: Union[
365
1300
  None,
366
1301
  Annotated[StrictFloat, Field(gt=0)],
@@ -373,19 +1308,15 @@ class UserApi:
373
1308
  _content_type: Optional[StrictStr] = None,
374
1309
  _headers: Optional[Dict[StrictStr, Any]] = None,
375
1310
  _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
376
- ) -> UserResponse:
377
- """get_user_by_screen_name
1311
+ ) -> ViewerBadgeCountsResponse:
1312
+ """get_viewer_badge_counts
378
1313
 
379
- get user by screen name
1314
+ get the unread badge counts of the viewer
380
1315
 
381
1316
  :param path_query_id: (required)
382
1317
  :type path_query_id: str
383
1318
  :param variables: (required)
384
1319
  :type variables: str
385
- :param features: (required)
386
- :type features: str
387
- :param field_toggles: (required)
388
- :type field_toggles: str
389
1320
  :param _request_timeout: timeout setting for this request. If one
390
1321
  number provided, it will be total request
391
1322
  timeout. It can also be a pair (tuple) of
@@ -408,11 +1339,9 @@ class UserApi:
408
1339
  :return: Returns the result object.
409
1340
  """ # noqa: E501
410
1341
 
411
- _param = self._get_user_by_screen_name_serialize(
1342
+ _param = self._get_viewer_badge_counts_serialize(
412
1343
  path_query_id=path_query_id,
413
1344
  variables=variables,
414
- features=features,
415
- field_toggles=field_toggles,
416
1345
  _request_auth=_request_auth,
417
1346
  _content_type=_content_type,
418
1347
  _headers=_headers,
@@ -420,7 +1349,7 @@ class UserApi:
420
1349
  )
421
1350
 
422
1351
  _response_types_map: Dict[str, Optional[str]] = {
423
- '200': "UserResponse",
1352
+ '200': "ViewerBadgeCountsResponse",
424
1353
  }
425
1354
  response_data = self.api_client.call_api(
426
1355
  *_param,
@@ -434,12 +1363,10 @@ class UserApi:
434
1363
 
435
1364
 
436
1365
  @validate_call
437
- def get_user_by_screen_name_with_http_info(
1366
+ def get_viewer_badge_counts_with_http_info(
438
1367
  self,
439
1368
  path_query_id: StrictStr,
440
1369
  variables: StrictStr,
441
- features: StrictStr,
442
- field_toggles: StrictStr,
443
1370
  _request_timeout: Union[
444
1371
  None,
445
1372
  Annotated[StrictFloat, Field(gt=0)],
@@ -452,19 +1379,15 @@ class UserApi:
452
1379
  _content_type: Optional[StrictStr] = None,
453
1380
  _headers: Optional[Dict[StrictStr, Any]] = None,
454
1381
  _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
455
- ) -> ApiResponse[UserResponse]:
456
- """get_user_by_screen_name
1382
+ ) -> ApiResponse[ViewerBadgeCountsResponse]:
1383
+ """get_viewer_badge_counts
457
1384
 
458
- get user by screen name
1385
+ get the unread badge counts of the viewer
459
1386
 
460
1387
  :param path_query_id: (required)
461
1388
  :type path_query_id: str
462
1389
  :param variables: (required)
463
1390
  :type variables: str
464
- :param features: (required)
465
- :type features: str
466
- :param field_toggles: (required)
467
- :type field_toggles: str
468
1391
  :param _request_timeout: timeout setting for this request. If one
469
1392
  number provided, it will be total request
470
1393
  timeout. It can also be a pair (tuple) of
@@ -487,11 +1410,9 @@ class UserApi:
487
1410
  :return: Returns the result object.
488
1411
  """ # noqa: E501
489
1412
 
490
- _param = self._get_user_by_screen_name_serialize(
1413
+ _param = self._get_viewer_badge_counts_serialize(
491
1414
  path_query_id=path_query_id,
492
1415
  variables=variables,
493
- features=features,
494
- field_toggles=field_toggles,
495
1416
  _request_auth=_request_auth,
496
1417
  _content_type=_content_type,
497
1418
  _headers=_headers,
@@ -499,7 +1420,7 @@ class UserApi:
499
1420
  )
500
1421
 
501
1422
  _response_types_map: Dict[str, Optional[str]] = {
502
- '200': "UserResponse",
1423
+ '200': "ViewerBadgeCountsResponse",
503
1424
  }
504
1425
  response_data = self.api_client.call_api(
505
1426
  *_param,
@@ -513,12 +1434,10 @@ class UserApi:
513
1434
 
514
1435
 
515
1436
  @validate_call
516
- def get_user_by_screen_name_without_preload_content(
1437
+ def get_viewer_badge_counts_without_preload_content(
517
1438
  self,
518
1439
  path_query_id: StrictStr,
519
1440
  variables: StrictStr,
520
- features: StrictStr,
521
- field_toggles: StrictStr,
522
1441
  _request_timeout: Union[
523
1442
  None,
524
1443
  Annotated[StrictFloat, Field(gt=0)],
@@ -532,18 +1451,14 @@ class UserApi:
532
1451
  _headers: Optional[Dict[StrictStr, Any]] = None,
533
1452
  _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
534
1453
  ) -> RESTResponseType:
535
- """get_user_by_screen_name
1454
+ """get_viewer_badge_counts
536
1455
 
537
- get user by screen name
1456
+ get the unread badge counts of the viewer
538
1457
 
539
1458
  :param path_query_id: (required)
540
1459
  :type path_query_id: str
541
1460
  :param variables: (required)
542
1461
  :type variables: str
543
- :param features: (required)
544
- :type features: str
545
- :param field_toggles: (required)
546
- :type field_toggles: str
547
1462
  :param _request_timeout: timeout setting for this request. If one
548
1463
  number provided, it will be total request
549
1464
  timeout. It can also be a pair (tuple) of
@@ -566,11 +1481,9 @@ class UserApi:
566
1481
  :return: Returns the result object.
567
1482
  """ # noqa: E501
568
1483
 
569
- _param = self._get_user_by_screen_name_serialize(
1484
+ _param = self._get_viewer_badge_counts_serialize(
570
1485
  path_query_id=path_query_id,
571
1486
  variables=variables,
572
- features=features,
573
- field_toggles=field_toggles,
574
1487
  _request_auth=_request_auth,
575
1488
  _content_type=_content_type,
576
1489
  _headers=_headers,
@@ -578,7 +1491,7 @@ class UserApi:
578
1491
  )
579
1492
 
580
1493
  _response_types_map: Dict[str, Optional[str]] = {
581
- '200': "UserResponse",
1494
+ '200': "ViewerBadgeCountsResponse",
582
1495
  }
583
1496
  response_data = self.api_client.call_api(
584
1497
  *_param,
@@ -587,12 +1500,10 @@ class UserApi:
587
1500
  return response_data.response
588
1501
 
589
1502
 
590
- def _get_user_by_screen_name_serialize(
1503
+ def _get_viewer_badge_counts_serialize(
591
1504
  self,
592
1505
  path_query_id,
593
1506
  variables,
594
- features,
595
- field_toggles,
596
1507
  _request_auth,
597
1508
  _content_type,
598
1509
  _headers,
@@ -621,14 +1532,6 @@ class UserApi:
621
1532
 
622
1533
  _query_params.append(('variables', variables))
623
1534
 
624
- if features is not None:
625
-
626
- _query_params.append(('features', features))
627
-
628
- if field_toggles is not None:
629
-
630
- _query_params.append(('fieldToggles', field_toggles))
631
-
632
1535
  # process the header parameters
633
1536
  # process the form parameters
634
1537
  # process the body parameter
@@ -672,7 +1575,7 @@ class UserApi:
672
1575
 
673
1576
  return self.api_client.param_serialize(
674
1577
  method='GET',
675
- resource_path='/graphql/{pathQueryId}/UserByScreenName',
1578
+ resource_path='/graphql/{pathQueryId}/ViewerBadgeCounts',
676
1579
  path_params=_path_params,
677
1580
  query_params=_query_params,
678
1581
  header_params=_header_params,