twitter-openapi-typescript-generated 0.0.28 → 0.0.29
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.
- package/README.md +2 -2
- package/dist/apis/DefaultApi.d.ts.map +1 -1
- package/dist/apis/DefaultApi.js +180 -164
- package/dist/apis/DefaultApi.js.map +1 -1
- package/dist/apis/OtherApi.d.ts.map +1 -1
- package/dist/apis/OtherApi.js +90 -82
- package/dist/apis/OtherApi.js.map +1 -1
- package/dist/apis/PostApi.d.ts.map +1 -1
- package/dist/apis/PostApi.js +720 -656
- package/dist/apis/PostApi.js.map +1 -1
- package/dist/apis/TweetApi.d.ts.map +1 -1
- package/dist/apis/TweetApi.js +990 -902
- package/dist/apis/TweetApi.js.map +1 -1
- package/dist/apis/UserApi.d.ts.map +1 -1
- package/dist/apis/UserApi.js +180 -164
- package/dist/apis/UserApi.js.map +1 -1
- package/dist/apis/UserListApi.d.ts.map +1 -1
- package/dist/apis/UserListApi.js +450 -410
- package/dist/apis/UserListApi.js.map +1 -1
- package/dist/apis/UsersApi.d.ts.map +1 -1
- package/dist/apis/UsersApi.js +90 -82
- package/dist/apis/UsersApi.js.map +1 -1
- package/dist/apis/V11GetApi.d.ts.map +1 -1
- package/dist/apis/V11GetApi.js +180 -164
- package/dist/apis/V11GetApi.js.map +1 -1
- package/dist/apis/V11PostApi.d.ts.map +1 -1
- package/dist/apis/V11PostApi.js +178 -162
- package/dist/apis/V11PostApi.js.map +1 -1
- package/dist/apis/V20GetApi.d.ts.map +1 -1
- package/dist/apis/V20GetApi.js +90 -82
- package/dist/apis/V20GetApi.js.map +1 -1
- package/dist/models/BookmarksResponse.d.ts +3 -2
- package/dist/models/BookmarksResponse.d.ts.map +1 -1
- package/dist/models/BookmarksResponse.js +3 -2
- package/dist/models/BookmarksResponse.js.map +1 -1
- package/dist/models/CreateBookmarkResponse.d.ts +3 -2
- package/dist/models/CreateBookmarkResponse.d.ts.map +1 -1
- package/dist/models/CreateBookmarkResponse.js +3 -2
- package/dist/models/CreateBookmarkResponse.js.map +1 -1
- package/dist/models/CreateRetweetResponse.d.ts +3 -2
- package/dist/models/CreateRetweetResponse.d.ts.map +1 -1
- package/dist/models/CreateRetweetResponse.js +3 -2
- package/dist/models/CreateRetweetResponse.js.map +1 -1
- package/dist/models/CreateTweetResponse.d.ts +3 -2
- package/dist/models/CreateTweetResponse.d.ts.map +1 -1
- package/dist/models/CreateTweetResponse.js +3 -2
- package/dist/models/CreateTweetResponse.js.map +1 -1
- package/dist/models/DeleteBookmarkResponse.d.ts +3 -2
- package/dist/models/DeleteBookmarkResponse.d.ts.map +1 -1
- package/dist/models/DeleteBookmarkResponse.js +3 -2
- package/dist/models/DeleteBookmarkResponse.js.map +1 -1
- package/dist/models/DeleteRetweetResponse.d.ts +3 -2
- package/dist/models/DeleteRetweetResponse.d.ts.map +1 -1
- package/dist/models/DeleteRetweetResponse.js +3 -2
- package/dist/models/DeleteRetweetResponse.js.map +1 -1
- package/dist/models/DeleteTweetResponse.d.ts +3 -2
- package/dist/models/DeleteTweetResponse.d.ts.map +1 -1
- package/dist/models/DeleteTweetResponse.js +3 -2
- package/dist/models/DeleteTweetResponse.js.map +1 -1
- package/dist/models/{ModelError.d.ts → ErrorResponse.d.ts} +18 -18
- package/dist/models/ErrorResponse.d.ts.map +1 -0
- package/dist/models/{ModelError.js → ErrorResponse.js} +12 -12
- package/dist/models/ErrorResponse.js.map +1 -0
- package/dist/models/FavoriteTweetResponse.d.ts +3 -2
- package/dist/models/FavoriteTweetResponse.d.ts.map +1 -1
- package/dist/models/FavoriteTweetResponse.js +3 -2
- package/dist/models/FavoriteTweetResponse.js.map +1 -1
- package/dist/models/FollowResponse.d.ts +3 -2
- package/dist/models/FollowResponse.d.ts.map +1 -1
- package/dist/models/FollowResponse.js +3 -2
- package/dist/models/FollowResponse.js.map +1 -1
- package/dist/models/ListLatestTweetsTimelineResponse.d.ts +3 -2
- package/dist/models/ListLatestTweetsTimelineResponse.d.ts.map +1 -1
- package/dist/models/ListLatestTweetsTimelineResponse.js +3 -2
- package/dist/models/ListLatestTweetsTimelineResponse.js.map +1 -1
- package/dist/models/ProfileResponse.d.ts +3 -2
- package/dist/models/ProfileResponse.d.ts.map +1 -1
- package/dist/models/ProfileResponse.js +3 -2
- package/dist/models/ProfileResponse.js.map +1 -1
- package/dist/models/SearchTimelineResponse.d.ts +3 -2
- package/dist/models/SearchTimelineResponse.d.ts.map +1 -1
- package/dist/models/SearchTimelineResponse.js +3 -2
- package/dist/models/SearchTimelineResponse.js.map +1 -1
- package/dist/models/TimelineResponse.d.ts +3 -2
- package/dist/models/TimelineResponse.d.ts.map +1 -1
- package/dist/models/TimelineResponse.js +3 -2
- package/dist/models/TimelineResponse.js.map +1 -1
- package/dist/models/TweetDetailResponse.d.ts +3 -2
- package/dist/models/TweetDetailResponse.d.ts.map +1 -1
- package/dist/models/TweetDetailResponse.js +3 -2
- package/dist/models/TweetDetailResponse.js.map +1 -1
- package/dist/models/TweetFavoritersResponse.d.ts +3 -2
- package/dist/models/TweetFavoritersResponse.d.ts.map +1 -1
- package/dist/models/TweetFavoritersResponse.js +3 -2
- package/dist/models/TweetFavoritersResponse.js.map +1 -1
- package/dist/models/TweetResultByRestIdResponse.d.ts +3 -2
- package/dist/models/TweetResultByRestIdResponse.d.ts.map +1 -1
- package/dist/models/TweetResultByRestIdResponse.js +3 -2
- package/dist/models/TweetResultByRestIdResponse.js.map +1 -1
- package/dist/models/TweetRetweetersResponse.d.ts +3 -2
- package/dist/models/TweetRetweetersResponse.d.ts.map +1 -1
- package/dist/models/TweetRetweetersResponse.js +3 -2
- package/dist/models/TweetRetweetersResponse.js.map +1 -1
- package/dist/models/UnfavoriteTweetResponse.d.ts +3 -2
- package/dist/models/UnfavoriteTweetResponse.d.ts.map +1 -1
- package/dist/models/UnfavoriteTweetResponse.js +3 -2
- package/dist/models/UnfavoriteTweetResponse.js.map +1 -1
- package/dist/models/UserHighlightsTweetsResponse.d.ts +3 -2
- package/dist/models/UserHighlightsTweetsResponse.d.ts.map +1 -1
- package/dist/models/UserHighlightsTweetsResponse.js +3 -2
- package/dist/models/UserHighlightsTweetsResponse.js.map +1 -1
- package/dist/models/UserResponse.d.ts +3 -2
- package/dist/models/UserResponse.d.ts.map +1 -1
- package/dist/models/UserResponse.js +3 -2
- package/dist/models/UserResponse.js.map +1 -1
- package/dist/models/UserTweetsResponse.d.ts +3 -2
- package/dist/models/UserTweetsResponse.d.ts.map +1 -1
- package/dist/models/UserTweetsResponse.js +3 -2
- package/dist/models/UserTweetsResponse.js.map +1 -1
- package/dist/models/UsersResponse.d.ts +3 -2
- package/dist/models/UsersResponse.d.ts.map +1 -1
- package/dist/models/UsersResponse.js +3 -2
- package/dist/models/UsersResponse.js.map +1 -1
- package/dist/models/index.d.ts +1 -1
- package/dist/models/index.d.ts.map +1 -1
- package/dist/models/index.js +1 -1
- package/dist/models/index.js.map +1 -1
- package/package.json +1 -1
- package/dist/models/ModelError.d.ts.map +0 -1
- package/dist/models/ModelError.js.map +0 -1
package/dist/apis/PostApi.js
CHANGED
|
@@ -80,9 +80,9 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
80
80
|
*/
|
|
81
81
|
PostApi.prototype.postCreateBookmarkRaw = function (requestParameters, initOverrides) {
|
|
82
82
|
return __awaiter(this, void 0, void 0, function () {
|
|
83
|
-
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r,
|
|
84
|
-
return __generator(this, function (
|
|
85
|
-
switch (
|
|
83
|
+
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, token, tokenString, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, response;
|
|
84
|
+
return __generator(this, function (_14) {
|
|
85
|
+
switch (_14.label) {
|
|
86
86
|
case 0:
|
|
87
87
|
if (requestParameters['pathQueryId'] == null) {
|
|
88
88
|
throw new runtime.RequiredError('pathQueryId', 'Required parameter "pathQueryId" was null or undefined when calling postCreateBookmark().');
|
|
@@ -98,163 +98,171 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
98
98
|
_b = "Accept";
|
|
99
99
|
return [4 /*yield*/, this.configuration.apiKey("Accept")];
|
|
100
100
|
case 1:
|
|
101
|
-
_a[_b] =
|
|
102
|
-
|
|
101
|
+
_a[_b] = _14.sent(); // Accept authentication
|
|
102
|
+
_14.label = 2;
|
|
103
103
|
case 2:
|
|
104
104
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 4];
|
|
105
105
|
_c = headerParameters;
|
|
106
106
|
_d = "x-twitter-client-language";
|
|
107
107
|
return [4 /*yield*/, this.configuration.apiKey("x-twitter-client-language")];
|
|
108
108
|
case 3:
|
|
109
|
-
_c[_d] =
|
|
110
|
-
|
|
109
|
+
_c[_d] = _14.sent(); // ClientLanguage authentication
|
|
110
|
+
_14.label = 4;
|
|
111
111
|
case 4:
|
|
112
112
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 6];
|
|
113
113
|
_e = headerParameters;
|
|
114
|
-
_f = "
|
|
115
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
114
|
+
_f = "Priority";
|
|
115
|
+
return [4 /*yield*/, this.configuration.apiKey("Priority")];
|
|
116
116
|
case 5:
|
|
117
|
-
_e[_f] =
|
|
118
|
-
|
|
117
|
+
_e[_f] = _14.sent(); // Priority authentication
|
|
118
|
+
_14.label = 6;
|
|
119
119
|
case 6:
|
|
120
120
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 8];
|
|
121
121
|
_g = headerParameters;
|
|
122
|
-
_h = "
|
|
123
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
122
|
+
_h = "Referer";
|
|
123
|
+
return [4 /*yield*/, this.configuration.apiKey("Referer")];
|
|
124
124
|
case 7:
|
|
125
|
-
_g[_h] =
|
|
126
|
-
|
|
125
|
+
_g[_h] = _14.sent(); // Referer authentication
|
|
126
|
+
_14.label = 8;
|
|
127
127
|
case 8:
|
|
128
128
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 10];
|
|
129
129
|
_j = headerParameters;
|
|
130
|
-
_k = "Sec-
|
|
131
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
130
|
+
_k = "Sec-Fetch-Dest";
|
|
131
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Dest")];
|
|
132
132
|
case 9:
|
|
133
|
-
_j[_k] =
|
|
134
|
-
|
|
133
|
+
_j[_k] = _14.sent(); // SecFetchDest authentication
|
|
134
|
+
_14.label = 10;
|
|
135
135
|
case 10:
|
|
136
136
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 12];
|
|
137
137
|
_l = headerParameters;
|
|
138
|
-
_m = "Sec-
|
|
139
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
138
|
+
_m = "Sec-Ch-Ua-Platform";
|
|
139
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Platform")];
|
|
140
140
|
case 11:
|
|
141
|
-
_l[_m] =
|
|
142
|
-
|
|
141
|
+
_l[_m] = _14.sent(); // SecChUaPlatform authentication
|
|
142
|
+
_14.label = 12;
|
|
143
143
|
case 12:
|
|
144
144
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 14];
|
|
145
145
|
_o = headerParameters;
|
|
146
|
-
_p = "
|
|
147
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
146
|
+
_p = "Sec-Fetch-Mode";
|
|
147
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Mode")];
|
|
148
148
|
case 13:
|
|
149
|
-
_o[_p] =
|
|
150
|
-
|
|
149
|
+
_o[_p] = _14.sent(); // SecFetchMode authentication
|
|
150
|
+
_14.label = 14;
|
|
151
151
|
case 14:
|
|
152
152
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 16];
|
|
153
153
|
_q = headerParameters;
|
|
154
|
-
_r = "x-
|
|
155
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
154
|
+
_r = "x-csrf-token";
|
|
155
|
+
return [4 /*yield*/, this.configuration.apiKey("x-csrf-token")];
|
|
156
156
|
case 15:
|
|
157
|
-
_q[_r] =
|
|
158
|
-
|
|
157
|
+
_q[_r] = _14.sent(); // CsrfToken authentication
|
|
158
|
+
_14.label = 16;
|
|
159
159
|
case 16:
|
|
160
|
-
if (!(this.configuration && this.configuration.
|
|
160
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 18];
|
|
161
|
+
_s = headerParameters;
|
|
162
|
+
_t = "x-client-uuid";
|
|
163
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-uuid")];
|
|
164
|
+
case 17:
|
|
165
|
+
_s[_t] = _14.sent(); // ClientUuid authentication
|
|
166
|
+
_14.label = 18;
|
|
167
|
+
case 18:
|
|
168
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 20];
|
|
161
169
|
token = this.configuration.accessToken;
|
|
162
170
|
return [4 /*yield*/, token("BearerAuth", [])];
|
|
163
|
-
case
|
|
164
|
-
tokenString =
|
|
171
|
+
case 19:
|
|
172
|
+
tokenString = _14.sent();
|
|
165
173
|
if (tokenString) {
|
|
166
174
|
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
167
175
|
}
|
|
168
|
-
|
|
169
|
-
case 18:
|
|
170
|
-
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 20];
|
|
171
|
-
_s = headerParameters;
|
|
172
|
-
_t = "x-guest-token";
|
|
173
|
-
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
174
|
-
case 19:
|
|
175
|
-
_s[_t] = _12.sent(); // GuestToken authentication
|
|
176
|
-
_12.label = 20;
|
|
176
|
+
_14.label = 20;
|
|
177
177
|
case 20:
|
|
178
178
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 22];
|
|
179
179
|
_u = headerParameters;
|
|
180
|
-
_v = "
|
|
181
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
180
|
+
_v = "x-guest-token";
|
|
181
|
+
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
182
182
|
case 21:
|
|
183
|
-
_u[_v] =
|
|
184
|
-
|
|
183
|
+
_u[_v] = _14.sent(); // GuestToken authentication
|
|
184
|
+
_14.label = 22;
|
|
185
185
|
case 22:
|
|
186
186
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 24];
|
|
187
187
|
_w = headerParameters;
|
|
188
|
-
_x = "
|
|
189
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
188
|
+
_x = "Sec-Ch-Ua";
|
|
189
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua")];
|
|
190
190
|
case 23:
|
|
191
|
-
_w[_x] =
|
|
192
|
-
|
|
191
|
+
_w[_x] = _14.sent(); // SecChUa authentication
|
|
192
|
+
_14.label = 24;
|
|
193
193
|
case 24:
|
|
194
194
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 26];
|
|
195
195
|
_y = headerParameters;
|
|
196
|
-
_z = "x-
|
|
197
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
196
|
+
_z = "x-client-transaction-id";
|
|
197
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-transaction-id")];
|
|
198
198
|
case 25:
|
|
199
|
-
_y[_z] =
|
|
200
|
-
|
|
199
|
+
_y[_z] = _14.sent(); // ClientTransactionId authentication
|
|
200
|
+
_14.label = 26;
|
|
201
201
|
case 26:
|
|
202
202
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 28];
|
|
203
203
|
_0 = headerParameters;
|
|
204
|
-
_1 = "user
|
|
205
|
-
return [4 /*yield*/, this.configuration.apiKey("user
|
|
204
|
+
_1 = "x-twitter-active-user";
|
|
205
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-active-user")];
|
|
206
206
|
case 27:
|
|
207
|
-
_0[_1] =
|
|
208
|
-
|
|
207
|
+
_0[_1] = _14.sent(); // ActiveUser authentication
|
|
208
|
+
_14.label = 28;
|
|
209
209
|
case 28:
|
|
210
210
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 30];
|
|
211
211
|
_2 = headerParameters;
|
|
212
|
-
_3 = "
|
|
213
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
212
|
+
_3 = "user-agent";
|
|
213
|
+
return [4 /*yield*/, this.configuration.apiKey("user-agent")];
|
|
214
214
|
case 29:
|
|
215
|
-
_2[_3] =
|
|
216
|
-
|
|
215
|
+
_2[_3] = _14.sent(); // UserAgent authentication
|
|
216
|
+
_14.label = 30;
|
|
217
217
|
case 30:
|
|
218
218
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 32];
|
|
219
219
|
_4 = headerParameters;
|
|
220
|
-
_5 = "
|
|
221
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
220
|
+
_5 = "Accept-Language";
|
|
221
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Language")];
|
|
222
222
|
case 31:
|
|
223
|
-
_4[_5] =
|
|
224
|
-
|
|
223
|
+
_4[_5] = _14.sent(); // AcceptLanguage authentication
|
|
224
|
+
_14.label = 32;
|
|
225
225
|
case 32:
|
|
226
226
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 34];
|
|
227
227
|
_6 = headerParameters;
|
|
228
|
-
_7 = "
|
|
229
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
228
|
+
_7 = "Sec-Fetch-Site";
|
|
229
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Site")];
|
|
230
230
|
case 33:
|
|
231
|
-
_6[_7] =
|
|
232
|
-
|
|
231
|
+
_6[_7] = _14.sent(); // SecFetchSite authentication
|
|
232
|
+
_14.label = 34;
|
|
233
233
|
case 34:
|
|
234
234
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 36];
|
|
235
235
|
_8 = headerParameters;
|
|
236
|
-
_9 = "
|
|
237
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
236
|
+
_9 = "x-twitter-auth-type";
|
|
237
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-auth-type")];
|
|
238
238
|
case 35:
|
|
239
|
-
_8[_9] =
|
|
240
|
-
|
|
239
|
+
_8[_9] = _14.sent(); // AuthType authentication
|
|
240
|
+
_14.label = 36;
|
|
241
241
|
case 36:
|
|
242
242
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 38];
|
|
243
243
|
_10 = headerParameters;
|
|
244
|
-
_11 = "
|
|
245
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
244
|
+
_11 = "Sec-Ch-Ua-Mobile";
|
|
245
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Mobile")];
|
|
246
246
|
case 37:
|
|
247
|
-
_10[_11] =
|
|
248
|
-
|
|
249
|
-
case 38:
|
|
247
|
+
_10[_11] = _14.sent(); // SecChUaMobile authentication
|
|
248
|
+
_14.label = 38;
|
|
249
|
+
case 38:
|
|
250
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 40];
|
|
251
|
+
_12 = headerParameters;
|
|
252
|
+
_13 = "Accept-Encoding";
|
|
253
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Encoding")];
|
|
254
|
+
case 39:
|
|
255
|
+
_12[_13] = _14.sent(); // AcceptEncoding authentication
|
|
256
|
+
_14.label = 40;
|
|
257
|
+
case 40: return [4 /*yield*/, this.request({
|
|
250
258
|
path: "/graphql/{pathQueryId}/CreateBookmark".replace("{".concat("pathQueryId", "}"), encodeURIComponent(String(requestParameters['pathQueryId']))),
|
|
251
259
|
method: 'POST',
|
|
252
260
|
headers: headerParameters,
|
|
253
261
|
query: queryParameters,
|
|
254
262
|
body: (0, index_1.PostCreateBookmarkRequestToJSON)(requestParameters['postCreateBookmarkRequest']),
|
|
255
263
|
}, initOverrides)];
|
|
256
|
-
case
|
|
257
|
-
response =
|
|
264
|
+
case 41:
|
|
265
|
+
response = _14.sent();
|
|
258
266
|
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.CreateBookmarkResponseFromJSON)(jsonValue); })];
|
|
259
267
|
}
|
|
260
268
|
});
|
|
@@ -282,9 +290,9 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
282
290
|
*/
|
|
283
291
|
PostApi.prototype.postCreateRetweetRaw = function (requestParameters, initOverrides) {
|
|
284
292
|
return __awaiter(this, void 0, void 0, function () {
|
|
285
|
-
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r,
|
|
286
|
-
return __generator(this, function (
|
|
287
|
-
switch (
|
|
293
|
+
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, token, tokenString, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, response;
|
|
294
|
+
return __generator(this, function (_14) {
|
|
295
|
+
switch (_14.label) {
|
|
288
296
|
case 0:
|
|
289
297
|
if (requestParameters['pathQueryId'] == null) {
|
|
290
298
|
throw new runtime.RequiredError('pathQueryId', 'Required parameter "pathQueryId" was null or undefined when calling postCreateRetweet().');
|
|
@@ -300,163 +308,171 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
300
308
|
_b = "Accept";
|
|
301
309
|
return [4 /*yield*/, this.configuration.apiKey("Accept")];
|
|
302
310
|
case 1:
|
|
303
|
-
_a[_b] =
|
|
304
|
-
|
|
311
|
+
_a[_b] = _14.sent(); // Accept authentication
|
|
312
|
+
_14.label = 2;
|
|
305
313
|
case 2:
|
|
306
314
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 4];
|
|
307
315
|
_c = headerParameters;
|
|
308
316
|
_d = "x-twitter-client-language";
|
|
309
317
|
return [4 /*yield*/, this.configuration.apiKey("x-twitter-client-language")];
|
|
310
318
|
case 3:
|
|
311
|
-
_c[_d] =
|
|
312
|
-
|
|
319
|
+
_c[_d] = _14.sent(); // ClientLanguage authentication
|
|
320
|
+
_14.label = 4;
|
|
313
321
|
case 4:
|
|
314
322
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 6];
|
|
315
323
|
_e = headerParameters;
|
|
316
|
-
_f = "
|
|
317
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
324
|
+
_f = "Priority";
|
|
325
|
+
return [4 /*yield*/, this.configuration.apiKey("Priority")];
|
|
318
326
|
case 5:
|
|
319
|
-
_e[_f] =
|
|
320
|
-
|
|
327
|
+
_e[_f] = _14.sent(); // Priority authentication
|
|
328
|
+
_14.label = 6;
|
|
321
329
|
case 6:
|
|
322
330
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 8];
|
|
323
331
|
_g = headerParameters;
|
|
324
|
-
_h = "
|
|
325
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
332
|
+
_h = "Referer";
|
|
333
|
+
return [4 /*yield*/, this.configuration.apiKey("Referer")];
|
|
326
334
|
case 7:
|
|
327
|
-
_g[_h] =
|
|
328
|
-
|
|
335
|
+
_g[_h] = _14.sent(); // Referer authentication
|
|
336
|
+
_14.label = 8;
|
|
329
337
|
case 8:
|
|
330
338
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 10];
|
|
331
339
|
_j = headerParameters;
|
|
332
|
-
_k = "Sec-
|
|
333
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
340
|
+
_k = "Sec-Fetch-Dest";
|
|
341
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Dest")];
|
|
334
342
|
case 9:
|
|
335
|
-
_j[_k] =
|
|
336
|
-
|
|
343
|
+
_j[_k] = _14.sent(); // SecFetchDest authentication
|
|
344
|
+
_14.label = 10;
|
|
337
345
|
case 10:
|
|
338
346
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 12];
|
|
339
347
|
_l = headerParameters;
|
|
340
|
-
_m = "Sec-
|
|
341
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
348
|
+
_m = "Sec-Ch-Ua-Platform";
|
|
349
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Platform")];
|
|
342
350
|
case 11:
|
|
343
|
-
_l[_m] =
|
|
344
|
-
|
|
351
|
+
_l[_m] = _14.sent(); // SecChUaPlatform authentication
|
|
352
|
+
_14.label = 12;
|
|
345
353
|
case 12:
|
|
346
354
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 14];
|
|
347
355
|
_o = headerParameters;
|
|
348
|
-
_p = "
|
|
349
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
356
|
+
_p = "Sec-Fetch-Mode";
|
|
357
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Mode")];
|
|
350
358
|
case 13:
|
|
351
|
-
_o[_p] =
|
|
352
|
-
|
|
359
|
+
_o[_p] = _14.sent(); // SecFetchMode authentication
|
|
360
|
+
_14.label = 14;
|
|
353
361
|
case 14:
|
|
354
362
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 16];
|
|
355
363
|
_q = headerParameters;
|
|
356
|
-
_r = "x-
|
|
357
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
364
|
+
_r = "x-csrf-token";
|
|
365
|
+
return [4 /*yield*/, this.configuration.apiKey("x-csrf-token")];
|
|
358
366
|
case 15:
|
|
359
|
-
_q[_r] =
|
|
360
|
-
|
|
367
|
+
_q[_r] = _14.sent(); // CsrfToken authentication
|
|
368
|
+
_14.label = 16;
|
|
361
369
|
case 16:
|
|
362
|
-
if (!(this.configuration && this.configuration.
|
|
370
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 18];
|
|
371
|
+
_s = headerParameters;
|
|
372
|
+
_t = "x-client-uuid";
|
|
373
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-uuid")];
|
|
374
|
+
case 17:
|
|
375
|
+
_s[_t] = _14.sent(); // ClientUuid authentication
|
|
376
|
+
_14.label = 18;
|
|
377
|
+
case 18:
|
|
378
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 20];
|
|
363
379
|
token = this.configuration.accessToken;
|
|
364
380
|
return [4 /*yield*/, token("BearerAuth", [])];
|
|
365
|
-
case
|
|
366
|
-
tokenString =
|
|
381
|
+
case 19:
|
|
382
|
+
tokenString = _14.sent();
|
|
367
383
|
if (tokenString) {
|
|
368
384
|
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
369
385
|
}
|
|
370
|
-
|
|
371
|
-
case 18:
|
|
372
|
-
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 20];
|
|
373
|
-
_s = headerParameters;
|
|
374
|
-
_t = "x-guest-token";
|
|
375
|
-
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
376
|
-
case 19:
|
|
377
|
-
_s[_t] = _12.sent(); // GuestToken authentication
|
|
378
|
-
_12.label = 20;
|
|
386
|
+
_14.label = 20;
|
|
379
387
|
case 20:
|
|
380
388
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 22];
|
|
381
389
|
_u = headerParameters;
|
|
382
|
-
_v = "
|
|
383
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
390
|
+
_v = "x-guest-token";
|
|
391
|
+
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
384
392
|
case 21:
|
|
385
|
-
_u[_v] =
|
|
386
|
-
|
|
393
|
+
_u[_v] = _14.sent(); // GuestToken authentication
|
|
394
|
+
_14.label = 22;
|
|
387
395
|
case 22:
|
|
388
396
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 24];
|
|
389
397
|
_w = headerParameters;
|
|
390
|
-
_x = "
|
|
391
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
398
|
+
_x = "Sec-Ch-Ua";
|
|
399
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua")];
|
|
392
400
|
case 23:
|
|
393
|
-
_w[_x] =
|
|
394
|
-
|
|
401
|
+
_w[_x] = _14.sent(); // SecChUa authentication
|
|
402
|
+
_14.label = 24;
|
|
395
403
|
case 24:
|
|
396
404
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 26];
|
|
397
405
|
_y = headerParameters;
|
|
398
|
-
_z = "x-
|
|
399
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
406
|
+
_z = "x-client-transaction-id";
|
|
407
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-transaction-id")];
|
|
400
408
|
case 25:
|
|
401
|
-
_y[_z] =
|
|
402
|
-
|
|
409
|
+
_y[_z] = _14.sent(); // ClientTransactionId authentication
|
|
410
|
+
_14.label = 26;
|
|
403
411
|
case 26:
|
|
404
412
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 28];
|
|
405
413
|
_0 = headerParameters;
|
|
406
|
-
_1 = "user
|
|
407
|
-
return [4 /*yield*/, this.configuration.apiKey("user
|
|
414
|
+
_1 = "x-twitter-active-user";
|
|
415
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-active-user")];
|
|
408
416
|
case 27:
|
|
409
|
-
_0[_1] =
|
|
410
|
-
|
|
417
|
+
_0[_1] = _14.sent(); // ActiveUser authentication
|
|
418
|
+
_14.label = 28;
|
|
411
419
|
case 28:
|
|
412
420
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 30];
|
|
413
421
|
_2 = headerParameters;
|
|
414
|
-
_3 = "
|
|
415
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
422
|
+
_3 = "user-agent";
|
|
423
|
+
return [4 /*yield*/, this.configuration.apiKey("user-agent")];
|
|
416
424
|
case 29:
|
|
417
|
-
_2[_3] =
|
|
418
|
-
|
|
425
|
+
_2[_3] = _14.sent(); // UserAgent authentication
|
|
426
|
+
_14.label = 30;
|
|
419
427
|
case 30:
|
|
420
428
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 32];
|
|
421
429
|
_4 = headerParameters;
|
|
422
|
-
_5 = "
|
|
423
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
430
|
+
_5 = "Accept-Language";
|
|
431
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Language")];
|
|
424
432
|
case 31:
|
|
425
|
-
_4[_5] =
|
|
426
|
-
|
|
433
|
+
_4[_5] = _14.sent(); // AcceptLanguage authentication
|
|
434
|
+
_14.label = 32;
|
|
427
435
|
case 32:
|
|
428
436
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 34];
|
|
429
437
|
_6 = headerParameters;
|
|
430
|
-
_7 = "
|
|
431
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
438
|
+
_7 = "Sec-Fetch-Site";
|
|
439
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Site")];
|
|
432
440
|
case 33:
|
|
433
|
-
_6[_7] =
|
|
434
|
-
|
|
441
|
+
_6[_7] = _14.sent(); // SecFetchSite authentication
|
|
442
|
+
_14.label = 34;
|
|
435
443
|
case 34:
|
|
436
444
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 36];
|
|
437
445
|
_8 = headerParameters;
|
|
438
|
-
_9 = "
|
|
439
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
446
|
+
_9 = "x-twitter-auth-type";
|
|
447
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-auth-type")];
|
|
440
448
|
case 35:
|
|
441
|
-
_8[_9] =
|
|
442
|
-
|
|
449
|
+
_8[_9] = _14.sent(); // AuthType authentication
|
|
450
|
+
_14.label = 36;
|
|
443
451
|
case 36:
|
|
444
452
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 38];
|
|
445
453
|
_10 = headerParameters;
|
|
446
|
-
_11 = "
|
|
447
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
454
|
+
_11 = "Sec-Ch-Ua-Mobile";
|
|
455
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Mobile")];
|
|
448
456
|
case 37:
|
|
449
|
-
_10[_11] =
|
|
450
|
-
|
|
451
|
-
case 38:
|
|
457
|
+
_10[_11] = _14.sent(); // SecChUaMobile authentication
|
|
458
|
+
_14.label = 38;
|
|
459
|
+
case 38:
|
|
460
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 40];
|
|
461
|
+
_12 = headerParameters;
|
|
462
|
+
_13 = "Accept-Encoding";
|
|
463
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Encoding")];
|
|
464
|
+
case 39:
|
|
465
|
+
_12[_13] = _14.sent(); // AcceptEncoding authentication
|
|
466
|
+
_14.label = 40;
|
|
467
|
+
case 40: return [4 /*yield*/, this.request({
|
|
452
468
|
path: "/graphql/{pathQueryId}/CreateRetweet".replace("{".concat("pathQueryId", "}"), encodeURIComponent(String(requestParameters['pathQueryId']))),
|
|
453
469
|
method: 'POST',
|
|
454
470
|
headers: headerParameters,
|
|
455
471
|
query: queryParameters,
|
|
456
472
|
body: (0, index_1.PostCreateRetweetRequestToJSON)(requestParameters['postCreateRetweetRequest']),
|
|
457
473
|
}, initOverrides)];
|
|
458
|
-
case
|
|
459
|
-
response =
|
|
474
|
+
case 41:
|
|
475
|
+
response = _14.sent();
|
|
460
476
|
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.CreateRetweetResponseFromJSON)(jsonValue); })];
|
|
461
477
|
}
|
|
462
478
|
});
|
|
@@ -484,9 +500,9 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
484
500
|
*/
|
|
485
501
|
PostApi.prototype.postCreateTweetRaw = function (requestParameters, initOverrides) {
|
|
486
502
|
return __awaiter(this, void 0, void 0, function () {
|
|
487
|
-
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r,
|
|
488
|
-
return __generator(this, function (
|
|
489
|
-
switch (
|
|
503
|
+
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, token, tokenString, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, response;
|
|
504
|
+
return __generator(this, function (_14) {
|
|
505
|
+
switch (_14.label) {
|
|
490
506
|
case 0:
|
|
491
507
|
if (requestParameters['pathQueryId'] == null) {
|
|
492
508
|
throw new runtime.RequiredError('pathQueryId', 'Required parameter "pathQueryId" was null or undefined when calling postCreateTweet().');
|
|
@@ -502,163 +518,171 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
502
518
|
_b = "Accept";
|
|
503
519
|
return [4 /*yield*/, this.configuration.apiKey("Accept")];
|
|
504
520
|
case 1:
|
|
505
|
-
_a[_b] =
|
|
506
|
-
|
|
521
|
+
_a[_b] = _14.sent(); // Accept authentication
|
|
522
|
+
_14.label = 2;
|
|
507
523
|
case 2:
|
|
508
524
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 4];
|
|
509
525
|
_c = headerParameters;
|
|
510
526
|
_d = "x-twitter-client-language";
|
|
511
527
|
return [4 /*yield*/, this.configuration.apiKey("x-twitter-client-language")];
|
|
512
528
|
case 3:
|
|
513
|
-
_c[_d] =
|
|
514
|
-
|
|
529
|
+
_c[_d] = _14.sent(); // ClientLanguage authentication
|
|
530
|
+
_14.label = 4;
|
|
515
531
|
case 4:
|
|
516
532
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 6];
|
|
517
533
|
_e = headerParameters;
|
|
518
|
-
_f = "
|
|
519
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
534
|
+
_f = "Priority";
|
|
535
|
+
return [4 /*yield*/, this.configuration.apiKey("Priority")];
|
|
520
536
|
case 5:
|
|
521
|
-
_e[_f] =
|
|
522
|
-
|
|
537
|
+
_e[_f] = _14.sent(); // Priority authentication
|
|
538
|
+
_14.label = 6;
|
|
523
539
|
case 6:
|
|
524
540
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 8];
|
|
525
541
|
_g = headerParameters;
|
|
526
|
-
_h = "
|
|
527
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
542
|
+
_h = "Referer";
|
|
543
|
+
return [4 /*yield*/, this.configuration.apiKey("Referer")];
|
|
528
544
|
case 7:
|
|
529
|
-
_g[_h] =
|
|
530
|
-
|
|
545
|
+
_g[_h] = _14.sent(); // Referer authentication
|
|
546
|
+
_14.label = 8;
|
|
531
547
|
case 8:
|
|
532
548
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 10];
|
|
533
549
|
_j = headerParameters;
|
|
534
|
-
_k = "Sec-
|
|
535
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
550
|
+
_k = "Sec-Fetch-Dest";
|
|
551
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Dest")];
|
|
536
552
|
case 9:
|
|
537
|
-
_j[_k] =
|
|
538
|
-
|
|
553
|
+
_j[_k] = _14.sent(); // SecFetchDest authentication
|
|
554
|
+
_14.label = 10;
|
|
539
555
|
case 10:
|
|
540
556
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 12];
|
|
541
557
|
_l = headerParameters;
|
|
542
|
-
_m = "Sec-
|
|
543
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
558
|
+
_m = "Sec-Ch-Ua-Platform";
|
|
559
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Platform")];
|
|
544
560
|
case 11:
|
|
545
|
-
_l[_m] =
|
|
546
|
-
|
|
561
|
+
_l[_m] = _14.sent(); // SecChUaPlatform authentication
|
|
562
|
+
_14.label = 12;
|
|
547
563
|
case 12:
|
|
548
564
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 14];
|
|
549
565
|
_o = headerParameters;
|
|
550
|
-
_p = "
|
|
551
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
566
|
+
_p = "Sec-Fetch-Mode";
|
|
567
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Mode")];
|
|
552
568
|
case 13:
|
|
553
|
-
_o[_p] =
|
|
554
|
-
|
|
569
|
+
_o[_p] = _14.sent(); // SecFetchMode authentication
|
|
570
|
+
_14.label = 14;
|
|
555
571
|
case 14:
|
|
556
572
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 16];
|
|
557
573
|
_q = headerParameters;
|
|
558
|
-
_r = "x-
|
|
559
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
574
|
+
_r = "x-csrf-token";
|
|
575
|
+
return [4 /*yield*/, this.configuration.apiKey("x-csrf-token")];
|
|
560
576
|
case 15:
|
|
561
|
-
_q[_r] =
|
|
562
|
-
|
|
577
|
+
_q[_r] = _14.sent(); // CsrfToken authentication
|
|
578
|
+
_14.label = 16;
|
|
563
579
|
case 16:
|
|
564
|
-
if (!(this.configuration && this.configuration.
|
|
580
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 18];
|
|
581
|
+
_s = headerParameters;
|
|
582
|
+
_t = "x-client-uuid";
|
|
583
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-uuid")];
|
|
584
|
+
case 17:
|
|
585
|
+
_s[_t] = _14.sent(); // ClientUuid authentication
|
|
586
|
+
_14.label = 18;
|
|
587
|
+
case 18:
|
|
588
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 20];
|
|
565
589
|
token = this.configuration.accessToken;
|
|
566
590
|
return [4 /*yield*/, token("BearerAuth", [])];
|
|
567
|
-
case
|
|
568
|
-
tokenString =
|
|
591
|
+
case 19:
|
|
592
|
+
tokenString = _14.sent();
|
|
569
593
|
if (tokenString) {
|
|
570
594
|
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
571
595
|
}
|
|
572
|
-
|
|
573
|
-
case 18:
|
|
574
|
-
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 20];
|
|
575
|
-
_s = headerParameters;
|
|
576
|
-
_t = "x-guest-token";
|
|
577
|
-
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
578
|
-
case 19:
|
|
579
|
-
_s[_t] = _12.sent(); // GuestToken authentication
|
|
580
|
-
_12.label = 20;
|
|
596
|
+
_14.label = 20;
|
|
581
597
|
case 20:
|
|
582
598
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 22];
|
|
583
599
|
_u = headerParameters;
|
|
584
|
-
_v = "
|
|
585
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
600
|
+
_v = "x-guest-token";
|
|
601
|
+
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
586
602
|
case 21:
|
|
587
|
-
_u[_v] =
|
|
588
|
-
|
|
603
|
+
_u[_v] = _14.sent(); // GuestToken authentication
|
|
604
|
+
_14.label = 22;
|
|
589
605
|
case 22:
|
|
590
606
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 24];
|
|
591
607
|
_w = headerParameters;
|
|
592
|
-
_x = "
|
|
593
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
608
|
+
_x = "Sec-Ch-Ua";
|
|
609
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua")];
|
|
594
610
|
case 23:
|
|
595
|
-
_w[_x] =
|
|
596
|
-
|
|
611
|
+
_w[_x] = _14.sent(); // SecChUa authentication
|
|
612
|
+
_14.label = 24;
|
|
597
613
|
case 24:
|
|
598
614
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 26];
|
|
599
615
|
_y = headerParameters;
|
|
600
|
-
_z = "x-
|
|
601
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
616
|
+
_z = "x-client-transaction-id";
|
|
617
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-transaction-id")];
|
|
602
618
|
case 25:
|
|
603
|
-
_y[_z] =
|
|
604
|
-
|
|
619
|
+
_y[_z] = _14.sent(); // ClientTransactionId authentication
|
|
620
|
+
_14.label = 26;
|
|
605
621
|
case 26:
|
|
606
622
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 28];
|
|
607
623
|
_0 = headerParameters;
|
|
608
|
-
_1 = "user
|
|
609
|
-
return [4 /*yield*/, this.configuration.apiKey("user
|
|
624
|
+
_1 = "x-twitter-active-user";
|
|
625
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-active-user")];
|
|
610
626
|
case 27:
|
|
611
|
-
_0[_1] =
|
|
612
|
-
|
|
627
|
+
_0[_1] = _14.sent(); // ActiveUser authentication
|
|
628
|
+
_14.label = 28;
|
|
613
629
|
case 28:
|
|
614
630
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 30];
|
|
615
631
|
_2 = headerParameters;
|
|
616
|
-
_3 = "
|
|
617
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
632
|
+
_3 = "user-agent";
|
|
633
|
+
return [4 /*yield*/, this.configuration.apiKey("user-agent")];
|
|
618
634
|
case 29:
|
|
619
|
-
_2[_3] =
|
|
620
|
-
|
|
635
|
+
_2[_3] = _14.sent(); // UserAgent authentication
|
|
636
|
+
_14.label = 30;
|
|
621
637
|
case 30:
|
|
622
638
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 32];
|
|
623
639
|
_4 = headerParameters;
|
|
624
|
-
_5 = "
|
|
625
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
640
|
+
_5 = "Accept-Language";
|
|
641
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Language")];
|
|
626
642
|
case 31:
|
|
627
|
-
_4[_5] =
|
|
628
|
-
|
|
643
|
+
_4[_5] = _14.sent(); // AcceptLanguage authentication
|
|
644
|
+
_14.label = 32;
|
|
629
645
|
case 32:
|
|
630
646
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 34];
|
|
631
647
|
_6 = headerParameters;
|
|
632
|
-
_7 = "
|
|
633
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
648
|
+
_7 = "Sec-Fetch-Site";
|
|
649
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Site")];
|
|
634
650
|
case 33:
|
|
635
|
-
_6[_7] =
|
|
636
|
-
|
|
651
|
+
_6[_7] = _14.sent(); // SecFetchSite authentication
|
|
652
|
+
_14.label = 34;
|
|
637
653
|
case 34:
|
|
638
654
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 36];
|
|
639
655
|
_8 = headerParameters;
|
|
640
|
-
_9 = "
|
|
641
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
656
|
+
_9 = "x-twitter-auth-type";
|
|
657
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-auth-type")];
|
|
642
658
|
case 35:
|
|
643
|
-
_8[_9] =
|
|
644
|
-
|
|
659
|
+
_8[_9] = _14.sent(); // AuthType authentication
|
|
660
|
+
_14.label = 36;
|
|
645
661
|
case 36:
|
|
646
662
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 38];
|
|
647
663
|
_10 = headerParameters;
|
|
648
|
-
_11 = "
|
|
649
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
664
|
+
_11 = "Sec-Ch-Ua-Mobile";
|
|
665
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Mobile")];
|
|
650
666
|
case 37:
|
|
651
|
-
_10[_11] =
|
|
652
|
-
|
|
653
|
-
case 38:
|
|
667
|
+
_10[_11] = _14.sent(); // SecChUaMobile authentication
|
|
668
|
+
_14.label = 38;
|
|
669
|
+
case 38:
|
|
670
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 40];
|
|
671
|
+
_12 = headerParameters;
|
|
672
|
+
_13 = "Accept-Encoding";
|
|
673
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Encoding")];
|
|
674
|
+
case 39:
|
|
675
|
+
_12[_13] = _14.sent(); // AcceptEncoding authentication
|
|
676
|
+
_14.label = 40;
|
|
677
|
+
case 40: return [4 /*yield*/, this.request({
|
|
654
678
|
path: "/graphql/{pathQueryId}/CreateTweet".replace("{".concat("pathQueryId", "}"), encodeURIComponent(String(requestParameters['pathQueryId']))),
|
|
655
679
|
method: 'POST',
|
|
656
680
|
headers: headerParameters,
|
|
657
681
|
query: queryParameters,
|
|
658
682
|
body: (0, index_1.PostCreateTweetRequestToJSON)(requestParameters['postCreateTweetRequest']),
|
|
659
683
|
}, initOverrides)];
|
|
660
|
-
case
|
|
661
|
-
response =
|
|
684
|
+
case 41:
|
|
685
|
+
response = _14.sent();
|
|
662
686
|
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.CreateTweetResponseFromJSON)(jsonValue); })];
|
|
663
687
|
}
|
|
664
688
|
});
|
|
@@ -686,9 +710,9 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
686
710
|
*/
|
|
687
711
|
PostApi.prototype.postDeleteBookmarkRaw = function (requestParameters, initOverrides) {
|
|
688
712
|
return __awaiter(this, void 0, void 0, function () {
|
|
689
|
-
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r,
|
|
690
|
-
return __generator(this, function (
|
|
691
|
-
switch (
|
|
713
|
+
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, token, tokenString, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, response;
|
|
714
|
+
return __generator(this, function (_14) {
|
|
715
|
+
switch (_14.label) {
|
|
692
716
|
case 0:
|
|
693
717
|
if (requestParameters['pathQueryId'] == null) {
|
|
694
718
|
throw new runtime.RequiredError('pathQueryId', 'Required parameter "pathQueryId" was null or undefined when calling postDeleteBookmark().');
|
|
@@ -704,163 +728,171 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
704
728
|
_b = "Accept";
|
|
705
729
|
return [4 /*yield*/, this.configuration.apiKey("Accept")];
|
|
706
730
|
case 1:
|
|
707
|
-
_a[_b] =
|
|
708
|
-
|
|
731
|
+
_a[_b] = _14.sent(); // Accept authentication
|
|
732
|
+
_14.label = 2;
|
|
709
733
|
case 2:
|
|
710
734
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 4];
|
|
711
735
|
_c = headerParameters;
|
|
712
736
|
_d = "x-twitter-client-language";
|
|
713
737
|
return [4 /*yield*/, this.configuration.apiKey("x-twitter-client-language")];
|
|
714
738
|
case 3:
|
|
715
|
-
_c[_d] =
|
|
716
|
-
|
|
739
|
+
_c[_d] = _14.sent(); // ClientLanguage authentication
|
|
740
|
+
_14.label = 4;
|
|
717
741
|
case 4:
|
|
718
742
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 6];
|
|
719
743
|
_e = headerParameters;
|
|
720
|
-
_f = "
|
|
721
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
744
|
+
_f = "Priority";
|
|
745
|
+
return [4 /*yield*/, this.configuration.apiKey("Priority")];
|
|
722
746
|
case 5:
|
|
723
|
-
_e[_f] =
|
|
724
|
-
|
|
747
|
+
_e[_f] = _14.sent(); // Priority authentication
|
|
748
|
+
_14.label = 6;
|
|
725
749
|
case 6:
|
|
726
750
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 8];
|
|
727
751
|
_g = headerParameters;
|
|
728
|
-
_h = "
|
|
729
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
752
|
+
_h = "Referer";
|
|
753
|
+
return [4 /*yield*/, this.configuration.apiKey("Referer")];
|
|
730
754
|
case 7:
|
|
731
|
-
_g[_h] =
|
|
732
|
-
|
|
755
|
+
_g[_h] = _14.sent(); // Referer authentication
|
|
756
|
+
_14.label = 8;
|
|
733
757
|
case 8:
|
|
734
758
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 10];
|
|
735
759
|
_j = headerParameters;
|
|
736
|
-
_k = "Sec-
|
|
737
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
760
|
+
_k = "Sec-Fetch-Dest";
|
|
761
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Dest")];
|
|
738
762
|
case 9:
|
|
739
|
-
_j[_k] =
|
|
740
|
-
|
|
763
|
+
_j[_k] = _14.sent(); // SecFetchDest authentication
|
|
764
|
+
_14.label = 10;
|
|
741
765
|
case 10:
|
|
742
766
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 12];
|
|
743
767
|
_l = headerParameters;
|
|
744
|
-
_m = "Sec-
|
|
745
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
768
|
+
_m = "Sec-Ch-Ua-Platform";
|
|
769
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Platform")];
|
|
746
770
|
case 11:
|
|
747
|
-
_l[_m] =
|
|
748
|
-
|
|
771
|
+
_l[_m] = _14.sent(); // SecChUaPlatform authentication
|
|
772
|
+
_14.label = 12;
|
|
749
773
|
case 12:
|
|
750
774
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 14];
|
|
751
775
|
_o = headerParameters;
|
|
752
|
-
_p = "
|
|
753
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
776
|
+
_p = "Sec-Fetch-Mode";
|
|
777
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Mode")];
|
|
754
778
|
case 13:
|
|
755
|
-
_o[_p] =
|
|
756
|
-
|
|
779
|
+
_o[_p] = _14.sent(); // SecFetchMode authentication
|
|
780
|
+
_14.label = 14;
|
|
757
781
|
case 14:
|
|
758
782
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 16];
|
|
759
783
|
_q = headerParameters;
|
|
760
|
-
_r = "x-
|
|
761
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
784
|
+
_r = "x-csrf-token";
|
|
785
|
+
return [4 /*yield*/, this.configuration.apiKey("x-csrf-token")];
|
|
762
786
|
case 15:
|
|
763
|
-
_q[_r] =
|
|
764
|
-
|
|
787
|
+
_q[_r] = _14.sent(); // CsrfToken authentication
|
|
788
|
+
_14.label = 16;
|
|
765
789
|
case 16:
|
|
766
|
-
if (!(this.configuration && this.configuration.
|
|
790
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 18];
|
|
791
|
+
_s = headerParameters;
|
|
792
|
+
_t = "x-client-uuid";
|
|
793
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-uuid")];
|
|
794
|
+
case 17:
|
|
795
|
+
_s[_t] = _14.sent(); // ClientUuid authentication
|
|
796
|
+
_14.label = 18;
|
|
797
|
+
case 18:
|
|
798
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 20];
|
|
767
799
|
token = this.configuration.accessToken;
|
|
768
800
|
return [4 /*yield*/, token("BearerAuth", [])];
|
|
769
|
-
case
|
|
770
|
-
tokenString =
|
|
801
|
+
case 19:
|
|
802
|
+
tokenString = _14.sent();
|
|
771
803
|
if (tokenString) {
|
|
772
804
|
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
773
805
|
}
|
|
774
|
-
|
|
775
|
-
case 18:
|
|
776
|
-
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 20];
|
|
777
|
-
_s = headerParameters;
|
|
778
|
-
_t = "x-guest-token";
|
|
779
|
-
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
780
|
-
case 19:
|
|
781
|
-
_s[_t] = _12.sent(); // GuestToken authentication
|
|
782
|
-
_12.label = 20;
|
|
806
|
+
_14.label = 20;
|
|
783
807
|
case 20:
|
|
784
808
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 22];
|
|
785
809
|
_u = headerParameters;
|
|
786
|
-
_v = "
|
|
787
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
810
|
+
_v = "x-guest-token";
|
|
811
|
+
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
788
812
|
case 21:
|
|
789
|
-
_u[_v] =
|
|
790
|
-
|
|
813
|
+
_u[_v] = _14.sent(); // GuestToken authentication
|
|
814
|
+
_14.label = 22;
|
|
791
815
|
case 22:
|
|
792
816
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 24];
|
|
793
817
|
_w = headerParameters;
|
|
794
|
-
_x = "
|
|
795
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
818
|
+
_x = "Sec-Ch-Ua";
|
|
819
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua")];
|
|
796
820
|
case 23:
|
|
797
|
-
_w[_x] =
|
|
798
|
-
|
|
821
|
+
_w[_x] = _14.sent(); // SecChUa authentication
|
|
822
|
+
_14.label = 24;
|
|
799
823
|
case 24:
|
|
800
824
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 26];
|
|
801
825
|
_y = headerParameters;
|
|
802
|
-
_z = "x-
|
|
803
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
826
|
+
_z = "x-client-transaction-id";
|
|
827
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-transaction-id")];
|
|
804
828
|
case 25:
|
|
805
|
-
_y[_z] =
|
|
806
|
-
|
|
829
|
+
_y[_z] = _14.sent(); // ClientTransactionId authentication
|
|
830
|
+
_14.label = 26;
|
|
807
831
|
case 26:
|
|
808
832
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 28];
|
|
809
833
|
_0 = headerParameters;
|
|
810
|
-
_1 = "user
|
|
811
|
-
return [4 /*yield*/, this.configuration.apiKey("user
|
|
834
|
+
_1 = "x-twitter-active-user";
|
|
835
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-active-user")];
|
|
812
836
|
case 27:
|
|
813
|
-
_0[_1] =
|
|
814
|
-
|
|
837
|
+
_0[_1] = _14.sent(); // ActiveUser authentication
|
|
838
|
+
_14.label = 28;
|
|
815
839
|
case 28:
|
|
816
840
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 30];
|
|
817
841
|
_2 = headerParameters;
|
|
818
|
-
_3 = "
|
|
819
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
842
|
+
_3 = "user-agent";
|
|
843
|
+
return [4 /*yield*/, this.configuration.apiKey("user-agent")];
|
|
820
844
|
case 29:
|
|
821
|
-
_2[_3] =
|
|
822
|
-
|
|
845
|
+
_2[_3] = _14.sent(); // UserAgent authentication
|
|
846
|
+
_14.label = 30;
|
|
823
847
|
case 30:
|
|
824
848
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 32];
|
|
825
849
|
_4 = headerParameters;
|
|
826
|
-
_5 = "
|
|
827
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
850
|
+
_5 = "Accept-Language";
|
|
851
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Language")];
|
|
828
852
|
case 31:
|
|
829
|
-
_4[_5] =
|
|
830
|
-
|
|
853
|
+
_4[_5] = _14.sent(); // AcceptLanguage authentication
|
|
854
|
+
_14.label = 32;
|
|
831
855
|
case 32:
|
|
832
856
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 34];
|
|
833
857
|
_6 = headerParameters;
|
|
834
|
-
_7 = "
|
|
835
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
858
|
+
_7 = "Sec-Fetch-Site";
|
|
859
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Site")];
|
|
836
860
|
case 33:
|
|
837
|
-
_6[_7] =
|
|
838
|
-
|
|
861
|
+
_6[_7] = _14.sent(); // SecFetchSite authentication
|
|
862
|
+
_14.label = 34;
|
|
839
863
|
case 34:
|
|
840
864
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 36];
|
|
841
865
|
_8 = headerParameters;
|
|
842
|
-
_9 = "
|
|
843
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
866
|
+
_9 = "x-twitter-auth-type";
|
|
867
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-auth-type")];
|
|
844
868
|
case 35:
|
|
845
|
-
_8[_9] =
|
|
846
|
-
|
|
869
|
+
_8[_9] = _14.sent(); // AuthType authentication
|
|
870
|
+
_14.label = 36;
|
|
847
871
|
case 36:
|
|
848
872
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 38];
|
|
849
873
|
_10 = headerParameters;
|
|
850
|
-
_11 = "
|
|
851
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
874
|
+
_11 = "Sec-Ch-Ua-Mobile";
|
|
875
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Mobile")];
|
|
852
876
|
case 37:
|
|
853
|
-
_10[_11] =
|
|
854
|
-
|
|
855
|
-
case 38:
|
|
877
|
+
_10[_11] = _14.sent(); // SecChUaMobile authentication
|
|
878
|
+
_14.label = 38;
|
|
879
|
+
case 38:
|
|
880
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 40];
|
|
881
|
+
_12 = headerParameters;
|
|
882
|
+
_13 = "Accept-Encoding";
|
|
883
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Encoding")];
|
|
884
|
+
case 39:
|
|
885
|
+
_12[_13] = _14.sent(); // AcceptEncoding authentication
|
|
886
|
+
_14.label = 40;
|
|
887
|
+
case 40: return [4 /*yield*/, this.request({
|
|
856
888
|
path: "/graphql/{pathQueryId}/DeleteBookmark".replace("{".concat("pathQueryId", "}"), encodeURIComponent(String(requestParameters['pathQueryId']))),
|
|
857
889
|
method: 'POST',
|
|
858
890
|
headers: headerParameters,
|
|
859
891
|
query: queryParameters,
|
|
860
892
|
body: (0, index_1.PostDeleteBookmarkRequestToJSON)(requestParameters['postDeleteBookmarkRequest']),
|
|
861
893
|
}, initOverrides)];
|
|
862
|
-
case
|
|
863
|
-
response =
|
|
894
|
+
case 41:
|
|
895
|
+
response = _14.sent();
|
|
864
896
|
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.DeleteBookmarkResponseFromJSON)(jsonValue); })];
|
|
865
897
|
}
|
|
866
898
|
});
|
|
@@ -888,9 +920,9 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
888
920
|
*/
|
|
889
921
|
PostApi.prototype.postDeleteRetweetRaw = function (requestParameters, initOverrides) {
|
|
890
922
|
return __awaiter(this, void 0, void 0, function () {
|
|
891
|
-
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r,
|
|
892
|
-
return __generator(this, function (
|
|
893
|
-
switch (
|
|
923
|
+
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, token, tokenString, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, response;
|
|
924
|
+
return __generator(this, function (_14) {
|
|
925
|
+
switch (_14.label) {
|
|
894
926
|
case 0:
|
|
895
927
|
if (requestParameters['pathQueryId'] == null) {
|
|
896
928
|
throw new runtime.RequiredError('pathQueryId', 'Required parameter "pathQueryId" was null or undefined when calling postDeleteRetweet().');
|
|
@@ -906,163 +938,171 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
906
938
|
_b = "Accept";
|
|
907
939
|
return [4 /*yield*/, this.configuration.apiKey("Accept")];
|
|
908
940
|
case 1:
|
|
909
|
-
_a[_b] =
|
|
910
|
-
|
|
941
|
+
_a[_b] = _14.sent(); // Accept authentication
|
|
942
|
+
_14.label = 2;
|
|
911
943
|
case 2:
|
|
912
944
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 4];
|
|
913
945
|
_c = headerParameters;
|
|
914
946
|
_d = "x-twitter-client-language";
|
|
915
947
|
return [4 /*yield*/, this.configuration.apiKey("x-twitter-client-language")];
|
|
916
948
|
case 3:
|
|
917
|
-
_c[_d] =
|
|
918
|
-
|
|
949
|
+
_c[_d] = _14.sent(); // ClientLanguage authentication
|
|
950
|
+
_14.label = 4;
|
|
919
951
|
case 4:
|
|
920
952
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 6];
|
|
921
953
|
_e = headerParameters;
|
|
922
|
-
_f = "
|
|
923
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
954
|
+
_f = "Priority";
|
|
955
|
+
return [4 /*yield*/, this.configuration.apiKey("Priority")];
|
|
924
956
|
case 5:
|
|
925
|
-
_e[_f] =
|
|
926
|
-
|
|
957
|
+
_e[_f] = _14.sent(); // Priority authentication
|
|
958
|
+
_14.label = 6;
|
|
927
959
|
case 6:
|
|
928
960
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 8];
|
|
929
961
|
_g = headerParameters;
|
|
930
|
-
_h = "
|
|
931
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
962
|
+
_h = "Referer";
|
|
963
|
+
return [4 /*yield*/, this.configuration.apiKey("Referer")];
|
|
932
964
|
case 7:
|
|
933
|
-
_g[_h] =
|
|
934
|
-
|
|
965
|
+
_g[_h] = _14.sent(); // Referer authentication
|
|
966
|
+
_14.label = 8;
|
|
935
967
|
case 8:
|
|
936
968
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 10];
|
|
937
969
|
_j = headerParameters;
|
|
938
|
-
_k = "Sec-
|
|
939
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
970
|
+
_k = "Sec-Fetch-Dest";
|
|
971
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Dest")];
|
|
940
972
|
case 9:
|
|
941
|
-
_j[_k] =
|
|
942
|
-
|
|
973
|
+
_j[_k] = _14.sent(); // SecFetchDest authentication
|
|
974
|
+
_14.label = 10;
|
|
943
975
|
case 10:
|
|
944
976
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 12];
|
|
945
977
|
_l = headerParameters;
|
|
946
|
-
_m = "Sec-
|
|
947
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
978
|
+
_m = "Sec-Ch-Ua-Platform";
|
|
979
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Platform")];
|
|
948
980
|
case 11:
|
|
949
|
-
_l[_m] =
|
|
950
|
-
|
|
981
|
+
_l[_m] = _14.sent(); // SecChUaPlatform authentication
|
|
982
|
+
_14.label = 12;
|
|
951
983
|
case 12:
|
|
952
984
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 14];
|
|
953
985
|
_o = headerParameters;
|
|
954
|
-
_p = "
|
|
955
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
986
|
+
_p = "Sec-Fetch-Mode";
|
|
987
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Mode")];
|
|
956
988
|
case 13:
|
|
957
|
-
_o[_p] =
|
|
958
|
-
|
|
989
|
+
_o[_p] = _14.sent(); // SecFetchMode authentication
|
|
990
|
+
_14.label = 14;
|
|
959
991
|
case 14:
|
|
960
992
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 16];
|
|
961
993
|
_q = headerParameters;
|
|
962
|
-
_r = "x-
|
|
963
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
994
|
+
_r = "x-csrf-token";
|
|
995
|
+
return [4 /*yield*/, this.configuration.apiKey("x-csrf-token")];
|
|
964
996
|
case 15:
|
|
965
|
-
_q[_r] =
|
|
966
|
-
|
|
997
|
+
_q[_r] = _14.sent(); // CsrfToken authentication
|
|
998
|
+
_14.label = 16;
|
|
967
999
|
case 16:
|
|
968
|
-
if (!(this.configuration && this.configuration.
|
|
1000
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 18];
|
|
1001
|
+
_s = headerParameters;
|
|
1002
|
+
_t = "x-client-uuid";
|
|
1003
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-uuid")];
|
|
1004
|
+
case 17:
|
|
1005
|
+
_s[_t] = _14.sent(); // ClientUuid authentication
|
|
1006
|
+
_14.label = 18;
|
|
1007
|
+
case 18:
|
|
1008
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 20];
|
|
969
1009
|
token = this.configuration.accessToken;
|
|
970
1010
|
return [4 /*yield*/, token("BearerAuth", [])];
|
|
971
|
-
case
|
|
972
|
-
tokenString =
|
|
1011
|
+
case 19:
|
|
1012
|
+
tokenString = _14.sent();
|
|
973
1013
|
if (tokenString) {
|
|
974
1014
|
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
975
1015
|
}
|
|
976
|
-
|
|
977
|
-
case 18:
|
|
978
|
-
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 20];
|
|
979
|
-
_s = headerParameters;
|
|
980
|
-
_t = "x-guest-token";
|
|
981
|
-
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
982
|
-
case 19:
|
|
983
|
-
_s[_t] = _12.sent(); // GuestToken authentication
|
|
984
|
-
_12.label = 20;
|
|
1016
|
+
_14.label = 20;
|
|
985
1017
|
case 20:
|
|
986
1018
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 22];
|
|
987
1019
|
_u = headerParameters;
|
|
988
|
-
_v = "
|
|
989
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1020
|
+
_v = "x-guest-token";
|
|
1021
|
+
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
990
1022
|
case 21:
|
|
991
|
-
_u[_v] =
|
|
992
|
-
|
|
1023
|
+
_u[_v] = _14.sent(); // GuestToken authentication
|
|
1024
|
+
_14.label = 22;
|
|
993
1025
|
case 22:
|
|
994
1026
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 24];
|
|
995
1027
|
_w = headerParameters;
|
|
996
|
-
_x = "
|
|
997
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1028
|
+
_x = "Sec-Ch-Ua";
|
|
1029
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua")];
|
|
998
1030
|
case 23:
|
|
999
|
-
_w[_x] =
|
|
1000
|
-
|
|
1031
|
+
_w[_x] = _14.sent(); // SecChUa authentication
|
|
1032
|
+
_14.label = 24;
|
|
1001
1033
|
case 24:
|
|
1002
1034
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 26];
|
|
1003
1035
|
_y = headerParameters;
|
|
1004
|
-
_z = "x-
|
|
1005
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
1036
|
+
_z = "x-client-transaction-id";
|
|
1037
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-transaction-id")];
|
|
1006
1038
|
case 25:
|
|
1007
|
-
_y[_z] =
|
|
1008
|
-
|
|
1039
|
+
_y[_z] = _14.sent(); // ClientTransactionId authentication
|
|
1040
|
+
_14.label = 26;
|
|
1009
1041
|
case 26:
|
|
1010
1042
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 28];
|
|
1011
1043
|
_0 = headerParameters;
|
|
1012
|
-
_1 = "user
|
|
1013
|
-
return [4 /*yield*/, this.configuration.apiKey("user
|
|
1044
|
+
_1 = "x-twitter-active-user";
|
|
1045
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-active-user")];
|
|
1014
1046
|
case 27:
|
|
1015
|
-
_0[_1] =
|
|
1016
|
-
|
|
1047
|
+
_0[_1] = _14.sent(); // ActiveUser authentication
|
|
1048
|
+
_14.label = 28;
|
|
1017
1049
|
case 28:
|
|
1018
1050
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 30];
|
|
1019
1051
|
_2 = headerParameters;
|
|
1020
|
-
_3 = "
|
|
1021
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1052
|
+
_3 = "user-agent";
|
|
1053
|
+
return [4 /*yield*/, this.configuration.apiKey("user-agent")];
|
|
1022
1054
|
case 29:
|
|
1023
|
-
_2[_3] =
|
|
1024
|
-
|
|
1055
|
+
_2[_3] = _14.sent(); // UserAgent authentication
|
|
1056
|
+
_14.label = 30;
|
|
1025
1057
|
case 30:
|
|
1026
1058
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 32];
|
|
1027
1059
|
_4 = headerParameters;
|
|
1028
|
-
_5 = "
|
|
1029
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1060
|
+
_5 = "Accept-Language";
|
|
1061
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Language")];
|
|
1030
1062
|
case 31:
|
|
1031
|
-
_4[_5] =
|
|
1032
|
-
|
|
1063
|
+
_4[_5] = _14.sent(); // AcceptLanguage authentication
|
|
1064
|
+
_14.label = 32;
|
|
1033
1065
|
case 32:
|
|
1034
1066
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 34];
|
|
1035
1067
|
_6 = headerParameters;
|
|
1036
|
-
_7 = "
|
|
1037
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1068
|
+
_7 = "Sec-Fetch-Site";
|
|
1069
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Site")];
|
|
1038
1070
|
case 33:
|
|
1039
|
-
_6[_7] =
|
|
1040
|
-
|
|
1071
|
+
_6[_7] = _14.sent(); // SecFetchSite authentication
|
|
1072
|
+
_14.label = 34;
|
|
1041
1073
|
case 34:
|
|
1042
1074
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 36];
|
|
1043
1075
|
_8 = headerParameters;
|
|
1044
|
-
_9 = "
|
|
1045
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1076
|
+
_9 = "x-twitter-auth-type";
|
|
1077
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-auth-type")];
|
|
1046
1078
|
case 35:
|
|
1047
|
-
_8[_9] =
|
|
1048
|
-
|
|
1079
|
+
_8[_9] = _14.sent(); // AuthType authentication
|
|
1080
|
+
_14.label = 36;
|
|
1049
1081
|
case 36:
|
|
1050
1082
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 38];
|
|
1051
1083
|
_10 = headerParameters;
|
|
1052
|
-
_11 = "
|
|
1053
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1084
|
+
_11 = "Sec-Ch-Ua-Mobile";
|
|
1085
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Mobile")];
|
|
1054
1086
|
case 37:
|
|
1055
|
-
_10[_11] =
|
|
1056
|
-
|
|
1057
|
-
case 38:
|
|
1087
|
+
_10[_11] = _14.sent(); // SecChUaMobile authentication
|
|
1088
|
+
_14.label = 38;
|
|
1089
|
+
case 38:
|
|
1090
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 40];
|
|
1091
|
+
_12 = headerParameters;
|
|
1092
|
+
_13 = "Accept-Encoding";
|
|
1093
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Encoding")];
|
|
1094
|
+
case 39:
|
|
1095
|
+
_12[_13] = _14.sent(); // AcceptEncoding authentication
|
|
1096
|
+
_14.label = 40;
|
|
1097
|
+
case 40: return [4 /*yield*/, this.request({
|
|
1058
1098
|
path: "/graphql/{pathQueryId}/DeleteRetweet".replace("{".concat("pathQueryId", "}"), encodeURIComponent(String(requestParameters['pathQueryId']))),
|
|
1059
1099
|
method: 'POST',
|
|
1060
1100
|
headers: headerParameters,
|
|
1061
1101
|
query: queryParameters,
|
|
1062
1102
|
body: (0, index_1.PostDeleteRetweetRequestToJSON)(requestParameters['postDeleteRetweetRequest']),
|
|
1063
1103
|
}, initOverrides)];
|
|
1064
|
-
case
|
|
1065
|
-
response =
|
|
1104
|
+
case 41:
|
|
1105
|
+
response = _14.sent();
|
|
1066
1106
|
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.DeleteRetweetResponseFromJSON)(jsonValue); })];
|
|
1067
1107
|
}
|
|
1068
1108
|
});
|
|
@@ -1090,9 +1130,9 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
1090
1130
|
*/
|
|
1091
1131
|
PostApi.prototype.postDeleteTweetRaw = function (requestParameters, initOverrides) {
|
|
1092
1132
|
return __awaiter(this, void 0, void 0, function () {
|
|
1093
|
-
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r,
|
|
1094
|
-
return __generator(this, function (
|
|
1095
|
-
switch (
|
|
1133
|
+
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, token, tokenString, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, response;
|
|
1134
|
+
return __generator(this, function (_14) {
|
|
1135
|
+
switch (_14.label) {
|
|
1096
1136
|
case 0:
|
|
1097
1137
|
if (requestParameters['pathQueryId'] == null) {
|
|
1098
1138
|
throw new runtime.RequiredError('pathQueryId', 'Required parameter "pathQueryId" was null or undefined when calling postDeleteTweet().');
|
|
@@ -1108,163 +1148,171 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
1108
1148
|
_b = "Accept";
|
|
1109
1149
|
return [4 /*yield*/, this.configuration.apiKey("Accept")];
|
|
1110
1150
|
case 1:
|
|
1111
|
-
_a[_b] =
|
|
1112
|
-
|
|
1151
|
+
_a[_b] = _14.sent(); // Accept authentication
|
|
1152
|
+
_14.label = 2;
|
|
1113
1153
|
case 2:
|
|
1114
1154
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 4];
|
|
1115
1155
|
_c = headerParameters;
|
|
1116
1156
|
_d = "x-twitter-client-language";
|
|
1117
1157
|
return [4 /*yield*/, this.configuration.apiKey("x-twitter-client-language")];
|
|
1118
1158
|
case 3:
|
|
1119
|
-
_c[_d] =
|
|
1120
|
-
|
|
1159
|
+
_c[_d] = _14.sent(); // ClientLanguage authentication
|
|
1160
|
+
_14.label = 4;
|
|
1121
1161
|
case 4:
|
|
1122
1162
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 6];
|
|
1123
1163
|
_e = headerParameters;
|
|
1124
|
-
_f = "
|
|
1125
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1164
|
+
_f = "Priority";
|
|
1165
|
+
return [4 /*yield*/, this.configuration.apiKey("Priority")];
|
|
1126
1166
|
case 5:
|
|
1127
|
-
_e[_f] =
|
|
1128
|
-
|
|
1167
|
+
_e[_f] = _14.sent(); // Priority authentication
|
|
1168
|
+
_14.label = 6;
|
|
1129
1169
|
case 6:
|
|
1130
1170
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 8];
|
|
1131
1171
|
_g = headerParameters;
|
|
1132
|
-
_h = "
|
|
1133
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1172
|
+
_h = "Referer";
|
|
1173
|
+
return [4 /*yield*/, this.configuration.apiKey("Referer")];
|
|
1134
1174
|
case 7:
|
|
1135
|
-
_g[_h] =
|
|
1136
|
-
|
|
1175
|
+
_g[_h] = _14.sent(); // Referer authentication
|
|
1176
|
+
_14.label = 8;
|
|
1137
1177
|
case 8:
|
|
1138
1178
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 10];
|
|
1139
1179
|
_j = headerParameters;
|
|
1140
|
-
_k = "Sec-
|
|
1141
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
1180
|
+
_k = "Sec-Fetch-Dest";
|
|
1181
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Dest")];
|
|
1142
1182
|
case 9:
|
|
1143
|
-
_j[_k] =
|
|
1144
|
-
|
|
1183
|
+
_j[_k] = _14.sent(); // SecFetchDest authentication
|
|
1184
|
+
_14.label = 10;
|
|
1145
1185
|
case 10:
|
|
1146
1186
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 12];
|
|
1147
1187
|
_l = headerParameters;
|
|
1148
|
-
_m = "Sec-
|
|
1149
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
1188
|
+
_m = "Sec-Ch-Ua-Platform";
|
|
1189
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Platform")];
|
|
1150
1190
|
case 11:
|
|
1151
|
-
_l[_m] =
|
|
1152
|
-
|
|
1191
|
+
_l[_m] = _14.sent(); // SecChUaPlatform authentication
|
|
1192
|
+
_14.label = 12;
|
|
1153
1193
|
case 12:
|
|
1154
1194
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 14];
|
|
1155
1195
|
_o = headerParameters;
|
|
1156
|
-
_p = "
|
|
1157
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1196
|
+
_p = "Sec-Fetch-Mode";
|
|
1197
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Mode")];
|
|
1158
1198
|
case 13:
|
|
1159
|
-
_o[_p] =
|
|
1160
|
-
|
|
1199
|
+
_o[_p] = _14.sent(); // SecFetchMode authentication
|
|
1200
|
+
_14.label = 14;
|
|
1161
1201
|
case 14:
|
|
1162
1202
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 16];
|
|
1163
1203
|
_q = headerParameters;
|
|
1164
|
-
_r = "x-
|
|
1165
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
1204
|
+
_r = "x-csrf-token";
|
|
1205
|
+
return [4 /*yield*/, this.configuration.apiKey("x-csrf-token")];
|
|
1166
1206
|
case 15:
|
|
1167
|
-
_q[_r] =
|
|
1168
|
-
|
|
1207
|
+
_q[_r] = _14.sent(); // CsrfToken authentication
|
|
1208
|
+
_14.label = 16;
|
|
1169
1209
|
case 16:
|
|
1170
|
-
if (!(this.configuration && this.configuration.
|
|
1210
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 18];
|
|
1211
|
+
_s = headerParameters;
|
|
1212
|
+
_t = "x-client-uuid";
|
|
1213
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-uuid")];
|
|
1214
|
+
case 17:
|
|
1215
|
+
_s[_t] = _14.sent(); // ClientUuid authentication
|
|
1216
|
+
_14.label = 18;
|
|
1217
|
+
case 18:
|
|
1218
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 20];
|
|
1171
1219
|
token = this.configuration.accessToken;
|
|
1172
1220
|
return [4 /*yield*/, token("BearerAuth", [])];
|
|
1173
|
-
case
|
|
1174
|
-
tokenString =
|
|
1221
|
+
case 19:
|
|
1222
|
+
tokenString = _14.sent();
|
|
1175
1223
|
if (tokenString) {
|
|
1176
1224
|
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
1177
1225
|
}
|
|
1178
|
-
|
|
1179
|
-
case 18:
|
|
1180
|
-
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 20];
|
|
1181
|
-
_s = headerParameters;
|
|
1182
|
-
_t = "x-guest-token";
|
|
1183
|
-
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
1184
|
-
case 19:
|
|
1185
|
-
_s[_t] = _12.sent(); // GuestToken authentication
|
|
1186
|
-
_12.label = 20;
|
|
1226
|
+
_14.label = 20;
|
|
1187
1227
|
case 20:
|
|
1188
1228
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 22];
|
|
1189
1229
|
_u = headerParameters;
|
|
1190
|
-
_v = "
|
|
1191
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1230
|
+
_v = "x-guest-token";
|
|
1231
|
+
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
1192
1232
|
case 21:
|
|
1193
|
-
_u[_v] =
|
|
1194
|
-
|
|
1233
|
+
_u[_v] = _14.sent(); // GuestToken authentication
|
|
1234
|
+
_14.label = 22;
|
|
1195
1235
|
case 22:
|
|
1196
1236
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 24];
|
|
1197
1237
|
_w = headerParameters;
|
|
1198
|
-
_x = "
|
|
1199
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1238
|
+
_x = "Sec-Ch-Ua";
|
|
1239
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua")];
|
|
1200
1240
|
case 23:
|
|
1201
|
-
_w[_x] =
|
|
1202
|
-
|
|
1241
|
+
_w[_x] = _14.sent(); // SecChUa authentication
|
|
1242
|
+
_14.label = 24;
|
|
1203
1243
|
case 24:
|
|
1204
1244
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 26];
|
|
1205
1245
|
_y = headerParameters;
|
|
1206
|
-
_z = "x-
|
|
1207
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
1246
|
+
_z = "x-client-transaction-id";
|
|
1247
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-transaction-id")];
|
|
1208
1248
|
case 25:
|
|
1209
|
-
_y[_z] =
|
|
1210
|
-
|
|
1249
|
+
_y[_z] = _14.sent(); // ClientTransactionId authentication
|
|
1250
|
+
_14.label = 26;
|
|
1211
1251
|
case 26:
|
|
1212
1252
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 28];
|
|
1213
1253
|
_0 = headerParameters;
|
|
1214
|
-
_1 = "user
|
|
1215
|
-
return [4 /*yield*/, this.configuration.apiKey("user
|
|
1254
|
+
_1 = "x-twitter-active-user";
|
|
1255
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-active-user")];
|
|
1216
1256
|
case 27:
|
|
1217
|
-
_0[_1] =
|
|
1218
|
-
|
|
1257
|
+
_0[_1] = _14.sent(); // ActiveUser authentication
|
|
1258
|
+
_14.label = 28;
|
|
1219
1259
|
case 28:
|
|
1220
1260
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 30];
|
|
1221
1261
|
_2 = headerParameters;
|
|
1222
|
-
_3 = "
|
|
1223
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1262
|
+
_3 = "user-agent";
|
|
1263
|
+
return [4 /*yield*/, this.configuration.apiKey("user-agent")];
|
|
1224
1264
|
case 29:
|
|
1225
|
-
_2[_3] =
|
|
1226
|
-
|
|
1265
|
+
_2[_3] = _14.sent(); // UserAgent authentication
|
|
1266
|
+
_14.label = 30;
|
|
1227
1267
|
case 30:
|
|
1228
1268
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 32];
|
|
1229
1269
|
_4 = headerParameters;
|
|
1230
|
-
_5 = "
|
|
1231
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1270
|
+
_5 = "Accept-Language";
|
|
1271
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Language")];
|
|
1232
1272
|
case 31:
|
|
1233
|
-
_4[_5] =
|
|
1234
|
-
|
|
1273
|
+
_4[_5] = _14.sent(); // AcceptLanguage authentication
|
|
1274
|
+
_14.label = 32;
|
|
1235
1275
|
case 32:
|
|
1236
1276
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 34];
|
|
1237
1277
|
_6 = headerParameters;
|
|
1238
|
-
_7 = "
|
|
1239
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1278
|
+
_7 = "Sec-Fetch-Site";
|
|
1279
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Site")];
|
|
1240
1280
|
case 33:
|
|
1241
|
-
_6[_7] =
|
|
1242
|
-
|
|
1281
|
+
_6[_7] = _14.sent(); // SecFetchSite authentication
|
|
1282
|
+
_14.label = 34;
|
|
1243
1283
|
case 34:
|
|
1244
1284
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 36];
|
|
1245
1285
|
_8 = headerParameters;
|
|
1246
|
-
_9 = "
|
|
1247
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1286
|
+
_9 = "x-twitter-auth-type";
|
|
1287
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-auth-type")];
|
|
1248
1288
|
case 35:
|
|
1249
|
-
_8[_9] =
|
|
1250
|
-
|
|
1289
|
+
_8[_9] = _14.sent(); // AuthType authentication
|
|
1290
|
+
_14.label = 36;
|
|
1251
1291
|
case 36:
|
|
1252
1292
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 38];
|
|
1253
1293
|
_10 = headerParameters;
|
|
1254
|
-
_11 = "
|
|
1255
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1294
|
+
_11 = "Sec-Ch-Ua-Mobile";
|
|
1295
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Mobile")];
|
|
1256
1296
|
case 37:
|
|
1257
|
-
_10[_11] =
|
|
1258
|
-
|
|
1259
|
-
case 38:
|
|
1297
|
+
_10[_11] = _14.sent(); // SecChUaMobile authentication
|
|
1298
|
+
_14.label = 38;
|
|
1299
|
+
case 38:
|
|
1300
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 40];
|
|
1301
|
+
_12 = headerParameters;
|
|
1302
|
+
_13 = "Accept-Encoding";
|
|
1303
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Encoding")];
|
|
1304
|
+
case 39:
|
|
1305
|
+
_12[_13] = _14.sent(); // AcceptEncoding authentication
|
|
1306
|
+
_14.label = 40;
|
|
1307
|
+
case 40: return [4 /*yield*/, this.request({
|
|
1260
1308
|
path: "/graphql/{pathQueryId}/DeleteTweet".replace("{".concat("pathQueryId", "}"), encodeURIComponent(String(requestParameters['pathQueryId']))),
|
|
1261
1309
|
method: 'POST',
|
|
1262
1310
|
headers: headerParameters,
|
|
1263
1311
|
query: queryParameters,
|
|
1264
1312
|
body: (0, index_1.PostDeleteTweetRequestToJSON)(requestParameters['postDeleteTweetRequest']),
|
|
1265
1313
|
}, initOverrides)];
|
|
1266
|
-
case
|
|
1267
|
-
response =
|
|
1314
|
+
case 41:
|
|
1315
|
+
response = _14.sent();
|
|
1268
1316
|
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.DeleteTweetResponseFromJSON)(jsonValue); })];
|
|
1269
1317
|
}
|
|
1270
1318
|
});
|
|
@@ -1292,9 +1340,9 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
1292
1340
|
*/
|
|
1293
1341
|
PostApi.prototype.postFavoriteTweetRaw = function (requestParameters, initOverrides) {
|
|
1294
1342
|
return __awaiter(this, void 0, void 0, function () {
|
|
1295
|
-
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r,
|
|
1296
|
-
return __generator(this, function (
|
|
1297
|
-
switch (
|
|
1343
|
+
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, token, tokenString, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, response;
|
|
1344
|
+
return __generator(this, function (_14) {
|
|
1345
|
+
switch (_14.label) {
|
|
1298
1346
|
case 0:
|
|
1299
1347
|
if (requestParameters['pathQueryId'] == null) {
|
|
1300
1348
|
throw new runtime.RequiredError('pathQueryId', 'Required parameter "pathQueryId" was null or undefined when calling postFavoriteTweet().');
|
|
@@ -1310,163 +1358,171 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
1310
1358
|
_b = "Accept";
|
|
1311
1359
|
return [4 /*yield*/, this.configuration.apiKey("Accept")];
|
|
1312
1360
|
case 1:
|
|
1313
|
-
_a[_b] =
|
|
1314
|
-
|
|
1361
|
+
_a[_b] = _14.sent(); // Accept authentication
|
|
1362
|
+
_14.label = 2;
|
|
1315
1363
|
case 2:
|
|
1316
1364
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 4];
|
|
1317
1365
|
_c = headerParameters;
|
|
1318
1366
|
_d = "x-twitter-client-language";
|
|
1319
1367
|
return [4 /*yield*/, this.configuration.apiKey("x-twitter-client-language")];
|
|
1320
1368
|
case 3:
|
|
1321
|
-
_c[_d] =
|
|
1322
|
-
|
|
1369
|
+
_c[_d] = _14.sent(); // ClientLanguage authentication
|
|
1370
|
+
_14.label = 4;
|
|
1323
1371
|
case 4:
|
|
1324
1372
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 6];
|
|
1325
1373
|
_e = headerParameters;
|
|
1326
|
-
_f = "
|
|
1327
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1374
|
+
_f = "Priority";
|
|
1375
|
+
return [4 /*yield*/, this.configuration.apiKey("Priority")];
|
|
1328
1376
|
case 5:
|
|
1329
|
-
_e[_f] =
|
|
1330
|
-
|
|
1377
|
+
_e[_f] = _14.sent(); // Priority authentication
|
|
1378
|
+
_14.label = 6;
|
|
1331
1379
|
case 6:
|
|
1332
1380
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 8];
|
|
1333
1381
|
_g = headerParameters;
|
|
1334
|
-
_h = "
|
|
1335
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1382
|
+
_h = "Referer";
|
|
1383
|
+
return [4 /*yield*/, this.configuration.apiKey("Referer")];
|
|
1336
1384
|
case 7:
|
|
1337
|
-
_g[_h] =
|
|
1338
|
-
|
|
1385
|
+
_g[_h] = _14.sent(); // Referer authentication
|
|
1386
|
+
_14.label = 8;
|
|
1339
1387
|
case 8:
|
|
1340
1388
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 10];
|
|
1341
1389
|
_j = headerParameters;
|
|
1342
|
-
_k = "Sec-
|
|
1343
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
1390
|
+
_k = "Sec-Fetch-Dest";
|
|
1391
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Dest")];
|
|
1344
1392
|
case 9:
|
|
1345
|
-
_j[_k] =
|
|
1346
|
-
|
|
1393
|
+
_j[_k] = _14.sent(); // SecFetchDest authentication
|
|
1394
|
+
_14.label = 10;
|
|
1347
1395
|
case 10:
|
|
1348
1396
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 12];
|
|
1349
1397
|
_l = headerParameters;
|
|
1350
|
-
_m = "Sec-
|
|
1351
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
1398
|
+
_m = "Sec-Ch-Ua-Platform";
|
|
1399
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Platform")];
|
|
1352
1400
|
case 11:
|
|
1353
|
-
_l[_m] =
|
|
1354
|
-
|
|
1401
|
+
_l[_m] = _14.sent(); // SecChUaPlatform authentication
|
|
1402
|
+
_14.label = 12;
|
|
1355
1403
|
case 12:
|
|
1356
1404
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 14];
|
|
1357
1405
|
_o = headerParameters;
|
|
1358
|
-
_p = "
|
|
1359
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1406
|
+
_p = "Sec-Fetch-Mode";
|
|
1407
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Mode")];
|
|
1360
1408
|
case 13:
|
|
1361
|
-
_o[_p] =
|
|
1362
|
-
|
|
1409
|
+
_o[_p] = _14.sent(); // SecFetchMode authentication
|
|
1410
|
+
_14.label = 14;
|
|
1363
1411
|
case 14:
|
|
1364
1412
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 16];
|
|
1365
1413
|
_q = headerParameters;
|
|
1366
|
-
_r = "x-
|
|
1367
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
1414
|
+
_r = "x-csrf-token";
|
|
1415
|
+
return [4 /*yield*/, this.configuration.apiKey("x-csrf-token")];
|
|
1368
1416
|
case 15:
|
|
1369
|
-
_q[_r] =
|
|
1370
|
-
|
|
1417
|
+
_q[_r] = _14.sent(); // CsrfToken authentication
|
|
1418
|
+
_14.label = 16;
|
|
1371
1419
|
case 16:
|
|
1372
|
-
if (!(this.configuration && this.configuration.
|
|
1420
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 18];
|
|
1421
|
+
_s = headerParameters;
|
|
1422
|
+
_t = "x-client-uuid";
|
|
1423
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-uuid")];
|
|
1424
|
+
case 17:
|
|
1425
|
+
_s[_t] = _14.sent(); // ClientUuid authentication
|
|
1426
|
+
_14.label = 18;
|
|
1427
|
+
case 18:
|
|
1428
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 20];
|
|
1373
1429
|
token = this.configuration.accessToken;
|
|
1374
1430
|
return [4 /*yield*/, token("BearerAuth", [])];
|
|
1375
|
-
case
|
|
1376
|
-
tokenString =
|
|
1431
|
+
case 19:
|
|
1432
|
+
tokenString = _14.sent();
|
|
1377
1433
|
if (tokenString) {
|
|
1378
1434
|
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
1379
1435
|
}
|
|
1380
|
-
|
|
1381
|
-
case 18:
|
|
1382
|
-
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 20];
|
|
1383
|
-
_s = headerParameters;
|
|
1384
|
-
_t = "x-guest-token";
|
|
1385
|
-
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
1386
|
-
case 19:
|
|
1387
|
-
_s[_t] = _12.sent(); // GuestToken authentication
|
|
1388
|
-
_12.label = 20;
|
|
1436
|
+
_14.label = 20;
|
|
1389
1437
|
case 20:
|
|
1390
1438
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 22];
|
|
1391
1439
|
_u = headerParameters;
|
|
1392
|
-
_v = "
|
|
1393
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1440
|
+
_v = "x-guest-token";
|
|
1441
|
+
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
1394
1442
|
case 21:
|
|
1395
|
-
_u[_v] =
|
|
1396
|
-
|
|
1443
|
+
_u[_v] = _14.sent(); // GuestToken authentication
|
|
1444
|
+
_14.label = 22;
|
|
1397
1445
|
case 22:
|
|
1398
1446
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 24];
|
|
1399
1447
|
_w = headerParameters;
|
|
1400
|
-
_x = "
|
|
1401
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1448
|
+
_x = "Sec-Ch-Ua";
|
|
1449
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua")];
|
|
1402
1450
|
case 23:
|
|
1403
|
-
_w[_x] =
|
|
1404
|
-
|
|
1451
|
+
_w[_x] = _14.sent(); // SecChUa authentication
|
|
1452
|
+
_14.label = 24;
|
|
1405
1453
|
case 24:
|
|
1406
1454
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 26];
|
|
1407
1455
|
_y = headerParameters;
|
|
1408
|
-
_z = "x-
|
|
1409
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
1456
|
+
_z = "x-client-transaction-id";
|
|
1457
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-transaction-id")];
|
|
1410
1458
|
case 25:
|
|
1411
|
-
_y[_z] =
|
|
1412
|
-
|
|
1459
|
+
_y[_z] = _14.sent(); // ClientTransactionId authentication
|
|
1460
|
+
_14.label = 26;
|
|
1413
1461
|
case 26:
|
|
1414
1462
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 28];
|
|
1415
1463
|
_0 = headerParameters;
|
|
1416
|
-
_1 = "user
|
|
1417
|
-
return [4 /*yield*/, this.configuration.apiKey("user
|
|
1464
|
+
_1 = "x-twitter-active-user";
|
|
1465
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-active-user")];
|
|
1418
1466
|
case 27:
|
|
1419
|
-
_0[_1] =
|
|
1420
|
-
|
|
1467
|
+
_0[_1] = _14.sent(); // ActiveUser authentication
|
|
1468
|
+
_14.label = 28;
|
|
1421
1469
|
case 28:
|
|
1422
1470
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 30];
|
|
1423
1471
|
_2 = headerParameters;
|
|
1424
|
-
_3 = "
|
|
1425
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1472
|
+
_3 = "user-agent";
|
|
1473
|
+
return [4 /*yield*/, this.configuration.apiKey("user-agent")];
|
|
1426
1474
|
case 29:
|
|
1427
|
-
_2[_3] =
|
|
1428
|
-
|
|
1475
|
+
_2[_3] = _14.sent(); // UserAgent authentication
|
|
1476
|
+
_14.label = 30;
|
|
1429
1477
|
case 30:
|
|
1430
1478
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 32];
|
|
1431
1479
|
_4 = headerParameters;
|
|
1432
|
-
_5 = "
|
|
1433
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1480
|
+
_5 = "Accept-Language";
|
|
1481
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Language")];
|
|
1434
1482
|
case 31:
|
|
1435
|
-
_4[_5] =
|
|
1436
|
-
|
|
1483
|
+
_4[_5] = _14.sent(); // AcceptLanguage authentication
|
|
1484
|
+
_14.label = 32;
|
|
1437
1485
|
case 32:
|
|
1438
1486
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 34];
|
|
1439
1487
|
_6 = headerParameters;
|
|
1440
|
-
_7 = "
|
|
1441
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1488
|
+
_7 = "Sec-Fetch-Site";
|
|
1489
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Site")];
|
|
1442
1490
|
case 33:
|
|
1443
|
-
_6[_7] =
|
|
1444
|
-
|
|
1491
|
+
_6[_7] = _14.sent(); // SecFetchSite authentication
|
|
1492
|
+
_14.label = 34;
|
|
1445
1493
|
case 34:
|
|
1446
1494
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 36];
|
|
1447
1495
|
_8 = headerParameters;
|
|
1448
|
-
_9 = "
|
|
1449
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1496
|
+
_9 = "x-twitter-auth-type";
|
|
1497
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-auth-type")];
|
|
1450
1498
|
case 35:
|
|
1451
|
-
_8[_9] =
|
|
1452
|
-
|
|
1499
|
+
_8[_9] = _14.sent(); // AuthType authentication
|
|
1500
|
+
_14.label = 36;
|
|
1453
1501
|
case 36:
|
|
1454
1502
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 38];
|
|
1455
1503
|
_10 = headerParameters;
|
|
1456
|
-
_11 = "
|
|
1457
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1504
|
+
_11 = "Sec-Ch-Ua-Mobile";
|
|
1505
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Mobile")];
|
|
1458
1506
|
case 37:
|
|
1459
|
-
_10[_11] =
|
|
1460
|
-
|
|
1461
|
-
case 38:
|
|
1507
|
+
_10[_11] = _14.sent(); // SecChUaMobile authentication
|
|
1508
|
+
_14.label = 38;
|
|
1509
|
+
case 38:
|
|
1510
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 40];
|
|
1511
|
+
_12 = headerParameters;
|
|
1512
|
+
_13 = "Accept-Encoding";
|
|
1513
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Encoding")];
|
|
1514
|
+
case 39:
|
|
1515
|
+
_12[_13] = _14.sent(); // AcceptEncoding authentication
|
|
1516
|
+
_14.label = 40;
|
|
1517
|
+
case 40: return [4 /*yield*/, this.request({
|
|
1462
1518
|
path: "/graphql/{pathQueryId}/FavoriteTweet".replace("{".concat("pathQueryId", "}"), encodeURIComponent(String(requestParameters['pathQueryId']))),
|
|
1463
1519
|
method: 'POST',
|
|
1464
1520
|
headers: headerParameters,
|
|
1465
1521
|
query: queryParameters,
|
|
1466
1522
|
body: (0, index_1.PostFavoriteTweetRequestToJSON)(requestParameters['postFavoriteTweetRequest']),
|
|
1467
1523
|
}, initOverrides)];
|
|
1468
|
-
case
|
|
1469
|
-
response =
|
|
1524
|
+
case 41:
|
|
1525
|
+
response = _14.sent();
|
|
1470
1526
|
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.FavoriteTweetResponseFromJSON)(jsonValue); })];
|
|
1471
1527
|
}
|
|
1472
1528
|
});
|
|
@@ -1494,9 +1550,9 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
1494
1550
|
*/
|
|
1495
1551
|
PostApi.prototype.postUnfavoriteTweetRaw = function (requestParameters, initOverrides) {
|
|
1496
1552
|
return __awaiter(this, void 0, void 0, function () {
|
|
1497
|
-
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r,
|
|
1498
|
-
return __generator(this, function (
|
|
1499
|
-
switch (
|
|
1553
|
+
var queryParameters, headerParameters, _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, token, tokenString, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, response;
|
|
1554
|
+
return __generator(this, function (_14) {
|
|
1555
|
+
switch (_14.label) {
|
|
1500
1556
|
case 0:
|
|
1501
1557
|
if (requestParameters['pathQueryId'] == null) {
|
|
1502
1558
|
throw new runtime.RequiredError('pathQueryId', 'Required parameter "pathQueryId" was null or undefined when calling postUnfavoriteTweet().');
|
|
@@ -1512,163 +1568,171 @@ var PostApi = /** @class */ (function (_super) {
|
|
|
1512
1568
|
_b = "Accept";
|
|
1513
1569
|
return [4 /*yield*/, this.configuration.apiKey("Accept")];
|
|
1514
1570
|
case 1:
|
|
1515
|
-
_a[_b] =
|
|
1516
|
-
|
|
1571
|
+
_a[_b] = _14.sent(); // Accept authentication
|
|
1572
|
+
_14.label = 2;
|
|
1517
1573
|
case 2:
|
|
1518
1574
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 4];
|
|
1519
1575
|
_c = headerParameters;
|
|
1520
1576
|
_d = "x-twitter-client-language";
|
|
1521
1577
|
return [4 /*yield*/, this.configuration.apiKey("x-twitter-client-language")];
|
|
1522
1578
|
case 3:
|
|
1523
|
-
_c[_d] =
|
|
1524
|
-
|
|
1579
|
+
_c[_d] = _14.sent(); // ClientLanguage authentication
|
|
1580
|
+
_14.label = 4;
|
|
1525
1581
|
case 4:
|
|
1526
1582
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 6];
|
|
1527
1583
|
_e = headerParameters;
|
|
1528
|
-
_f = "
|
|
1529
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1584
|
+
_f = "Priority";
|
|
1585
|
+
return [4 /*yield*/, this.configuration.apiKey("Priority")];
|
|
1530
1586
|
case 5:
|
|
1531
|
-
_e[_f] =
|
|
1532
|
-
|
|
1587
|
+
_e[_f] = _14.sent(); // Priority authentication
|
|
1588
|
+
_14.label = 6;
|
|
1533
1589
|
case 6:
|
|
1534
1590
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 8];
|
|
1535
1591
|
_g = headerParameters;
|
|
1536
|
-
_h = "
|
|
1537
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1592
|
+
_h = "Referer";
|
|
1593
|
+
return [4 /*yield*/, this.configuration.apiKey("Referer")];
|
|
1538
1594
|
case 7:
|
|
1539
|
-
_g[_h] =
|
|
1540
|
-
|
|
1595
|
+
_g[_h] = _14.sent(); // Referer authentication
|
|
1596
|
+
_14.label = 8;
|
|
1541
1597
|
case 8:
|
|
1542
1598
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 10];
|
|
1543
1599
|
_j = headerParameters;
|
|
1544
|
-
_k = "Sec-
|
|
1545
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
1600
|
+
_k = "Sec-Fetch-Dest";
|
|
1601
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Dest")];
|
|
1546
1602
|
case 9:
|
|
1547
|
-
_j[_k] =
|
|
1548
|
-
|
|
1603
|
+
_j[_k] = _14.sent(); // SecFetchDest authentication
|
|
1604
|
+
_14.label = 10;
|
|
1549
1605
|
case 10:
|
|
1550
1606
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 12];
|
|
1551
1607
|
_l = headerParameters;
|
|
1552
|
-
_m = "Sec-
|
|
1553
|
-
return [4 /*yield*/, this.configuration.apiKey("Sec-
|
|
1608
|
+
_m = "Sec-Ch-Ua-Platform";
|
|
1609
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Platform")];
|
|
1554
1610
|
case 11:
|
|
1555
|
-
_l[_m] =
|
|
1556
|
-
|
|
1611
|
+
_l[_m] = _14.sent(); // SecChUaPlatform authentication
|
|
1612
|
+
_14.label = 12;
|
|
1557
1613
|
case 12:
|
|
1558
1614
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 14];
|
|
1559
1615
|
_o = headerParameters;
|
|
1560
|
-
_p = "
|
|
1561
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1616
|
+
_p = "Sec-Fetch-Mode";
|
|
1617
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Mode")];
|
|
1562
1618
|
case 13:
|
|
1563
|
-
_o[_p] =
|
|
1564
|
-
|
|
1619
|
+
_o[_p] = _14.sent(); // SecFetchMode authentication
|
|
1620
|
+
_14.label = 14;
|
|
1565
1621
|
case 14:
|
|
1566
1622
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 16];
|
|
1567
1623
|
_q = headerParameters;
|
|
1568
|
-
_r = "x-
|
|
1569
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
1624
|
+
_r = "x-csrf-token";
|
|
1625
|
+
return [4 /*yield*/, this.configuration.apiKey("x-csrf-token")];
|
|
1570
1626
|
case 15:
|
|
1571
|
-
_q[_r] =
|
|
1572
|
-
|
|
1627
|
+
_q[_r] = _14.sent(); // CsrfToken authentication
|
|
1628
|
+
_14.label = 16;
|
|
1573
1629
|
case 16:
|
|
1574
|
-
if (!(this.configuration && this.configuration.
|
|
1630
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 18];
|
|
1631
|
+
_s = headerParameters;
|
|
1632
|
+
_t = "x-client-uuid";
|
|
1633
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-uuid")];
|
|
1634
|
+
case 17:
|
|
1635
|
+
_s[_t] = _14.sent(); // ClientUuid authentication
|
|
1636
|
+
_14.label = 18;
|
|
1637
|
+
case 18:
|
|
1638
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 20];
|
|
1575
1639
|
token = this.configuration.accessToken;
|
|
1576
1640
|
return [4 /*yield*/, token("BearerAuth", [])];
|
|
1577
|
-
case
|
|
1578
|
-
tokenString =
|
|
1641
|
+
case 19:
|
|
1642
|
+
tokenString = _14.sent();
|
|
1579
1643
|
if (tokenString) {
|
|
1580
1644
|
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
1581
1645
|
}
|
|
1582
|
-
|
|
1583
|
-
case 18:
|
|
1584
|
-
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 20];
|
|
1585
|
-
_s = headerParameters;
|
|
1586
|
-
_t = "x-guest-token";
|
|
1587
|
-
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
1588
|
-
case 19:
|
|
1589
|
-
_s[_t] = _12.sent(); // GuestToken authentication
|
|
1590
|
-
_12.label = 20;
|
|
1646
|
+
_14.label = 20;
|
|
1591
1647
|
case 20:
|
|
1592
1648
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 22];
|
|
1593
1649
|
_u = headerParameters;
|
|
1594
|
-
_v = "
|
|
1595
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1650
|
+
_v = "x-guest-token";
|
|
1651
|
+
return [4 /*yield*/, this.configuration.apiKey("x-guest-token")];
|
|
1596
1652
|
case 21:
|
|
1597
|
-
_u[_v] =
|
|
1598
|
-
|
|
1653
|
+
_u[_v] = _14.sent(); // GuestToken authentication
|
|
1654
|
+
_14.label = 22;
|
|
1599
1655
|
case 22:
|
|
1600
1656
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 24];
|
|
1601
1657
|
_w = headerParameters;
|
|
1602
|
-
_x = "
|
|
1603
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1658
|
+
_x = "Sec-Ch-Ua";
|
|
1659
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua")];
|
|
1604
1660
|
case 23:
|
|
1605
|
-
_w[_x] =
|
|
1606
|
-
|
|
1661
|
+
_w[_x] = _14.sent(); // SecChUa authentication
|
|
1662
|
+
_14.label = 24;
|
|
1607
1663
|
case 24:
|
|
1608
1664
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 26];
|
|
1609
1665
|
_y = headerParameters;
|
|
1610
|
-
_z = "x-
|
|
1611
|
-
return [4 /*yield*/, this.configuration.apiKey("x-
|
|
1666
|
+
_z = "x-client-transaction-id";
|
|
1667
|
+
return [4 /*yield*/, this.configuration.apiKey("x-client-transaction-id")];
|
|
1612
1668
|
case 25:
|
|
1613
|
-
_y[_z] =
|
|
1614
|
-
|
|
1669
|
+
_y[_z] = _14.sent(); // ClientTransactionId authentication
|
|
1670
|
+
_14.label = 26;
|
|
1615
1671
|
case 26:
|
|
1616
1672
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 28];
|
|
1617
1673
|
_0 = headerParameters;
|
|
1618
|
-
_1 = "user
|
|
1619
|
-
return [4 /*yield*/, this.configuration.apiKey("user
|
|
1674
|
+
_1 = "x-twitter-active-user";
|
|
1675
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-active-user")];
|
|
1620
1676
|
case 27:
|
|
1621
|
-
_0[_1] =
|
|
1622
|
-
|
|
1677
|
+
_0[_1] = _14.sent(); // ActiveUser authentication
|
|
1678
|
+
_14.label = 28;
|
|
1623
1679
|
case 28:
|
|
1624
1680
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 30];
|
|
1625
1681
|
_2 = headerParameters;
|
|
1626
|
-
_3 = "
|
|
1627
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1682
|
+
_3 = "user-agent";
|
|
1683
|
+
return [4 /*yield*/, this.configuration.apiKey("user-agent")];
|
|
1628
1684
|
case 29:
|
|
1629
|
-
_2[_3] =
|
|
1630
|
-
|
|
1685
|
+
_2[_3] = _14.sent(); // UserAgent authentication
|
|
1686
|
+
_14.label = 30;
|
|
1631
1687
|
case 30:
|
|
1632
1688
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 32];
|
|
1633
1689
|
_4 = headerParameters;
|
|
1634
|
-
_5 = "
|
|
1635
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1690
|
+
_5 = "Accept-Language";
|
|
1691
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Language")];
|
|
1636
1692
|
case 31:
|
|
1637
|
-
_4[_5] =
|
|
1638
|
-
|
|
1693
|
+
_4[_5] = _14.sent(); // AcceptLanguage authentication
|
|
1694
|
+
_14.label = 32;
|
|
1639
1695
|
case 32:
|
|
1640
1696
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 34];
|
|
1641
1697
|
_6 = headerParameters;
|
|
1642
|
-
_7 = "
|
|
1643
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1698
|
+
_7 = "Sec-Fetch-Site";
|
|
1699
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Fetch-Site")];
|
|
1644
1700
|
case 33:
|
|
1645
|
-
_6[_7] =
|
|
1646
|
-
|
|
1701
|
+
_6[_7] = _14.sent(); // SecFetchSite authentication
|
|
1702
|
+
_14.label = 34;
|
|
1647
1703
|
case 34:
|
|
1648
1704
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 36];
|
|
1649
1705
|
_8 = headerParameters;
|
|
1650
|
-
_9 = "
|
|
1651
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1706
|
+
_9 = "x-twitter-auth-type";
|
|
1707
|
+
return [4 /*yield*/, this.configuration.apiKey("x-twitter-auth-type")];
|
|
1652
1708
|
case 35:
|
|
1653
|
-
_8[_9] =
|
|
1654
|
-
|
|
1709
|
+
_8[_9] = _14.sent(); // AuthType authentication
|
|
1710
|
+
_14.label = 36;
|
|
1655
1711
|
case 36:
|
|
1656
1712
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 38];
|
|
1657
1713
|
_10 = headerParameters;
|
|
1658
|
-
_11 = "
|
|
1659
|
-
return [4 /*yield*/, this.configuration.apiKey("
|
|
1714
|
+
_11 = "Sec-Ch-Ua-Mobile";
|
|
1715
|
+
return [4 /*yield*/, this.configuration.apiKey("Sec-Ch-Ua-Mobile")];
|
|
1660
1716
|
case 37:
|
|
1661
|
-
_10[_11] =
|
|
1662
|
-
|
|
1663
|
-
case 38:
|
|
1717
|
+
_10[_11] = _14.sent(); // SecChUaMobile authentication
|
|
1718
|
+
_14.label = 38;
|
|
1719
|
+
case 38:
|
|
1720
|
+
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 40];
|
|
1721
|
+
_12 = headerParameters;
|
|
1722
|
+
_13 = "Accept-Encoding";
|
|
1723
|
+
return [4 /*yield*/, this.configuration.apiKey("Accept-Encoding")];
|
|
1724
|
+
case 39:
|
|
1725
|
+
_12[_13] = _14.sent(); // AcceptEncoding authentication
|
|
1726
|
+
_14.label = 40;
|
|
1727
|
+
case 40: return [4 /*yield*/, this.request({
|
|
1664
1728
|
path: "/graphql/{pathQueryId}/UnfavoriteTweet".replace("{".concat("pathQueryId", "}"), encodeURIComponent(String(requestParameters['pathQueryId']))),
|
|
1665
1729
|
method: 'POST',
|
|
1666
1730
|
headers: headerParameters,
|
|
1667
1731
|
query: queryParameters,
|
|
1668
1732
|
body: (0, index_1.PostUnfavoriteTweetRequestToJSON)(requestParameters['postUnfavoriteTweetRequest']),
|
|
1669
1733
|
}, initOverrides)];
|
|
1670
|
-
case
|
|
1671
|
-
response =
|
|
1734
|
+
case 41:
|
|
1735
|
+
response = _14.sent();
|
|
1672
1736
|
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.UnfavoriteTweetResponseFromJSON)(jsonValue); })];
|
|
1673
1737
|
}
|
|
1674
1738
|
});
|