twitter-openapi-typescript-generated 0.1.0 → 0.1.1
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 +11 -2
- package/dist/esm/models/Community.d.ts +4 -0
- package/dist/esm/models/Community.js +2 -0
- package/dist/esm/models/ErrorExtensions.d.ts +1 -1
- package/dist/esm/models/ErrorExtensions.js +1 -3
- package/dist/esm/models/ErrorResponse.d.ts +1 -1
- package/dist/esm/models/ErrorResponse.js +1 -3
- package/dist/esm/models/GroupedTrend.d.ts +35 -0
- package/dist/esm/models/GroupedTrend.js +48 -0
- package/dist/esm/models/SearchTimeline.d.ts +1 -1
- package/dist/esm/models/SearchTimeline.js +1 -3
- package/dist/esm/models/TimelineCommunity.d.ts +11 -2
- package/dist/esm/models/TimelineCommunity.js +18 -2
- package/dist/esm/models/TimelineMessagePrompt.d.ts +11 -2
- package/dist/esm/models/TimelineMessagePrompt.js +18 -2
- package/dist/esm/models/TimelineMessagePromptButton.d.ts +35 -0
- package/dist/esm/models/TimelineMessagePromptButton.js +48 -0
- package/dist/esm/models/TimelineMessagePromptButtonAction.d.ts +34 -0
- package/dist/esm/models/TimelineMessagePromptButtonAction.js +47 -0
- package/dist/esm/models/TimelineMessagePromptContent.d.ts +56 -0
- package/dist/esm/models/TimelineMessagePromptContent.js +62 -0
- package/dist/esm/models/TimelineMessagePromptRichText.d.ts +35 -0
- package/dist/esm/models/TimelineMessagePromptRichText.js +48 -0
- package/dist/esm/models/TimelineMessagePromptRichTextEntity.d.ts +39 -0
- package/dist/esm/models/TimelineMessagePromptRichTextEntity.js +52 -0
- package/dist/esm/models/TimelineMessagePromptRichTextEntityRef.d.ts +52 -0
- package/dist/esm/models/TimelineMessagePromptRichTextEntityRef.js +67 -0
- package/dist/esm/models/TimelinePrompt.d.ts +16 -2
- package/dist/esm/models/TimelinePrompt.js +23 -2
- package/dist/esm/models/TimelinePromptCallback.d.ts +30 -0
- package/dist/esm/models/TimelinePromptCallback.js +43 -0
- package/dist/esm/models/TimelinePromptContent.d.ts +73 -0
- package/dist/esm/models/TimelinePromptContent.js +88 -0
- package/dist/esm/models/TimelineTrend.d.ts +5 -0
- package/dist/esm/models/TimelineTrend.js +3 -0
- package/dist/esm/models/index.d.ts +9 -0
- package/dist/esm/models/index.js +9 -0
- package/dist/models/Community.d.ts +4 -0
- package/dist/models/Community.js +2 -0
- package/dist/models/ErrorExtensions.d.ts +1 -1
- package/dist/models/ErrorExtensions.js +1 -3
- package/dist/models/ErrorResponse.d.ts +1 -1
- package/dist/models/ErrorResponse.js +1 -3
- package/dist/models/GroupedTrend.d.ts +35 -0
- package/dist/models/GroupedTrend.js +55 -0
- package/dist/models/SearchTimeline.d.ts +1 -1
- package/dist/models/SearchTimeline.js +1 -3
- package/dist/models/TimelineCommunity.d.ts +11 -2
- package/dist/models/TimelineCommunity.js +18 -2
- package/dist/models/TimelineMessagePrompt.d.ts +11 -2
- package/dist/models/TimelineMessagePrompt.js +18 -2
- package/dist/models/TimelineMessagePromptButton.d.ts +35 -0
- package/dist/models/TimelineMessagePromptButton.js +55 -0
- package/dist/models/TimelineMessagePromptButtonAction.d.ts +34 -0
- package/dist/models/TimelineMessagePromptButtonAction.js +54 -0
- package/dist/models/TimelineMessagePromptContent.d.ts +56 -0
- package/dist/models/TimelineMessagePromptContent.js +70 -0
- package/dist/models/TimelineMessagePromptRichText.d.ts +35 -0
- package/dist/models/TimelineMessagePromptRichText.js +55 -0
- package/dist/models/TimelineMessagePromptRichTextEntity.d.ts +39 -0
- package/dist/models/TimelineMessagePromptRichTextEntity.js +59 -0
- package/dist/models/TimelineMessagePromptRichTextEntityRef.d.ts +52 -0
- package/dist/models/TimelineMessagePromptRichTextEntityRef.js +75 -0
- package/dist/models/TimelinePrompt.d.ts +16 -2
- package/dist/models/TimelinePrompt.js +23 -2
- package/dist/models/TimelinePromptCallback.d.ts +30 -0
- package/dist/models/TimelinePromptCallback.js +50 -0
- package/dist/models/TimelinePromptContent.d.ts +73 -0
- package/dist/models/TimelinePromptContent.js +96 -0
- package/dist/models/TimelineTrend.d.ts +5 -0
- package/dist/models/TimelineTrend.js +3 -0
- package/dist/models/index.d.ts +9 -0
- package/dist/models/index.js +9 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# twitter-openapi-typescript-generated@0.1.
|
|
1
|
+
# twitter-openapi-typescript-generated@0.1.1
|
|
2
2
|
|
|
3
3
|
A TypeScript SDK client for the x.com API.
|
|
4
4
|
|
|
@@ -334,6 +334,7 @@ All URIs are relative to *https://x.com/i/api*
|
|
|
334
334
|
- [GrokTranslatedCommunityNoteWithAvailability](docs/GrokTranslatedCommunityNoteWithAvailability.md)
|
|
335
335
|
- [GrokTranslatedPost](docs/GrokTranslatedPost.md)
|
|
336
336
|
- [GrokTranslatedPostWithAvailability](docs/GrokTranslatedPostWithAvailability.md)
|
|
337
|
+
- [GroupedTrend](docs/GroupedTrend.md)
|
|
337
338
|
- [Hashtag](docs/Hashtag.md)
|
|
338
339
|
- [Highlight](docs/Highlight.md)
|
|
339
340
|
- [HomeTimelineHome](docs/HomeTimelineHome.md)
|
|
@@ -500,10 +501,18 @@ All URIs are relative to *https://x.com/i/api*
|
|
|
500
501
|
- [TimelineLabel](docs/TimelineLabel.md)
|
|
501
502
|
- [TimelineMarkEntriesUnreadGreaterThanSortIndex](docs/TimelineMarkEntriesUnreadGreaterThanSortIndex.md)
|
|
502
503
|
- [TimelineMessagePrompt](docs/TimelineMessagePrompt.md)
|
|
504
|
+
- [TimelineMessagePromptButton](docs/TimelineMessagePromptButton.md)
|
|
505
|
+
- [TimelineMessagePromptButtonAction](docs/TimelineMessagePromptButtonAction.md)
|
|
506
|
+
- [TimelineMessagePromptContent](docs/TimelineMessagePromptContent.md)
|
|
507
|
+
- [TimelineMessagePromptRichText](docs/TimelineMessagePromptRichText.md)
|
|
508
|
+
- [TimelineMessagePromptRichTextEntity](docs/TimelineMessagePromptRichTextEntity.md)
|
|
509
|
+
- [TimelineMessagePromptRichTextEntityRef](docs/TimelineMessagePromptRichTextEntityRef.md)
|
|
503
510
|
- [TimelineMetadata](docs/TimelineMetadata.md)
|
|
504
511
|
- [TimelineNotification](docs/TimelineNotification.md)
|
|
505
512
|
- [TimelinePinEntry](docs/TimelinePinEntry.md)
|
|
506
513
|
- [TimelinePrompt](docs/TimelinePrompt.md)
|
|
514
|
+
- [TimelinePromptCallback](docs/TimelinePromptCallback.md)
|
|
515
|
+
- [TimelinePromptContent](docs/TimelinePromptContent.md)
|
|
507
516
|
- [TimelineReplaceEntry](docs/TimelineReplaceEntry.md)
|
|
508
517
|
- [TimelineResponse](docs/TimelineResponse.md)
|
|
509
518
|
- [TimelineResponseObjects](docs/TimelineResponseObjects.md)
|
|
@@ -827,7 +836,7 @@ and is automatically generated by the
|
|
|
827
836
|
[OpenAPI Generator](https://openapi-generator.tech) project:
|
|
828
837
|
|
|
829
838
|
- API version: `0.0.1`
|
|
830
|
-
- Package version: `0.1.
|
|
839
|
+
- Package version: `0.1.1`
|
|
831
840
|
- Generator version: `7.26.0`
|
|
832
841
|
- Build package: `org.openapitools.codegen.languages.TypeScriptFetchClientCodegen`
|
|
833
842
|
|
|
@@ -68,6 +68,7 @@ export function CommunityFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
68
68
|
'idStr': json['id_str'] == null ? undefined : json['id_str'],
|
|
69
69
|
'invitesPolicy': json['invites_policy'] == null ? undefined : json['invites_policy'],
|
|
70
70
|
'invitesResult': json['invites_result'] == null ? undefined : CommunityInvitesResultFromJSON(json['invites_result']),
|
|
71
|
+
'isNsfw': json['is_nsfw'] == null ? undefined : json['is_nsfw'],
|
|
71
72
|
'isPinned': json['is_pinned'] == null ? undefined : json['is_pinned'],
|
|
72
73
|
'joinPolicy': json['join_policy'] == null ? undefined : json['join_policy'],
|
|
73
74
|
'joinRequestsResult': json['join_requests_result'] == null ? undefined : CommunityJoinRequestsResultFromJSON(json['join_requests_result']),
|
|
@@ -104,6 +105,7 @@ export function CommunityToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
104
105
|
'id_str': value['idStr'],
|
|
105
106
|
'invites_policy': value['invitesPolicy'],
|
|
106
107
|
'invites_result': CommunityInvitesResultToJSON(value['invitesResult']),
|
|
108
|
+
'is_nsfw': value['isNsfw'],
|
|
107
109
|
'is_pinned': value['isPinned'],
|
|
108
110
|
'join_policy': value['joinPolicy'],
|
|
109
111
|
'join_requests_result': CommunityJoinRequestsResultToJSON(value['joinRequestsResult']),
|
|
@@ -16,8 +16,6 @@ import { TracingFromJSON, TracingToJSON, } from './Tracing';
|
|
|
16
16
|
* Check if a given object implements the ErrorExtensions interface.
|
|
17
17
|
*/
|
|
18
18
|
export function instanceOfErrorExtensions(value) {
|
|
19
|
-
if (!('code' in value) || value['code'] === undefined)
|
|
20
|
-
return false;
|
|
21
19
|
if (!('kind' in value) || value['kind'] === undefined)
|
|
22
20
|
return false;
|
|
23
21
|
if (!('name' in value) || value['name'] === undefined)
|
|
@@ -34,7 +32,7 @@ export function ErrorExtensionsFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
34
32
|
return json;
|
|
35
33
|
}
|
|
36
34
|
return {
|
|
37
|
-
'code': json['code'],
|
|
35
|
+
'code': json['code'] == null ? undefined : json['code'],
|
|
38
36
|
'kind': json['kind'],
|
|
39
37
|
'name': json['name'],
|
|
40
38
|
'retryAfter': json['retry_after'] == null ? undefined : json['retry_after'],
|
|
@@ -19,8 +19,6 @@ import { LocationFromJSON, LocationToJSON, } from './Location';
|
|
|
19
19
|
* Check if a given object implements the ErrorResponse interface.
|
|
20
20
|
*/
|
|
21
21
|
export function instanceOfErrorResponse(value) {
|
|
22
|
-
if (!('code' in value) || value['code'] === undefined)
|
|
23
|
-
return false;
|
|
24
22
|
if (!('extensions' in value) || value['extensions'] === undefined)
|
|
25
23
|
return false;
|
|
26
24
|
if (!('kind' in value) || value['kind'] === undefined)
|
|
@@ -45,7 +43,7 @@ export function ErrorResponseFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
45
43
|
return json;
|
|
46
44
|
}
|
|
47
45
|
return {
|
|
48
|
-
'code': json['code'],
|
|
46
|
+
'code': json['code'] == null ? undefined : json['code'],
|
|
49
47
|
'extensions': ErrorExtensionsFromJSON(json['extensions']),
|
|
50
48
|
'kind': json['kind'],
|
|
51
49
|
'locations': (json['locations'].map(LocationFromJSON)),
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Twitter OpenAPI
|
|
3
|
+
* Twitter OpenAPI(Swagger) specification
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 0.0.1
|
|
6
|
+
* Contact: yuki@yuki0311.com
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { SocialContextLandingUrl } from './SocialContextLandingUrl';
|
|
13
|
+
/**
|
|
14
|
+
*
|
|
15
|
+
* @export
|
|
16
|
+
* @interface GroupedTrend
|
|
17
|
+
*/
|
|
18
|
+
export interface GroupedTrend {
|
|
19
|
+
/**
|
|
20
|
+
*
|
|
21
|
+
*/
|
|
22
|
+
name: string;
|
|
23
|
+
/**
|
|
24
|
+
*
|
|
25
|
+
*/
|
|
26
|
+
url: SocialContextLandingUrl;
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Check if a given object implements the GroupedTrend interface.
|
|
30
|
+
*/
|
|
31
|
+
export declare function instanceOfGroupedTrend(value: object): value is GroupedTrend;
|
|
32
|
+
export declare function GroupedTrendFromJSON(json: any): GroupedTrend;
|
|
33
|
+
export declare function GroupedTrendFromJSONTyped(json: any, ignoreDiscriminator: boolean): GroupedTrend;
|
|
34
|
+
export declare function GroupedTrendToJSON(json: any): GroupedTrend;
|
|
35
|
+
export declare function GroupedTrendToJSONTyped(value?: GroupedTrend | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,48 @@
|
|
|
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
|
+
import { SocialContextLandingUrlFromJSON, SocialContextLandingUrlToJSON, } from './SocialContextLandingUrl';
|
|
15
|
+
/**
|
|
16
|
+
* Check if a given object implements the GroupedTrend interface.
|
|
17
|
+
*/
|
|
18
|
+
export function instanceOfGroupedTrend(value) {
|
|
19
|
+
if (!('name' in value) || value['name'] === undefined)
|
|
20
|
+
return false;
|
|
21
|
+
if (!('url' in value) || value['url'] === undefined)
|
|
22
|
+
return false;
|
|
23
|
+
return true;
|
|
24
|
+
}
|
|
25
|
+
export function GroupedTrendFromJSON(json) {
|
|
26
|
+
return GroupedTrendFromJSONTyped(json, false);
|
|
27
|
+
}
|
|
28
|
+
export function GroupedTrendFromJSONTyped(json, ignoreDiscriminator) {
|
|
29
|
+
if (json == null) {
|
|
30
|
+
return json;
|
|
31
|
+
}
|
|
32
|
+
return {
|
|
33
|
+
'name': json['name'],
|
|
34
|
+
'url': SocialContextLandingUrlFromJSON(json['url']),
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
export function GroupedTrendToJSON(json) {
|
|
38
|
+
return GroupedTrendToJSONTyped(json, false);
|
|
39
|
+
}
|
|
40
|
+
export function GroupedTrendToJSONTyped(value, ignoreDiscriminator = false) {
|
|
41
|
+
if (value == null) {
|
|
42
|
+
return value;
|
|
43
|
+
}
|
|
44
|
+
return {
|
|
45
|
+
'name': value['name'],
|
|
46
|
+
'url': SocialContextLandingUrlToJSON(value['url']),
|
|
47
|
+
};
|
|
48
|
+
}
|
|
@@ -16,8 +16,6 @@ import { TimelineFromJSON, TimelineToJSON, } from './Timeline';
|
|
|
16
16
|
* Check if a given object implements the SearchTimeline interface.
|
|
17
17
|
*/
|
|
18
18
|
export function instanceOfSearchTimeline(value) {
|
|
19
|
-
if (!('timeline' in value) || value['timeline'] === undefined)
|
|
20
|
-
return false;
|
|
21
19
|
return true;
|
|
22
20
|
}
|
|
23
21
|
export function SearchTimelineFromJSON(json) {
|
|
@@ -28,7 +26,7 @@ export function SearchTimelineFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
28
26
|
return json;
|
|
29
27
|
}
|
|
30
28
|
return {
|
|
31
|
-
'timeline': TimelineFromJSON(json['timeline']),
|
|
29
|
+
'timeline': json['timeline'] == null ? undefined : TimelineFromJSON(json['timeline']),
|
|
32
30
|
};
|
|
33
31
|
}
|
|
34
32
|
export function SearchTimelineToJSON(json) {
|
|
@@ -9,18 +9,27 @@
|
|
|
9
9
|
* https://openapi-generator.tech
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
|
+
import type { CommunityResult } from './CommunityResult';
|
|
12
13
|
import type { TypeName } from './TypeName';
|
|
14
|
+
import type { ContentItemType } from './ContentItemType';
|
|
13
15
|
/**
|
|
14
16
|
*
|
|
15
17
|
* @export
|
|
16
18
|
* @interface TimelineCommunity
|
|
17
19
|
*/
|
|
18
20
|
export interface TimelineCommunity {
|
|
19
|
-
[key: string]: any | any;
|
|
20
21
|
/**
|
|
21
22
|
*
|
|
22
23
|
*/
|
|
23
|
-
typename
|
|
24
|
+
typename: TypeName;
|
|
25
|
+
/**
|
|
26
|
+
*
|
|
27
|
+
*/
|
|
28
|
+
communityResults: CommunityResult;
|
|
29
|
+
/**
|
|
30
|
+
*
|
|
31
|
+
*/
|
|
32
|
+
itemType: ContentItemType;
|
|
24
33
|
}
|
|
25
34
|
/**
|
|
26
35
|
* Check if a given object implements the TimelineCommunity interface.
|
|
@@ -11,11 +11,19 @@
|
|
|
11
11
|
* https://openapi-generator.tech
|
|
12
12
|
* Do not edit the class manually.
|
|
13
13
|
*/
|
|
14
|
+
import { CommunityResultFromJSON, CommunityResultToJSON, } from './CommunityResult';
|
|
14
15
|
import { TypeNameFromJSON, TypeNameToJSON, } from './TypeName';
|
|
16
|
+
import { ContentItemTypeFromJSON, ContentItemTypeToJSON, } from './ContentItemType';
|
|
15
17
|
/**
|
|
16
18
|
* Check if a given object implements the TimelineCommunity interface.
|
|
17
19
|
*/
|
|
18
20
|
export function instanceOfTimelineCommunity(value) {
|
|
21
|
+
if ((!('typename' in value) && !('__typename' in value)) || (value['typename'] === undefined && value['__typename'] === undefined))
|
|
22
|
+
return false;
|
|
23
|
+
if ((!('communityResults' in value) && !('community_results' in value)) || (value['communityResults'] === undefined && value['community_results'] === undefined))
|
|
24
|
+
return false;
|
|
25
|
+
if (!('itemType' in value) || value['itemType'] === undefined)
|
|
26
|
+
return false;
|
|
19
27
|
return true;
|
|
20
28
|
}
|
|
21
29
|
export function TimelineCommunityFromJSON(json) {
|
|
@@ -25,7 +33,11 @@ export function TimelineCommunityFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
25
33
|
if (json == null) {
|
|
26
34
|
return json;
|
|
27
35
|
}
|
|
28
|
-
return
|
|
36
|
+
return {
|
|
37
|
+
'typename': TypeNameFromJSON(json['__typename']),
|
|
38
|
+
'communityResults': CommunityResultFromJSON(json['community_results']),
|
|
39
|
+
'itemType': ContentItemTypeFromJSON(json['itemType']),
|
|
40
|
+
};
|
|
29
41
|
}
|
|
30
42
|
export function TimelineCommunityToJSON(json) {
|
|
31
43
|
return TimelineCommunityToJSONTyped(json, false);
|
|
@@ -34,5 +46,9 @@ export function TimelineCommunityToJSONTyped(value, ignoreDiscriminator = false)
|
|
|
34
46
|
if (value == null) {
|
|
35
47
|
return value;
|
|
36
48
|
}
|
|
37
|
-
return
|
|
49
|
+
return {
|
|
50
|
+
'__typename': TypeNameToJSON(value['typename']),
|
|
51
|
+
'community_results': CommunityResultToJSON(value['communityResults']),
|
|
52
|
+
'itemType': ContentItemTypeToJSON(value['itemType']),
|
|
53
|
+
};
|
|
38
54
|
}
|
|
@@ -10,17 +10,26 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import type { TypeName } from './TypeName';
|
|
13
|
+
import type { TimelineMessagePromptContent } from './TimelineMessagePromptContent';
|
|
14
|
+
import type { ContentItemType } from './ContentItemType';
|
|
13
15
|
/**
|
|
14
16
|
*
|
|
15
17
|
* @export
|
|
16
18
|
* @interface TimelineMessagePrompt
|
|
17
19
|
*/
|
|
18
20
|
export interface TimelineMessagePrompt {
|
|
19
|
-
[key: string]: any | any;
|
|
20
21
|
/**
|
|
21
22
|
*
|
|
22
23
|
*/
|
|
23
|
-
typename
|
|
24
|
+
typename: TypeName;
|
|
25
|
+
/**
|
|
26
|
+
*
|
|
27
|
+
*/
|
|
28
|
+
content: TimelineMessagePromptContent;
|
|
29
|
+
/**
|
|
30
|
+
*
|
|
31
|
+
*/
|
|
32
|
+
itemType: ContentItemType;
|
|
24
33
|
}
|
|
25
34
|
/**
|
|
26
35
|
* Check if a given object implements the TimelineMessagePrompt interface.
|
|
@@ -12,10 +12,18 @@
|
|
|
12
12
|
* Do not edit the class manually.
|
|
13
13
|
*/
|
|
14
14
|
import { TypeNameFromJSON, TypeNameToJSON, } from './TypeName';
|
|
15
|
+
import { TimelineMessagePromptContentFromJSON, TimelineMessagePromptContentToJSON, } from './TimelineMessagePromptContent';
|
|
16
|
+
import { ContentItemTypeFromJSON, ContentItemTypeToJSON, } from './ContentItemType';
|
|
15
17
|
/**
|
|
16
18
|
* Check if a given object implements the TimelineMessagePrompt interface.
|
|
17
19
|
*/
|
|
18
20
|
export function instanceOfTimelineMessagePrompt(value) {
|
|
21
|
+
if ((!('typename' in value) && !('__typename' in value)) || (value['typename'] === undefined && value['__typename'] === undefined))
|
|
22
|
+
return false;
|
|
23
|
+
if (!('content' in value) || value['content'] === undefined)
|
|
24
|
+
return false;
|
|
25
|
+
if (!('itemType' in value) || value['itemType'] === undefined)
|
|
26
|
+
return false;
|
|
19
27
|
return true;
|
|
20
28
|
}
|
|
21
29
|
export function TimelineMessagePromptFromJSON(json) {
|
|
@@ -25,7 +33,11 @@ export function TimelineMessagePromptFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
25
33
|
if (json == null) {
|
|
26
34
|
return json;
|
|
27
35
|
}
|
|
28
|
-
return
|
|
36
|
+
return {
|
|
37
|
+
'typename': TypeNameFromJSON(json['__typename']),
|
|
38
|
+
'content': TimelineMessagePromptContentFromJSON(json['content']),
|
|
39
|
+
'itemType': ContentItemTypeFromJSON(json['itemType']),
|
|
40
|
+
};
|
|
29
41
|
}
|
|
30
42
|
export function TimelineMessagePromptToJSON(json) {
|
|
31
43
|
return TimelineMessagePromptToJSONTyped(json, false);
|
|
@@ -34,5 +46,9 @@ export function TimelineMessagePromptToJSONTyped(value, ignoreDiscriminator = fa
|
|
|
34
46
|
if (value == null) {
|
|
35
47
|
return value;
|
|
36
48
|
}
|
|
37
|
-
return
|
|
49
|
+
return {
|
|
50
|
+
'__typename': TypeNameToJSON(value['typename']),
|
|
51
|
+
'content': TimelineMessagePromptContentToJSON(value['content']),
|
|
52
|
+
'itemType': ContentItemTypeToJSON(value['itemType']),
|
|
53
|
+
};
|
|
38
54
|
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Twitter OpenAPI
|
|
3
|
+
* Twitter OpenAPI(Swagger) specification
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 0.0.1
|
|
6
|
+
* Contact: yuki@yuki0311.com
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { TimelineMessagePromptButtonAction } from './TimelineMessagePromptButtonAction';
|
|
13
|
+
/**
|
|
14
|
+
*
|
|
15
|
+
* @export
|
|
16
|
+
* @interface TimelineMessagePromptButton
|
|
17
|
+
*/
|
|
18
|
+
export interface TimelineMessagePromptButton {
|
|
19
|
+
/**
|
|
20
|
+
*
|
|
21
|
+
*/
|
|
22
|
+
action: TimelineMessagePromptButtonAction;
|
|
23
|
+
/**
|
|
24
|
+
*
|
|
25
|
+
*/
|
|
26
|
+
text: string;
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Check if a given object implements the TimelineMessagePromptButton interface.
|
|
30
|
+
*/
|
|
31
|
+
export declare function instanceOfTimelineMessagePromptButton(value: object): value is TimelineMessagePromptButton;
|
|
32
|
+
export declare function TimelineMessagePromptButtonFromJSON(json: any): TimelineMessagePromptButton;
|
|
33
|
+
export declare function TimelineMessagePromptButtonFromJSONTyped(json: any, ignoreDiscriminator: boolean): TimelineMessagePromptButton;
|
|
34
|
+
export declare function TimelineMessagePromptButtonToJSON(json: any): TimelineMessagePromptButton;
|
|
35
|
+
export declare function TimelineMessagePromptButtonToJSONTyped(value?: TimelineMessagePromptButton | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,48 @@
|
|
|
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
|
+
import { TimelineMessagePromptButtonActionFromJSON, TimelineMessagePromptButtonActionToJSON, } from './TimelineMessagePromptButtonAction';
|
|
15
|
+
/**
|
|
16
|
+
* Check if a given object implements the TimelineMessagePromptButton interface.
|
|
17
|
+
*/
|
|
18
|
+
export function instanceOfTimelineMessagePromptButton(value) {
|
|
19
|
+
if (!('action' in value) || value['action'] === undefined)
|
|
20
|
+
return false;
|
|
21
|
+
if (!('text' in value) || value['text'] === undefined)
|
|
22
|
+
return false;
|
|
23
|
+
return true;
|
|
24
|
+
}
|
|
25
|
+
export function TimelineMessagePromptButtonFromJSON(json) {
|
|
26
|
+
return TimelineMessagePromptButtonFromJSONTyped(json, false);
|
|
27
|
+
}
|
|
28
|
+
export function TimelineMessagePromptButtonFromJSONTyped(json, ignoreDiscriminator) {
|
|
29
|
+
if (json == null) {
|
|
30
|
+
return json;
|
|
31
|
+
}
|
|
32
|
+
return {
|
|
33
|
+
'action': TimelineMessagePromptButtonActionFromJSON(json['action']),
|
|
34
|
+
'text': json['text'],
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
export function TimelineMessagePromptButtonToJSON(json) {
|
|
38
|
+
return TimelineMessagePromptButtonToJSONTyped(json, false);
|
|
39
|
+
}
|
|
40
|
+
export function TimelineMessagePromptButtonToJSONTyped(value, ignoreDiscriminator = false) {
|
|
41
|
+
if (value == null) {
|
|
42
|
+
return value;
|
|
43
|
+
}
|
|
44
|
+
return {
|
|
45
|
+
'action': TimelineMessagePromptButtonActionToJSON(value['action']),
|
|
46
|
+
'text': value['text'],
|
|
47
|
+
};
|
|
48
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Twitter OpenAPI
|
|
3
|
+
* Twitter OpenAPI(Swagger) specification
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 0.0.1
|
|
6
|
+
* Contact: yuki@yuki0311.com
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface TimelineMessagePromptButtonAction
|
|
16
|
+
*/
|
|
17
|
+
export interface TimelineMessagePromptButtonAction {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
*/
|
|
21
|
+
dismissOnClick: boolean;
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
*/
|
|
25
|
+
url: string;
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Check if a given object implements the TimelineMessagePromptButtonAction interface.
|
|
29
|
+
*/
|
|
30
|
+
export declare function instanceOfTimelineMessagePromptButtonAction(value: object): value is TimelineMessagePromptButtonAction;
|
|
31
|
+
export declare function TimelineMessagePromptButtonActionFromJSON(json: any): TimelineMessagePromptButtonAction;
|
|
32
|
+
export declare function TimelineMessagePromptButtonActionFromJSONTyped(json: any, ignoreDiscriminator: boolean): TimelineMessagePromptButtonAction;
|
|
33
|
+
export declare function TimelineMessagePromptButtonActionToJSON(json: any): TimelineMessagePromptButtonAction;
|
|
34
|
+
export declare function TimelineMessagePromptButtonActionToJSONTyped(value?: TimelineMessagePromptButtonAction | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,47 @@
|
|
|
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
|
+
* Check if a given object implements the TimelineMessagePromptButtonAction interface.
|
|
16
|
+
*/
|
|
17
|
+
export function instanceOfTimelineMessagePromptButtonAction(value) {
|
|
18
|
+
if (!('dismissOnClick' in value) || value['dismissOnClick'] === undefined)
|
|
19
|
+
return false;
|
|
20
|
+
if (!('url' in value) || value['url'] === undefined)
|
|
21
|
+
return false;
|
|
22
|
+
return true;
|
|
23
|
+
}
|
|
24
|
+
export function TimelineMessagePromptButtonActionFromJSON(json) {
|
|
25
|
+
return TimelineMessagePromptButtonActionFromJSONTyped(json, false);
|
|
26
|
+
}
|
|
27
|
+
export function TimelineMessagePromptButtonActionFromJSONTyped(json, ignoreDiscriminator) {
|
|
28
|
+
if (json == null) {
|
|
29
|
+
return json;
|
|
30
|
+
}
|
|
31
|
+
return {
|
|
32
|
+
'dismissOnClick': json['dismissOnClick'],
|
|
33
|
+
'url': json['url'],
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
export function TimelineMessagePromptButtonActionToJSON(json) {
|
|
37
|
+
return TimelineMessagePromptButtonActionToJSONTyped(json, false);
|
|
38
|
+
}
|
|
39
|
+
export function TimelineMessagePromptButtonActionToJSONTyped(value, ignoreDiscriminator = false) {
|
|
40
|
+
if (value == null) {
|
|
41
|
+
return value;
|
|
42
|
+
}
|
|
43
|
+
return {
|
|
44
|
+
'dismissOnClick': value['dismissOnClick'],
|
|
45
|
+
'url': value['url'],
|
|
46
|
+
};
|
|
47
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Twitter OpenAPI
|
|
3
|
+
* Twitter OpenAPI(Swagger) specification
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 0.0.1
|
|
6
|
+
* Contact: yuki@yuki0311.com
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { TimelineMessagePromptButton } from './TimelineMessagePromptButton';
|
|
13
|
+
import type { TimelineMessagePromptRichText } from './TimelineMessagePromptRichText';
|
|
14
|
+
/**
|
|
15
|
+
*
|
|
16
|
+
* @export
|
|
17
|
+
* @interface TimelineMessagePromptContent
|
|
18
|
+
*/
|
|
19
|
+
export interface TimelineMessagePromptContent {
|
|
20
|
+
/**
|
|
21
|
+
*
|
|
22
|
+
*/
|
|
23
|
+
bodyRichText?: TimelineMessagePromptRichText;
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
*/
|
|
27
|
+
bodyText?: string;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
*/
|
|
31
|
+
contentType: TimelineMessagePromptContentContentTypeEnum;
|
|
32
|
+
/**
|
|
33
|
+
*
|
|
34
|
+
*/
|
|
35
|
+
headerText: string;
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
*/
|
|
39
|
+
primaryButtonAction?: TimelineMessagePromptButton;
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* @export
|
|
43
|
+
*/
|
|
44
|
+
export declare const TimelineMessagePromptContentContentTypeEnum: {
|
|
45
|
+
readonly TimelineInlinePrompt: "TimelineInlinePrompt";
|
|
46
|
+
readonly TimelineCompactPrompt: "TimelineCompactPrompt";
|
|
47
|
+
};
|
|
48
|
+
export type TimelineMessagePromptContentContentTypeEnum = typeof TimelineMessagePromptContentContentTypeEnum[keyof typeof TimelineMessagePromptContentContentTypeEnum];
|
|
49
|
+
/**
|
|
50
|
+
* Check if a given object implements the TimelineMessagePromptContent interface.
|
|
51
|
+
*/
|
|
52
|
+
export declare function instanceOfTimelineMessagePromptContent(value: object): value is TimelineMessagePromptContent;
|
|
53
|
+
export declare function TimelineMessagePromptContentFromJSON(json: any): TimelineMessagePromptContent;
|
|
54
|
+
export declare function TimelineMessagePromptContentFromJSONTyped(json: any, ignoreDiscriminator: boolean): TimelineMessagePromptContent;
|
|
55
|
+
export declare function TimelineMessagePromptContentToJSON(json: any): TimelineMessagePromptContent;
|
|
56
|
+
export declare function TimelineMessagePromptContentToJSONTyped(value?: TimelineMessagePromptContent | null, ignoreDiscriminator?: boolean): any;
|