twitter-openapi-typescript-generated 0.0.11 → 0.0.13
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/.openapi-generator/FILES +18 -0
- package/LICENSE +31 -31
- package/LICENSE.AGPL +660 -660
- package/README.md +2 -2
- package/dist/apis/DefaultApi.d.ts.map +1 -1
- package/dist/apis/DefaultApi.js +86 -18
- package/dist/apis/DefaultApi.js.map +1 -1
- package/dist/apis/OtherApi.d.ts.map +1 -1
- package/dist/apis/OtherApi.js +43 -9
- package/dist/apis/OtherApi.js.map +1 -1
- package/dist/apis/PostApi.d.ts.map +1 -1
- package/dist/apis/PostApi.js +264 -60
- package/dist/apis/PostApi.js.map +1 -1
- package/dist/apis/TweetApi.d.ts +1 -2
- package/dist/apis/TweetApi.d.ts.map +1 -1
- package/dist/apis/TweetApi.js +479 -111
- package/dist/apis/TweetApi.js.map +1 -1
- package/dist/apis/UserApi.d.ts +1 -0
- package/dist/apis/UserApi.d.ts.map +1 -1
- package/dist/apis/UserApi.js +92 -18
- package/dist/apis/UserApi.js.map +1 -1
- package/dist/apis/UserListApi.d.ts +0 -1
- package/dist/apis/UserListApi.d.ts.map +1 -1
- package/dist/apis/UserListApi.js +215 -51
- package/dist/apis/UserListApi.js.map +1 -1
- package/dist/apis/UsersApi.d.ts.map +1 -1
- package/dist/apis/UsersApi.js +43 -9
- package/dist/apis/UsersApi.js.map +1 -1
- package/dist/apis/V11GetApi.d.ts.map +1 -1
- package/dist/apis/V11GetApi.js +86 -18
- package/dist/apis/V11GetApi.js.map +1 -1
- package/dist/apis/V11PostApi.d.ts.map +1 -1
- package/dist/apis/V11PostApi.js +72 -6
- package/dist/apis/V11PostApi.js.map +1 -1
- package/dist/apis/V20GetApi.d.ts.map +1 -1
- package/dist/apis/V20GetApi.js +43 -9
- package/dist/apis/V20GetApi.js.map +1 -1
- package/dist/models/BirdwatchEntity.d.ts +45 -0
- package/dist/models/BirdwatchEntity.d.ts.map +1 -0
- package/dist/models/BirdwatchEntity.js +58 -0
- package/dist/models/BirdwatchEntity.js.map +1 -0
- package/dist/models/BirdwatchEntityRef.d.ts +58 -0
- package/dist/models/BirdwatchEntityRef.d.ts.map +1 -0
- package/dist/models/BirdwatchEntityRef.js +69 -0
- package/dist/models/BirdwatchEntityRef.js.map +1 -0
- package/dist/models/BirdwatchPivot.d.ts +91 -0
- package/dist/models/BirdwatchPivot.d.ts.map +1 -0
- package/dist/models/BirdwatchPivot.js +87 -0
- package/dist/models/BirdwatchPivot.js.map +1 -0
- package/dist/models/BirdwatchPivotFooter.d.ts +39 -0
- package/dist/models/BirdwatchPivotFooter.d.ts.map +1 -0
- package/dist/models/BirdwatchPivotFooter.js +55 -0
- package/dist/models/BirdwatchPivotFooter.js.map +1 -0
- package/dist/models/BirdwatchPivotNote.d.ts +32 -0
- package/dist/models/BirdwatchPivotNote.d.ts.map +1 -0
- package/dist/models/BirdwatchPivotNote.js +51 -0
- package/dist/models/BirdwatchPivotNote.js.map +1 -0
- package/dist/models/BirdwatchPivotSubtitle.d.ts +39 -0
- package/dist/models/BirdwatchPivotSubtitle.d.ts.map +1 -0
- package/dist/models/BirdwatchPivotSubtitle.js +55 -0
- package/dist/models/BirdwatchPivotSubtitle.js.map +1 -0
- package/dist/models/ContentItemType.d.ts +1 -0
- package/dist/models/ContentItemType.d.ts.map +1 -1
- package/dist/models/ContentItemType.js +2 -1
- package/dist/models/ContentItemType.js.map +1 -1
- package/dist/models/CoverCta.d.ts +1 -1
- package/dist/models/CoverCta.d.ts.map +1 -1
- package/dist/models/CoverCta.js +1 -2
- package/dist/models/CoverCta.js.map +1 -1
- package/dist/models/DeleteRetweet.d.ts +33 -0
- package/dist/models/DeleteRetweet.d.ts.map +1 -0
- package/dist/models/DeleteRetweet.js +52 -0
- package/dist/models/DeleteRetweet.js.map +1 -0
- package/dist/models/DeleteRetweetResponseResult.d.ts +33 -0
- package/dist/models/DeleteRetweetResponseResult.d.ts.map +1 -0
- package/dist/models/DeleteRetweetResponseResult.js +52 -0
- package/dist/models/DeleteRetweetResponseResult.js.map +1 -0
- package/dist/models/ErrorResponse.d.ts +33 -0
- package/dist/models/ErrorResponse.d.ts.map +1 -0
- package/dist/models/ErrorResponse.js +52 -0
- package/dist/models/ErrorResponse.js.map +1 -0
- package/dist/models/ExtMediaAvailability.d.ts +7 -0
- package/dist/models/ExtMediaAvailability.d.ts.map +1 -1
- package/dist/models/ExtMediaAvailability.js +4 -1
- package/dist/models/ExtMediaAvailability.js.map +1 -1
- package/dist/models/Extensions.d.ts +57 -0
- package/dist/models/Extensions.d.ts.map +1 -0
- package/dist/models/Extensions.js +64 -0
- package/dist/models/Extensions.js.map +1 -0
- package/dist/models/ItemContentUnion.d.ts +3 -0
- package/dist/models/ItemContentUnion.d.ts.map +1 -1
- package/dist/models/ItemContentUnion.js +5 -0
- package/dist/models/ItemContentUnion.js.map +1 -1
- package/dist/models/ListTweetsTimeline.d.ts +1 -1
- package/dist/models/ListTweetsTimeline.d.ts.map +1 -1
- package/dist/models/ListTweetsTimeline.js +2 -2
- package/dist/models/ListTweetsTimeline.js.map +1 -1
- package/dist/models/MediaExtended.d.ts +1 -1
- package/dist/models/MediaExtended.d.ts.map +1 -1
- package/dist/models/MediaExtended.js +1 -2
- package/dist/models/MediaExtended.js.map +1 -1
- package/dist/models/NoteTweet.d.ts +39 -0
- package/dist/models/NoteTweet.d.ts.map +1 -0
- package/dist/models/NoteTweet.js +55 -0
- package/dist/models/NoteTweet.js.map +1 -0
- package/dist/models/NoteTweetResult.d.ts +33 -0
- package/dist/models/NoteTweetResult.d.ts.map +1 -0
- package/dist/models/NoteTweetResult.js +52 -0
- package/dist/models/NoteTweetResult.js.map +1 -0
- package/dist/models/NoteTweetResultData.d.ts +59 -0
- package/dist/models/NoteTweetResultData.d.ts.map +1 -0
- package/dist/models/NoteTweetResultData.js +65 -0
- package/dist/models/NoteTweetResultData.js.map +1 -0
- package/dist/models/NoteTweetResultMedia.d.ts +32 -0
- package/dist/models/NoteTweetResultMedia.d.ts.map +1 -0
- package/dist/models/NoteTweetResultMedia.js +51 -0
- package/dist/models/NoteTweetResultMedia.js.map +1 -0
- package/dist/models/NoteTweetResultRichText.d.ts +33 -0
- package/dist/models/NoteTweetResultRichText.d.ts.map +1 -0
- package/dist/models/NoteTweetResultRichText.js +52 -0
- package/dist/models/NoteTweetResultRichText.js.map +1 -0
- package/dist/models/NoteTweetResultRichTextTag.d.ts +52 -0
- package/dist/models/NoteTweetResultRichTextTag.d.ts.map +1 -0
- package/dist/models/NoteTweetResultRichTextTag.js +64 -0
- package/dist/models/NoteTweetResultRichTextTag.js.map +1 -0
- package/dist/models/PostCreateTweetRequestFeatures.d.ts +9 -15
- package/dist/models/PostCreateTweetRequestFeatures.d.ts.map +1 -1
- package/dist/models/PostCreateTweetRequestFeatures.js +9 -12
- package/dist/models/PostCreateTweetRequestFeatures.js.map +1 -1
- package/dist/models/PostCreateTweetRequestVariablesMedia.d.ts +3 -2
- package/dist/models/PostCreateTweetRequestVariablesMedia.d.ts.map +1 -1
- package/dist/models/PostCreateTweetRequestVariablesMedia.js +3 -2
- package/dist/models/PostCreateTweetRequestVariablesMedia.js.map +1 -1
- package/dist/models/PostCreateTweetRequestVariablesMediaMediaEntitiesInner.d.ts +38 -0
- package/dist/models/PostCreateTweetRequestVariablesMediaMediaEntitiesInner.d.ts.map +1 -0
- package/dist/models/PostCreateTweetRequestVariablesMediaMediaEntitiesInner.js +54 -0
- package/dist/models/PostCreateTweetRequestVariablesMediaMediaEntitiesInner.js.map +1 -0
- package/dist/models/TimelineCommunity.d.ts +34 -0
- package/dist/models/TimelineCommunity.d.ts.map +1 -0
- package/dist/models/TimelineCommunity.js +59 -0
- package/dist/models/TimelineCommunity.js.map +1 -0
- package/dist/models/Tweet.d.ts +20 -0
- package/dist/models/Tweet.d.ts.map +1 -1
- package/dist/models/Tweet.js +8 -0
- package/dist/models/Tweet.js.map +1 -1
- package/dist/models/TypeName.d.ts +1 -0
- package/dist/models/TypeName.d.ts.map +1 -1
- package/dist/models/TypeName.js +1 -0
- package/dist/models/TypeName.js.map +1 -1
- package/dist/models/UserResults.d.ts +1 -1
- package/dist/models/UserResults.d.ts.map +1 -1
- package/dist/models/UserResults.js +2 -2
- package/dist/models/UserResults.js.map +1 -1
- package/dist/models/index.d.ts +18 -0
- package/dist/models/index.d.ts.map +1 -1
- package/dist/models/index.js +18 -0
- package/dist/models/index.js.map +1 -1
- package/package.json +2 -3
- package/src/apis/DefaultApi.ts +94 -6
- package/src/apis/OtherApi.ts +47 -3
- package/src/apis/PostApi.ts +282 -18
- package/src/apis/TweetApi.ts +526 -51
- package/src/apis/UserApi.ts +103 -6
- package/src/apis/UserListApi.ts +235 -24
- package/src/apis/UsersApi.ts +47 -3
- package/src/apis/V11GetApi.ts +94 -6
- package/src/apis/V11PostApi.ts +94 -6
- package/src/apis/V20GetApi.ts +47 -3
- package/src/models/BirdwatchEntity.ts +91 -0
- package/src/models/BirdwatchEntityRef.ts +102 -0
- package/src/models/BirdwatchPivot.ts +165 -0
- package/src/models/BirdwatchPivotFooter.ts +82 -0
- package/src/models/BirdwatchPivotNote.ts +66 -0
- package/src/models/BirdwatchPivotSubtitle.ts +82 -0
- package/src/models/ContentItemType.ts +2 -1
- package/src/models/CoverCta.ts +2 -3
- package/src/models/DeleteRetweet.ts +73 -0
- package/src/models/DeleteRetweetResponseResult.ts +72 -0
- package/src/models/ErrorResponse.ts +73 -0
- package/src/models/ExtMediaAvailability.ts +10 -1
- package/src/models/Extensions.ts +109 -0
- package/src/models/ItemContentUnion.ts +12 -1
- package/src/models/ListTweetsTimeline.ts +2 -3
- package/src/models/MediaExtended.ts +2 -3
- package/src/models/NoteTweet.ts +82 -0
- package/src/models/NoteTweetResult.ts +73 -0
- package/src/models/NoteTweetResultData.ts +119 -0
- package/src/models/NoteTweetResultMedia.ts +66 -0
- package/src/models/NoteTweetResultRichText.ts +73 -0
- package/src/models/NoteTweetResultRichTextTag.ts +95 -0
- package/src/models/PostCreateTweetRequestFeatures.ts +18 -27
- package/src/models/PostCreateTweetRequestVariablesMedia.ts +11 -4
- package/src/models/PostCreateTweetRequestVariablesMediaMediaEntitiesInner.ts +75 -0
- package/src/models/TimelineCommunity.ts +75 -0
- package/src/models/Tweet.ts +36 -0
- package/src/models/TypeName.ts +1 -0
- package/src/models/UserResults.ts +2 -3
- package/src/models/index.ts +18 -0
- package/tools/openapi-generator-config.yaml +1 -1
- package/twitter-openapi/.vscode/launch.json +8 -0
- package/twitter-openapi/README.md +2 -0
- package/twitter-openapi/dist/compatible/openapi-3.0.yaml +5189 -34
- package/twitter-openapi/dist/docs/openapi-3.0.yaml +6987 -34
- package/twitter-openapi/src/config/component/security_schemes.yaml +148 -0
- package/twitter-openapi/src/config/placeholder.json +145 -112
- package/twitter-openapi/src/openapi/paths/timeline.yaml +0 -2
- package/twitter-openapi/src/openapi/schemas/content.yaml +9 -1
- package/twitter-openapi/src/openapi/schemas/general.yaml +2 -2
- package/twitter-openapi/src/openapi/schemas/instruction.yaml +0 -1
- package/twitter-openapi/src/openapi/schemas/tweet.yaml +169 -2
- package/twitter-openapi/src/openapi/schemas/typename.yaml +1 -0
- package/twitter-openapi/src/openapi/schemas/user.yaml +0 -2
- package/twitter-openapi/test/python/test_serialize.py +24 -0
- package/twitter-openapi/tools/__pycache__/build_config.cpython-310.pyc +0 -0
- package/twitter-openapi/tools/__pycache__/hooks.cpython-310.pyc +0 -0
- package/twitter-openapi/tools/build.py +35 -31
- package/twitter-openapi/tools/build_config.py +7 -10
- package/twitter-openapi/dist/compatible/paths/bookmarks.yaml +0 -107
- package/twitter-openapi/dist/compatible/paths/follow.yaml +0 -301
- package/twitter-openapi/dist/compatible/paths/other.yaml +0 -99
- package/twitter-openapi/dist/compatible/paths/post.yaml +0 -714
- package/twitter-openapi/dist/compatible/paths/profile.yaml +0 -126
- package/twitter-openapi/dist/compatible/paths/timeline.yaml +0 -416
- package/twitter-openapi/dist/compatible/paths/tweet.yaml +0 -397
- package/twitter-openapi/dist/compatible/paths/user.yaml +0 -233
- package/twitter-openapi/dist/compatible/paths/usertweets.yaml +0 -504
- package/twitter-openapi/dist/compatible/paths/v1.1-get.yaml +0 -242
- package/twitter-openapi/dist/compatible/paths/v1.1-post.yaml +0 -237
- package/twitter-openapi/dist/compatible/paths/v2.0-get.yaml +0 -302
- package/twitter-openapi/dist/compatible/resources/parameters.yaml +0 -13
- package/twitter-openapi/dist/compatible/response/error.yaml +0 -90
- package/twitter-openapi/dist/compatible/schemas/content.yaml +0 -214
- package/twitter-openapi/dist/compatible/schemas/error.yaml +0 -94
- package/twitter-openapi/dist/compatible/schemas/general.yaml +0 -13
- package/twitter-openapi/dist/compatible/schemas/instruction.yaml +0 -286
- package/twitter-openapi/dist/compatible/schemas/timeline.yaml +0 -27
- package/twitter-openapi/dist/compatible/schemas/tweet.yaml +0 -508
- package/twitter-openapi/dist/compatible/schemas/typename.yaml +0 -23
- package/twitter-openapi/dist/compatible/schemas/user.yaml +0 -222
- package/twitter-openapi/dist/docs/paths/bookmarks.yaml +0 -201
- package/twitter-openapi/dist/docs/paths/follow.yaml +0 -587
- package/twitter-openapi/dist/docs/paths/other.yaml +0 -99
- package/twitter-openapi/dist/docs/paths/post.yaml +0 -692
- package/twitter-openapi/dist/docs/paths/profile.yaml +0 -134
- package/twitter-openapi/dist/docs/paths/timeline.yaml +0 -811
- package/twitter-openapi/dist/docs/paths/tweet.yaml +0 -797
- package/twitter-openapi/dist/docs/paths/user.yaml +0 -338
- package/twitter-openapi/dist/docs/paths/usertweets.yaml +0 -1046
- package/twitter-openapi/dist/docs/paths/v1.1-get.yaml +0 -242
- package/twitter-openapi/dist/docs/paths/v1.1-post.yaml +0 -237
- package/twitter-openapi/dist/docs/paths/v2.0-get.yaml +0 -302
- package/twitter-openapi/dist/docs/resources/parameters.yaml +0 -13
- package/twitter-openapi/dist/docs/response/error.yaml +0 -90
- package/twitter-openapi/dist/docs/schemas/content.yaml +0 -214
- package/twitter-openapi/dist/docs/schemas/error.yaml +0 -94
- package/twitter-openapi/dist/docs/schemas/general.yaml +0 -13
- package/twitter-openapi/dist/docs/schemas/instruction.yaml +0 -286
- package/twitter-openapi/dist/docs/schemas/timeline.yaml +0 -27
- package/twitter-openapi/dist/docs/schemas/tweet.yaml +0 -508
- package/twitter-openapi/dist/docs/schemas/typename.yaml +0 -23
- package/twitter-openapi/dist/docs/schemas/user.yaml +0 -222
package/src/apis/V11GetApi.ts
CHANGED
|
@@ -198,15 +198,23 @@ export class V11GetApi extends runtime.BaseAPI {
|
|
|
198
198
|
}
|
|
199
199
|
|
|
200
200
|
if (this.configuration && this.configuration.apiKey) {
|
|
201
|
-
headerParameters["
|
|
201
|
+
headerParameters["Accept"] = this.configuration.apiKey("Accept"); // Accept authentication
|
|
202
202
|
}
|
|
203
203
|
|
|
204
204
|
if (this.configuration && this.configuration.apiKey) {
|
|
205
|
-
headerParameters["
|
|
205
|
+
headerParameters["Sec-Fetch-Dest"] = this.configuration.apiKey("Sec-Fetch-Dest"); // SecFetchDest authentication
|
|
206
206
|
}
|
|
207
207
|
|
|
208
208
|
if (this.configuration && this.configuration.apiKey) {
|
|
209
|
-
headerParameters["
|
|
209
|
+
headerParameters["Pragma"] = this.configuration.apiKey("Pragma"); // Pragma authentication
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
213
|
+
headerParameters["Sec-Ch-Ua-Platform"] = this.configuration.apiKey("Sec-Ch-Ua-Platform"); // SecChUaPlatform authentication
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
217
|
+
headerParameters["Sec-Fetch-Mode"] = this.configuration.apiKey("Sec-Fetch-Mode"); // SecFetchMode authentication
|
|
210
218
|
}
|
|
211
219
|
|
|
212
220
|
if (this.configuration && this.configuration.apiKey) {
|
|
@@ -225,6 +233,42 @@ export class V11GetApi extends runtime.BaseAPI {
|
|
|
225
233
|
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
226
234
|
}
|
|
227
235
|
}
|
|
236
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
237
|
+
headerParameters["Sec-Ch-Ua"] = this.configuration.apiKey("Sec-Ch-Ua"); // SecChUa authentication
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
241
|
+
headerParameters["x-twitter-active-user"] = this.configuration.apiKey("x-twitter-active-user"); // ActiveUser authentication
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
245
|
+
headerParameters["user-agent"] = this.configuration.apiKey("user-agent"); // UserAgent authentication
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
249
|
+
headerParameters["Accept-Language"] = this.configuration.apiKey("Accept-Language"); // AcceptLanguage authentication
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
253
|
+
headerParameters["Sec-Fetch-Site"] = this.configuration.apiKey("Sec-Fetch-Site"); // SecFetchSite authentication
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
257
|
+
headerParameters["x-twitter-auth-type"] = this.configuration.apiKey("x-twitter-auth-type"); // AuthType authentication
|
|
258
|
+
}
|
|
259
|
+
|
|
260
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
261
|
+
headerParameters["Cache-Control"] = this.configuration.apiKey("Cache-Control"); // CacheControl authentication
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
265
|
+
headerParameters["Sec-Ch-Ua-Mobile"] = this.configuration.apiKey("Sec-Ch-Ua-Mobile"); // SecChUaMobile authentication
|
|
266
|
+
}
|
|
267
|
+
|
|
268
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
269
|
+
headerParameters["Accept-Encoding"] = this.configuration.apiKey("Accept-Encoding"); // AcceptEncoding authentication
|
|
270
|
+
}
|
|
271
|
+
|
|
228
272
|
const response = await this.request({
|
|
229
273
|
path: `/1.1/friends/following/list.json`,
|
|
230
274
|
method: 'GET',
|
|
@@ -303,15 +347,23 @@ export class V11GetApi extends runtime.BaseAPI {
|
|
|
303
347
|
}
|
|
304
348
|
|
|
305
349
|
if (this.configuration && this.configuration.apiKey) {
|
|
306
|
-
headerParameters["
|
|
350
|
+
headerParameters["Accept"] = this.configuration.apiKey("Accept"); // Accept authentication
|
|
307
351
|
}
|
|
308
352
|
|
|
309
353
|
if (this.configuration && this.configuration.apiKey) {
|
|
310
|
-
headerParameters["
|
|
354
|
+
headerParameters["Sec-Fetch-Dest"] = this.configuration.apiKey("Sec-Fetch-Dest"); // SecFetchDest authentication
|
|
311
355
|
}
|
|
312
356
|
|
|
313
357
|
if (this.configuration && this.configuration.apiKey) {
|
|
314
|
-
headerParameters["
|
|
358
|
+
headerParameters["Pragma"] = this.configuration.apiKey("Pragma"); // Pragma authentication
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
362
|
+
headerParameters["Sec-Ch-Ua-Platform"] = this.configuration.apiKey("Sec-Ch-Ua-Platform"); // SecChUaPlatform authentication
|
|
363
|
+
}
|
|
364
|
+
|
|
365
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
366
|
+
headerParameters["Sec-Fetch-Mode"] = this.configuration.apiKey("Sec-Fetch-Mode"); // SecFetchMode authentication
|
|
315
367
|
}
|
|
316
368
|
|
|
317
369
|
if (this.configuration && this.configuration.apiKey) {
|
|
@@ -330,6 +382,42 @@ export class V11GetApi extends runtime.BaseAPI {
|
|
|
330
382
|
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
331
383
|
}
|
|
332
384
|
}
|
|
385
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
386
|
+
headerParameters["Sec-Ch-Ua"] = this.configuration.apiKey("Sec-Ch-Ua"); // SecChUa authentication
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
390
|
+
headerParameters["x-twitter-active-user"] = this.configuration.apiKey("x-twitter-active-user"); // ActiveUser authentication
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
394
|
+
headerParameters["user-agent"] = this.configuration.apiKey("user-agent"); // UserAgent authentication
|
|
395
|
+
}
|
|
396
|
+
|
|
397
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
398
|
+
headerParameters["Accept-Language"] = this.configuration.apiKey("Accept-Language"); // AcceptLanguage authentication
|
|
399
|
+
}
|
|
400
|
+
|
|
401
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
402
|
+
headerParameters["Sec-Fetch-Site"] = this.configuration.apiKey("Sec-Fetch-Site"); // SecFetchSite authentication
|
|
403
|
+
}
|
|
404
|
+
|
|
405
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
406
|
+
headerParameters["x-twitter-auth-type"] = this.configuration.apiKey("x-twitter-auth-type"); // AuthType authentication
|
|
407
|
+
}
|
|
408
|
+
|
|
409
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
410
|
+
headerParameters["Cache-Control"] = this.configuration.apiKey("Cache-Control"); // CacheControl authentication
|
|
411
|
+
}
|
|
412
|
+
|
|
413
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
414
|
+
headerParameters["Sec-Ch-Ua-Mobile"] = this.configuration.apiKey("Sec-Ch-Ua-Mobile"); // SecChUaMobile authentication
|
|
415
|
+
}
|
|
416
|
+
|
|
417
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
418
|
+
headerParameters["Accept-Encoding"] = this.configuration.apiKey("Accept-Encoding"); // AcceptEncoding authentication
|
|
419
|
+
}
|
|
420
|
+
|
|
333
421
|
const response = await this.request({
|
|
334
422
|
path: `/1.1/search/typeahead.json`,
|
|
335
423
|
method: 'GET',
|
package/src/apis/V11PostApi.ts
CHANGED
|
@@ -123,15 +123,23 @@ export class V11PostApi extends runtime.BaseAPI {
|
|
|
123
123
|
}
|
|
124
124
|
|
|
125
125
|
if (this.configuration && this.configuration.apiKey) {
|
|
126
|
-
headerParameters["
|
|
126
|
+
headerParameters["Accept"] = this.configuration.apiKey("Accept"); // Accept authentication
|
|
127
127
|
}
|
|
128
128
|
|
|
129
129
|
if (this.configuration && this.configuration.apiKey) {
|
|
130
|
-
headerParameters["
|
|
130
|
+
headerParameters["Sec-Fetch-Dest"] = this.configuration.apiKey("Sec-Fetch-Dest"); // SecFetchDest authentication
|
|
131
131
|
}
|
|
132
132
|
|
|
133
133
|
if (this.configuration && this.configuration.apiKey) {
|
|
134
|
-
headerParameters["
|
|
134
|
+
headerParameters["Pragma"] = this.configuration.apiKey("Pragma"); // Pragma authentication
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
138
|
+
headerParameters["Sec-Ch-Ua-Platform"] = this.configuration.apiKey("Sec-Ch-Ua-Platform"); // SecChUaPlatform authentication
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
142
|
+
headerParameters["Sec-Fetch-Mode"] = this.configuration.apiKey("Sec-Fetch-Mode"); // SecFetchMode authentication
|
|
135
143
|
}
|
|
136
144
|
|
|
137
145
|
if (this.configuration && this.configuration.apiKey) {
|
|
@@ -150,6 +158,42 @@ export class V11PostApi extends runtime.BaseAPI {
|
|
|
150
158
|
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
151
159
|
}
|
|
152
160
|
}
|
|
161
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
162
|
+
headerParameters["Sec-Ch-Ua"] = this.configuration.apiKey("Sec-Ch-Ua"); // SecChUa authentication
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
166
|
+
headerParameters["x-twitter-active-user"] = this.configuration.apiKey("x-twitter-active-user"); // ActiveUser authentication
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
170
|
+
headerParameters["user-agent"] = this.configuration.apiKey("user-agent"); // UserAgent authentication
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
174
|
+
headerParameters["Accept-Language"] = this.configuration.apiKey("Accept-Language"); // AcceptLanguage authentication
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
178
|
+
headerParameters["Sec-Fetch-Site"] = this.configuration.apiKey("Sec-Fetch-Site"); // SecFetchSite authentication
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
182
|
+
headerParameters["x-twitter-auth-type"] = this.configuration.apiKey("x-twitter-auth-type"); // AuthType authentication
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
186
|
+
headerParameters["Cache-Control"] = this.configuration.apiKey("Cache-Control"); // CacheControl authentication
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
190
|
+
headerParameters["Sec-Ch-Ua-Mobile"] = this.configuration.apiKey("Sec-Ch-Ua-Mobile"); // SecChUaMobile authentication
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
194
|
+
headerParameters["Accept-Encoding"] = this.configuration.apiKey("Accept-Encoding"); // AcceptEncoding authentication
|
|
195
|
+
}
|
|
196
|
+
|
|
153
197
|
const consumes: runtime.Consume[] = [
|
|
154
198
|
{ contentType: 'application/x-www-form-urlencoded' },
|
|
155
199
|
];
|
|
@@ -307,15 +351,23 @@ export class V11PostApi extends runtime.BaseAPI {
|
|
|
307
351
|
}
|
|
308
352
|
|
|
309
353
|
if (this.configuration && this.configuration.apiKey) {
|
|
310
|
-
headerParameters["
|
|
354
|
+
headerParameters["Accept"] = this.configuration.apiKey("Accept"); // Accept authentication
|
|
311
355
|
}
|
|
312
356
|
|
|
313
357
|
if (this.configuration && this.configuration.apiKey) {
|
|
314
|
-
headerParameters["
|
|
358
|
+
headerParameters["Sec-Fetch-Dest"] = this.configuration.apiKey("Sec-Fetch-Dest"); // SecFetchDest authentication
|
|
315
359
|
}
|
|
316
360
|
|
|
317
361
|
if (this.configuration && this.configuration.apiKey) {
|
|
318
|
-
headerParameters["
|
|
362
|
+
headerParameters["Pragma"] = this.configuration.apiKey("Pragma"); // Pragma authentication
|
|
363
|
+
}
|
|
364
|
+
|
|
365
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
366
|
+
headerParameters["Sec-Ch-Ua-Platform"] = this.configuration.apiKey("Sec-Ch-Ua-Platform"); // SecChUaPlatform authentication
|
|
367
|
+
}
|
|
368
|
+
|
|
369
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
370
|
+
headerParameters["Sec-Fetch-Mode"] = this.configuration.apiKey("Sec-Fetch-Mode"); // SecFetchMode authentication
|
|
319
371
|
}
|
|
320
372
|
|
|
321
373
|
if (this.configuration && this.configuration.apiKey) {
|
|
@@ -334,6 +386,42 @@ export class V11PostApi extends runtime.BaseAPI {
|
|
|
334
386
|
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
335
387
|
}
|
|
336
388
|
}
|
|
389
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
390
|
+
headerParameters["Sec-Ch-Ua"] = this.configuration.apiKey("Sec-Ch-Ua"); // SecChUa authentication
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
394
|
+
headerParameters["x-twitter-active-user"] = this.configuration.apiKey("x-twitter-active-user"); // ActiveUser authentication
|
|
395
|
+
}
|
|
396
|
+
|
|
397
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
398
|
+
headerParameters["user-agent"] = this.configuration.apiKey("user-agent"); // UserAgent authentication
|
|
399
|
+
}
|
|
400
|
+
|
|
401
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
402
|
+
headerParameters["Accept-Language"] = this.configuration.apiKey("Accept-Language"); // AcceptLanguage authentication
|
|
403
|
+
}
|
|
404
|
+
|
|
405
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
406
|
+
headerParameters["Sec-Fetch-Site"] = this.configuration.apiKey("Sec-Fetch-Site"); // SecFetchSite authentication
|
|
407
|
+
}
|
|
408
|
+
|
|
409
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
410
|
+
headerParameters["x-twitter-auth-type"] = this.configuration.apiKey("x-twitter-auth-type"); // AuthType authentication
|
|
411
|
+
}
|
|
412
|
+
|
|
413
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
414
|
+
headerParameters["Cache-Control"] = this.configuration.apiKey("Cache-Control"); // CacheControl authentication
|
|
415
|
+
}
|
|
416
|
+
|
|
417
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
418
|
+
headerParameters["Sec-Ch-Ua-Mobile"] = this.configuration.apiKey("Sec-Ch-Ua-Mobile"); // SecChUaMobile authentication
|
|
419
|
+
}
|
|
420
|
+
|
|
421
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
422
|
+
headerParameters["Accept-Encoding"] = this.configuration.apiKey("Accept-Encoding"); // AcceptEncoding authentication
|
|
423
|
+
}
|
|
424
|
+
|
|
337
425
|
const consumes: runtime.Consume[] = [
|
|
338
426
|
{ contentType: 'application/x-www-form-urlencoded' },
|
|
339
427
|
];
|
package/src/apis/V20GetApi.ts
CHANGED
|
@@ -369,15 +369,23 @@ export class V20GetApi extends runtime.BaseAPI {
|
|
|
369
369
|
}
|
|
370
370
|
|
|
371
371
|
if (this.configuration && this.configuration.apiKey) {
|
|
372
|
-
headerParameters["
|
|
372
|
+
headerParameters["Accept"] = this.configuration.apiKey("Accept"); // Accept authentication
|
|
373
373
|
}
|
|
374
374
|
|
|
375
375
|
if (this.configuration && this.configuration.apiKey) {
|
|
376
|
-
headerParameters["
|
|
376
|
+
headerParameters["Sec-Fetch-Dest"] = this.configuration.apiKey("Sec-Fetch-Dest"); // SecFetchDest authentication
|
|
377
377
|
}
|
|
378
378
|
|
|
379
379
|
if (this.configuration && this.configuration.apiKey) {
|
|
380
|
-
headerParameters["
|
|
380
|
+
headerParameters["Pragma"] = this.configuration.apiKey("Pragma"); // Pragma authentication
|
|
381
|
+
}
|
|
382
|
+
|
|
383
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
384
|
+
headerParameters["Sec-Ch-Ua-Platform"] = this.configuration.apiKey("Sec-Ch-Ua-Platform"); // SecChUaPlatform authentication
|
|
385
|
+
}
|
|
386
|
+
|
|
387
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
388
|
+
headerParameters["Sec-Fetch-Mode"] = this.configuration.apiKey("Sec-Fetch-Mode"); // SecFetchMode authentication
|
|
381
389
|
}
|
|
382
390
|
|
|
383
391
|
if (this.configuration && this.configuration.apiKey) {
|
|
@@ -396,6 +404,42 @@ export class V20GetApi extends runtime.BaseAPI {
|
|
|
396
404
|
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
397
405
|
}
|
|
398
406
|
}
|
|
407
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
408
|
+
headerParameters["Sec-Ch-Ua"] = this.configuration.apiKey("Sec-Ch-Ua"); // SecChUa authentication
|
|
409
|
+
}
|
|
410
|
+
|
|
411
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
412
|
+
headerParameters["x-twitter-active-user"] = this.configuration.apiKey("x-twitter-active-user"); // ActiveUser authentication
|
|
413
|
+
}
|
|
414
|
+
|
|
415
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
416
|
+
headerParameters["user-agent"] = this.configuration.apiKey("user-agent"); // UserAgent authentication
|
|
417
|
+
}
|
|
418
|
+
|
|
419
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
420
|
+
headerParameters["Accept-Language"] = this.configuration.apiKey("Accept-Language"); // AcceptLanguage authentication
|
|
421
|
+
}
|
|
422
|
+
|
|
423
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
424
|
+
headerParameters["Sec-Fetch-Site"] = this.configuration.apiKey("Sec-Fetch-Site"); // SecFetchSite authentication
|
|
425
|
+
}
|
|
426
|
+
|
|
427
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
428
|
+
headerParameters["x-twitter-auth-type"] = this.configuration.apiKey("x-twitter-auth-type"); // AuthType authentication
|
|
429
|
+
}
|
|
430
|
+
|
|
431
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
432
|
+
headerParameters["Cache-Control"] = this.configuration.apiKey("Cache-Control"); // CacheControl authentication
|
|
433
|
+
}
|
|
434
|
+
|
|
435
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
436
|
+
headerParameters["Sec-Ch-Ua-Mobile"] = this.configuration.apiKey("Sec-Ch-Ua-Mobile"); // SecChUaMobile authentication
|
|
437
|
+
}
|
|
438
|
+
|
|
439
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
440
|
+
headerParameters["Accept-Encoding"] = this.configuration.apiKey("Accept-Encoding"); // AcceptEncoding authentication
|
|
441
|
+
}
|
|
442
|
+
|
|
399
443
|
const response = await this.request({
|
|
400
444
|
path: `/2/search/adaptive.json`,
|
|
401
445
|
method: 'GET',
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Twitter OpenAPI
|
|
5
|
+
* Twitter OpenAPI(Swagger) specification
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 0.0.1
|
|
8
|
+
* Contact: yuki@yuki0311.com
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { exists, mapValues } from '../runtime';
|
|
16
|
+
import type { BirdwatchEntityRef } from './BirdwatchEntityRef';
|
|
17
|
+
import {
|
|
18
|
+
BirdwatchEntityRefFromJSON,
|
|
19
|
+
BirdwatchEntityRefFromJSONTyped,
|
|
20
|
+
BirdwatchEntityRefToJSON,
|
|
21
|
+
} from './BirdwatchEntityRef';
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
*
|
|
25
|
+
* @export
|
|
26
|
+
* @interface BirdwatchEntity
|
|
27
|
+
*/
|
|
28
|
+
export interface BirdwatchEntity {
|
|
29
|
+
/**
|
|
30
|
+
*
|
|
31
|
+
* @type {number}
|
|
32
|
+
* @memberof BirdwatchEntity
|
|
33
|
+
*/
|
|
34
|
+
fromIndex: number;
|
|
35
|
+
/**
|
|
36
|
+
*
|
|
37
|
+
* @type {BirdwatchEntityRef}
|
|
38
|
+
* @memberof BirdwatchEntity
|
|
39
|
+
*/
|
|
40
|
+
ref: BirdwatchEntityRef;
|
|
41
|
+
/**
|
|
42
|
+
*
|
|
43
|
+
* @type {number}
|
|
44
|
+
* @memberof BirdwatchEntity
|
|
45
|
+
*/
|
|
46
|
+
toIndex: number;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* Check if a given object implements the BirdwatchEntity interface.
|
|
51
|
+
*/
|
|
52
|
+
export function instanceOfBirdwatchEntity(value: object): boolean {
|
|
53
|
+
let isInstance = true;
|
|
54
|
+
isInstance = isInstance && "fromIndex" in value;
|
|
55
|
+
isInstance = isInstance && "ref" in value;
|
|
56
|
+
isInstance = isInstance && "toIndex" in value;
|
|
57
|
+
|
|
58
|
+
return isInstance;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export function BirdwatchEntityFromJSON(json: any): BirdwatchEntity {
|
|
62
|
+
return BirdwatchEntityFromJSONTyped(json, false);
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
export function BirdwatchEntityFromJSONTyped(json: any, ignoreDiscriminator: boolean): BirdwatchEntity {
|
|
66
|
+
if ((json === undefined) || (json === null)) {
|
|
67
|
+
return json;
|
|
68
|
+
}
|
|
69
|
+
return {
|
|
70
|
+
|
|
71
|
+
'fromIndex': json['fromIndex'],
|
|
72
|
+
'ref': BirdwatchEntityRefFromJSON(json['ref']),
|
|
73
|
+
'toIndex': json['toIndex'],
|
|
74
|
+
};
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export function BirdwatchEntityToJSON(value?: BirdwatchEntity | null): any {
|
|
78
|
+
if (value === undefined) {
|
|
79
|
+
return undefined;
|
|
80
|
+
}
|
|
81
|
+
if (value === null) {
|
|
82
|
+
return null;
|
|
83
|
+
}
|
|
84
|
+
return {
|
|
85
|
+
|
|
86
|
+
'fromIndex': value.fromIndex,
|
|
87
|
+
'ref': BirdwatchEntityRefToJSON(value.ref),
|
|
88
|
+
'toIndex': value.toIndex,
|
|
89
|
+
};
|
|
90
|
+
}
|
|
91
|
+
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Twitter OpenAPI
|
|
5
|
+
* Twitter OpenAPI(Swagger) specification
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 0.0.1
|
|
8
|
+
* Contact: yuki@yuki0311.com
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { exists, mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface BirdwatchEntityRef
|
|
20
|
+
*/
|
|
21
|
+
export interface BirdwatchEntityRef {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof BirdwatchEntityRef
|
|
26
|
+
*/
|
|
27
|
+
type: BirdwatchEntityRefTypeEnum;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof BirdwatchEntityRef
|
|
32
|
+
*/
|
|
33
|
+
url: string;
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* @type {string}
|
|
37
|
+
* @memberof BirdwatchEntityRef
|
|
38
|
+
*/
|
|
39
|
+
urlType: BirdwatchEntityRefUrlTypeEnum;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* @export
|
|
45
|
+
*/
|
|
46
|
+
export const BirdwatchEntityRefTypeEnum = {
|
|
47
|
+
TimelineUrl: 'TimelineUrl'
|
|
48
|
+
} as const;
|
|
49
|
+
export type BirdwatchEntityRefTypeEnum = typeof BirdwatchEntityRefTypeEnum[keyof typeof BirdwatchEntityRefTypeEnum];
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* @export
|
|
53
|
+
*/
|
|
54
|
+
export const BirdwatchEntityRefUrlTypeEnum = {
|
|
55
|
+
ExternalUrl: 'ExternalUrl'
|
|
56
|
+
} as const;
|
|
57
|
+
export type BirdwatchEntityRefUrlTypeEnum = typeof BirdwatchEntityRefUrlTypeEnum[keyof typeof BirdwatchEntityRefUrlTypeEnum];
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
* Check if a given object implements the BirdwatchEntityRef interface.
|
|
62
|
+
*/
|
|
63
|
+
export function instanceOfBirdwatchEntityRef(value: object): boolean {
|
|
64
|
+
let isInstance = true;
|
|
65
|
+
isInstance = isInstance && "type" in value;
|
|
66
|
+
isInstance = isInstance && "url" in value;
|
|
67
|
+
isInstance = isInstance && "urlType" in value;
|
|
68
|
+
|
|
69
|
+
return isInstance;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export function BirdwatchEntityRefFromJSON(json: any): BirdwatchEntityRef {
|
|
73
|
+
return BirdwatchEntityRefFromJSONTyped(json, false);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
export function BirdwatchEntityRefFromJSONTyped(json: any, ignoreDiscriminator: boolean): BirdwatchEntityRef {
|
|
77
|
+
if ((json === undefined) || (json === null)) {
|
|
78
|
+
return json;
|
|
79
|
+
}
|
|
80
|
+
return {
|
|
81
|
+
|
|
82
|
+
'type': json['type'],
|
|
83
|
+
'url': json['url'],
|
|
84
|
+
'urlType': json['urlType'],
|
|
85
|
+
};
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
export function BirdwatchEntityRefToJSON(value?: BirdwatchEntityRef | null): any {
|
|
89
|
+
if (value === undefined) {
|
|
90
|
+
return undefined;
|
|
91
|
+
}
|
|
92
|
+
if (value === null) {
|
|
93
|
+
return null;
|
|
94
|
+
}
|
|
95
|
+
return {
|
|
96
|
+
|
|
97
|
+
'type': value.type,
|
|
98
|
+
'url': value.url,
|
|
99
|
+
'urlType': value.urlType,
|
|
100
|
+
};
|
|
101
|
+
}
|
|
102
|
+
|