rettiwt-api 1.2.0 → 1.3.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.
Files changed (160) hide show
  1. package/dist/enums/Errors.d.ts +2 -1
  2. package/dist/enums/Errors.js +1 -0
  3. package/dist/enums/Errors.js.map +1 -1
  4. package/dist/graphql/queries/RootQuery.js.map +1 -1
  5. package/dist/graphql/resolvers/TweetResolver.d.ts +5 -5
  6. package/dist/graphql/resolvers/TweetResolver.js +4 -4
  7. package/dist/graphql/resolvers/TweetResolver.js.map +1 -1
  8. package/dist/graphql/types/UserTypes.js.map +1 -1
  9. package/dist/index.d.ts +5 -3
  10. package/dist/index.js +7 -5
  11. package/dist/index.js.map +1 -1
  12. package/dist/models/args/TweetListArgs.js +2 -2
  13. package/dist/models/args/TweetListArgs.js.map +1 -1
  14. package/dist/models/args/UserListArgs.js +2 -2
  15. package/dist/models/args/UserListArgs.js.map +1 -1
  16. package/dist/models/data/Tweet.d.ts +3 -3
  17. package/dist/models/data/Tweet.js.map +1 -1
  18. package/dist/models/data/User.d.ts +2 -2
  19. package/dist/models/data/User.js.map +1 -1
  20. package/dist/services/data/TweetService.d.ts +2 -2
  21. package/dist/services/data/TweetService.js +8 -9
  22. package/dist/services/data/TweetService.js.map +1 -1
  23. package/dist/services/data/UserService.js +12 -22
  24. package/dist/services/data/UserService.js.map +1 -1
  25. package/dist/services/helper/Headers.js +20 -20
  26. package/dist/services/helper/Headers.js.map +1 -1
  27. package/dist/services/helper/extractors/Tweets.d.ts +5 -14
  28. package/dist/services/helper/extractors/Tweets.js +25 -89
  29. package/dist/services/helper/extractors/Tweets.js.map +1 -1
  30. package/dist/services/helper/extractors/Users.d.ts +4 -13
  31. package/dist/services/helper/extractors/Users.js +1 -53
  32. package/dist/services/helper/extractors/Users.js.map +1 -1
  33. package/dist/services/util/FetcherService.d.ts +3 -3
  34. package/dist/services/util/FetcherService.js +10 -22
  35. package/dist/services/util/FetcherService.js.map +1 -1
  36. package/dist/types/Args.d.ts +0 -27
  37. package/dist/types/Args.js +0 -1
  38. package/dist/types/Args.js.map +1 -1
  39. package/docs/assets/search.js +1 -1
  40. package/docs/classes/AccountService.html +17 -17
  41. package/docs/classes/AuthCookie.html +7 -7
  42. package/docs/classes/AuthService.html +7 -7
  43. package/docs/classes/CacheService.html +7 -7
  44. package/docs/classes/Cursor.html +3 -3
  45. package/docs/classes/CursoredData.html +4 -4
  46. package/docs/classes/DataValidationError.html +24 -23
  47. package/docs/classes/FetcherService.html +15 -15
  48. package/docs/classes/Tweet.html +16 -16
  49. package/docs/classes/TweetEntities.html +8 -8
  50. package/docs/classes/TweetFilter.html +58 -56
  51. package/docs/classes/TweetListArgs.html +4 -4
  52. package/docs/classes/TweetService.html +15 -15
  53. package/docs/classes/User.html +18 -18
  54. package/docs/classes/UserListArgs.html +4 -4
  55. package/docs/classes/UserService.html +15 -15
  56. package/docs/enums/HttpMethods.html +3 -3
  57. package/docs/functions/Rettiwt.html +5 -4
  58. package/docs/index.html +4 -3
  59. package/docs/interfaces/IAuthCookie.html +5 -5
  60. package/docs/interfaces/ICursor.html +2 -2
  61. package/docs/interfaces/ICursoredData.html +3 -3
  62. package/docs/interfaces/IDataContext.html +4 -4
  63. package/docs/interfaces/IDataValidationError.html +109 -0
  64. package/docs/interfaces/IListArgs.html +3 -3
  65. package/docs/interfaces/ITweet.html +13 -13
  66. package/docs/interfaces/ITweetEntities.html +5 -5
  67. package/docs/interfaces/ITweetFilter.html +42 -42
  68. package/docs/interfaces/IUser.html +15 -15
  69. package/docs/modules.html +8 -6
  70. package/package.json +3 -2
  71. package/src/enums/Errors.ts +2 -1
  72. package/src/graphql/queries/RootQuery.ts +1 -1
  73. package/src/graphql/resolvers/TweetResolver.ts +12 -59
  74. package/src/graphql/types/UserTypes.ts +1 -1
  75. package/src/index.ts +5 -3
  76. package/src/models/args/TweetListArgs.ts +2 -2
  77. package/src/models/args/UserListArgs.ts +1 -1
  78. package/src/models/data/Tweet.ts +3 -3
  79. package/src/models/data/User.ts +2 -2
  80. package/src/services/data/TweetService.ts +25 -22
  81. package/src/services/data/UserService.ts +38 -42
  82. package/src/services/helper/Headers.ts +32 -32
  83. package/src/services/helper/Parser.ts +2 -2
  84. package/src/services/helper/extractors/Tweets.ts +35 -97
  85. package/src/services/helper/extractors/Users.ts +11 -62
  86. package/src/services/util/FetcherService.ts +13 -20
  87. package/src/types/Args.ts +0 -37
  88. package/Dockerfile +0 -9
  89. package/dist/models/args/TweetFilter.d.ts +0 -65
  90. package/dist/models/args/TweetFilter.js +0 -121
  91. package/dist/models/args/TweetFilter.js.map +0 -1
  92. package/dist/models/errors/DataValidationError.d.ts +0 -20
  93. package/dist/models/errors/DataValidationError.js +0 -23
  94. package/dist/models/errors/DataValidationError.js.map +0 -1
  95. package/dist/twitter/Url.d.ts +0 -22
  96. package/dist/twitter/Url.js +0 -32
  97. package/dist/twitter/Url.js.map +0 -1
  98. package/dist/twitter/enums/Resources.d.ts +0 -15
  99. package/dist/twitter/enums/Resources.js +0 -21
  100. package/dist/twitter/enums/Resources.js.map +0 -1
  101. package/dist/twitter/params/Query.d.ts +0 -67
  102. package/dist/twitter/params/Query.js +0 -64
  103. package/dist/twitter/params/Query.js.map +0 -1
  104. package/dist/twitter/payloads/Args.d.ts +0 -16
  105. package/dist/twitter/payloads/Args.js +0 -16
  106. package/dist/twitter/payloads/Args.js.map +0 -1
  107. package/dist/twitter/payloads/Features.d.ts +0 -28
  108. package/dist/twitter/payloads/Features.js +0 -37
  109. package/dist/twitter/payloads/Features.js.map +0 -1
  110. package/dist/twitter/payloads/Variables.d.ts +0 -41
  111. package/dist/twitter/payloads/Variables.js +0 -64
  112. package/dist/twitter/payloads/Variables.js.map +0 -1
  113. package/dist/twitter/types/request/Query.d.ts +0 -86
  114. package/dist/twitter/types/request/Query.js +0 -4
  115. package/dist/twitter/types/request/Query.js.map +0 -1
  116. package/dist/twitter/types/tweet/Favouriters.d.ts +0 -164
  117. package/dist/twitter/types/tweet/Favouriters.js +0 -3
  118. package/dist/twitter/types/tweet/Favouriters.js.map +0 -1
  119. package/dist/twitter/types/tweet/Retweeters.d.ts +0 -171
  120. package/dist/twitter/types/tweet/Retweeters.js +0 -3
  121. package/dist/twitter/types/tweet/Retweeters.js.map +0 -1
  122. package/dist/twitter/types/tweet/Tweet.d.ts +0 -746
  123. package/dist/twitter/types/tweet/Tweet.js +0 -3
  124. package/dist/twitter/types/tweet/Tweet.js.map +0 -1
  125. package/dist/twitter/types/tweet/Tweets.d.ts +0 -386
  126. package/dist/twitter/types/tweet/Tweets.js +0 -3
  127. package/dist/twitter/types/tweet/Tweets.js.map +0 -1
  128. package/dist/twitter/types/user/Followers.d.ts +0 -176
  129. package/dist/twitter/types/user/Followers.js +0 -3
  130. package/dist/twitter/types/user/Followers.js.map +0 -1
  131. package/dist/twitter/types/user/Following.d.ts +0 -176
  132. package/dist/twitter/types/user/Following.js +0 -3
  133. package/dist/twitter/types/user/Following.js.map +0 -1
  134. package/dist/twitter/types/user/Likes.d.ts +0 -1059
  135. package/dist/twitter/types/user/Likes.js +0 -3
  136. package/dist/twitter/types/user/Likes.js.map +0 -1
  137. package/dist/twitter/types/user/Tweets.d.ts +0 -1512
  138. package/dist/twitter/types/user/Tweets.js +0 -3
  139. package/dist/twitter/types/user/Tweets.js.map +0 -1
  140. package/dist/twitter/types/user/User.d.ts +0 -117
  141. package/dist/twitter/types/user/User.js +0 -3
  142. package/dist/twitter/types/user/User.js.map +0 -1
  143. package/src/models/args/TweetFilter.ts +0 -140
  144. package/src/models/errors/DataValidationError.ts +0 -29
  145. package/src/twitter/Url.ts +0 -37
  146. package/src/twitter/enums/Resources.ts +0 -15
  147. package/src/twitter/params/Query.ts +0 -100
  148. package/src/twitter/payloads/Args.ts +0 -21
  149. package/src/twitter/payloads/Features.ts +0 -33
  150. package/src/twitter/payloads/Variables.ts +0 -73
  151. package/src/twitter/types/request/Query.ts +0 -91
  152. package/src/twitter/types/tweet/Favouriters.ts +0 -193
  153. package/src/twitter/types/tweet/Retweeters.ts +0 -201
  154. package/src/twitter/types/tweet/Tweet.ts +0 -882
  155. package/src/twitter/types/tweet/Tweets.ts +0 -444
  156. package/src/twitter/types/user/Followers.ts +0 -208
  157. package/src/twitter/types/user/Following.ts +0 -208
  158. package/src/twitter/types/user/Likes.ts +0 -1247
  159. package/src/twitter/types/user/Tweets.ts +0 -1747
  160. package/src/twitter/types/user/User.ts +0 -135
@@ -1,64 +0,0 @@
1
- "use strict";
2
- exports.__esModule = true;
3
- exports.Query = void 0;
4
- // PAYLOADS
5
- var Variables_1 = require("../payloads/Variables");
6
- var Features_1 = require("../payloads/Features");
7
- // ENUMS
8
- var Resources_1 = require("../enums/Resources");
9
- /**
10
- * The URL query parameters that must be sent while making requests to Twitter API.
11
- */
12
- var Query = /** @class */ (function () {
13
- /**
14
- * Initializes the URL parameters.
15
- *
16
- * @param resourceType The type of resource requested.
17
- * @param args Additional user-defined arguments to be sent in the request.
18
- */
19
- function Query(resourceType, args) {
20
- var _a;
21
- this.include_entities = true;
22
- this.include_quote_count = true;
23
- this.include_reply_count = 1;
24
- this.include_user_entities = true;
25
- this.include_want_retweets = 1;
26
- this.tweet_mode = 'extended';
27
- this.tweet_search_mode = 'live';
28
- /**
29
- * Only the endpoint for fetching tweets (using advanced search) requires the parameters defined in this class.
30
- * All other endpoints required only 'variables' and 'features' fields.
31
- */
32
- if (resourceType == Resources_1.ResourceType.TWEETS) {
33
- this.q = encodeURIComponent((_a = args.query) !== null && _a !== void 0 ? _a : '');
34
- this.count = args.count;
35
- this.cursor = args.cursor;
36
- }
37
- else {
38
- this.variables = new Variables_1.Variables(resourceType, args).toString();
39
- this.features = new Features_1.Features().toString();
40
- }
41
- }
42
- /**
43
- * Converts this object to it's string representation.
44
- *
45
- * @returns 'this' object's string representation;
46
- */
47
- Query.prototype.toString = function () {
48
- /**
49
- * This first filters out all the empty paramters.
50
- * Then it formats each parameter key value pair as 'key=value'.
51
- * Then it joins the list of all formatted parameters using '&' as a separator.
52
- */
53
- return Object.entries(this).filter(function (_a) {
54
- var key = _a[0], value = _a[1];
55
- return value;
56
- }).map(function (_a) {
57
- var key = _a[0], value = _a[1];
58
- return "".concat(key, "=").concat(value);
59
- }).join('&');
60
- };
61
- return Query;
62
- }());
63
- exports.Query = Query;
64
- //# sourceMappingURL=Query.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Query.js","sourceRoot":"","sources":["../../../src/twitter/params/Query.ts"],"names":[],"mappings":";;;AAAA,WAAW;AACX,mDAAkD;AAClD,iDAAgD;AAMhD,QAAQ;AACR,gDAAkD;AAElD;;GAEG;AACH;IAkDI;;;;;OAKG;IACH,eAAY,YAA0B,EAAE,IAAU;;QA9ClD,qBAAgB,GAAa,IAAI,CAAC;QAgBlC,wBAAmB,GAAa,IAAI,CAAC;QACrC,wBAAmB,GAAY,CAAC,CAAC;QACjC,0BAAqB,GAAa,IAAI,CAAC;QACvC,0BAAqB,GAAY,CAAC,CAAC;QAQnC,eAAU,GAAY,UAAU,CAAC;QACjC,sBAAiB,GAAY,MAAM,CAAC;QAmBhC;;;WAGG;QACH,IAAI,YAAY,IAAI,wBAAY,CAAC,MAAM,EAAE;YACrC,IAAI,CAAC,CAAC,GAAG,kBAAkB,CAAC,MAAA,IAAI,CAAC,KAAK,mCAAI,EAAE,CAAC,CAAC;YAC9C,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;YACxB,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC;SAC7B;aACI;YACD,IAAI,CAAC,SAAS,GAAG,IAAI,qBAAS,CAAC,YAAY,EAAE,IAAI,CAAC,CAAC,QAAQ,EAAE,CAAC;YAC9D,IAAI,CAAC,QAAQ,GAAG,IAAI,mBAAQ,EAAE,CAAC,QAAQ,EAAE,CAAC;SAC7C;IACL,CAAC;IAED;;;;OAIG;IACH,wBAAQ,GAAR;QACI;;;;WAIG;QACH,OAAO,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,MAAM,CAAC,UAAC,EAAY;gBAAX,GAAG,QAAA,EAAE,KAAK,QAAA;YAAM,OAAA,KAAK;QAAL,CAAK,CAAC,CAAC,GAAG,CAAC,UAAC,EAAY;gBAAX,GAAG,QAAA,EAAE,KAAK,QAAA;YAAM,OAAA,UAAG,GAAG,cAAI,KAAK,CAAE;QAAjB,CAAiB,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;IACnH,CAAC;IACL,YAAC;AAAD,CAAC,AArFD,IAqFC;AArFY,sBAAK"}
@@ -1,16 +0,0 @@
1
- import { IArgs } from '../types/request/Query';
2
- /**
3
- * The arguments for fetching cursored list.
4
- *
5
- * @public
6
- */
7
- export declare class Args implements IArgs {
8
- /** The query string that may be used to filter data. */
9
- query?: string;
10
- /** The rest id of the data item to be requested. */
11
- id?: string;
12
- /** The number of data items to fetch. */
13
- count?: number;
14
- /** The cursor to the batch of data to fetch. */
15
- cursor?: string;
16
- }
@@ -1,16 +0,0 @@
1
- "use strict";
2
- exports.__esModule = true;
3
- exports.Args = void 0;
4
- /**
5
- * The arguments for fetching cursored list.
6
- *
7
- * @public
8
- */
9
- var Args = /** @class */ (function () {
10
- function Args() {
11
- }
12
- return Args;
13
- }());
14
- exports.Args = Args;
15
- ;
16
- //# sourceMappingURL=Args.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Args.js","sourceRoot":"","sources":["../../../src/twitter/payloads/Args.ts"],"names":[],"mappings":";;;AAGA;;;;GAIG;AACH;IAAA;IAYA,CAAC;IAAD,WAAC;AAAD,CAAC,AAZD,IAYC;AAZY,oBAAI;AAYhB,CAAC"}
@@ -1,28 +0,0 @@
1
- import { IFeatures } from '../types/request/Query';
2
- /**
3
- * The additional features that may be fetched while making requests to Twitter API.
4
- */
5
- export declare class Features implements IFeatures {
6
- graphql_is_translatable_rweb_tweet_is_translatable_enabled: boolean;
7
- interactive_text_enabled: boolean;
8
- longform_notetweets_consumption_enabled: boolean;
9
- responsive_web_edit_tweet_api_enabled: boolean;
10
- responsive_web_enhance_cards_enabled: boolean;
11
- responsive_web_graphql_timeline_navigation_enabled: boolean;
12
- responsive_web_text_conversations_enabled: boolean;
13
- responsive_web_twitter_blue_verified_badge_is_enabled: boolean;
14
- responsive_web_uc_gql_enabled: boolean;
15
- standardized_nudges_misinfo: boolean;
16
- tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled: boolean;
17
- tweetypie_unmention_optimization_enabled: boolean;
18
- verified_phone_label_enabled: boolean;
19
- vibe_api_enabled: boolean;
20
- view_counts_everywhere_api_enabled: boolean;
21
- view_counts_public_visibility_enabled: boolean;
22
- /**
23
- * Converts this object to it's string representation.
24
- *
25
- * @returns 'this' object's string representation.
26
- */
27
- toString(): string;
28
- }
@@ -1,37 +0,0 @@
1
- "use strict";
2
- exports.__esModule = true;
3
- exports.Features = void 0;
4
- /**
5
- * The additional features that may be fetched while making requests to Twitter API.
6
- */
7
- var Features = /** @class */ (function () {
8
- function Features() {
9
- this.graphql_is_translatable_rweb_tweet_is_translatable_enabled = false;
10
- this.interactive_text_enabled = false;
11
- this.longform_notetweets_consumption_enabled = false;
12
- this.responsive_web_edit_tweet_api_enabled = false;
13
- this.responsive_web_enhance_cards_enabled = false;
14
- this.responsive_web_graphql_timeline_navigation_enabled = false;
15
- this.responsive_web_text_conversations_enabled = false;
16
- this.responsive_web_twitter_blue_verified_badge_is_enabled = false;
17
- this.responsive_web_uc_gql_enabled = false;
18
- this.standardized_nudges_misinfo = false;
19
- this.tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled = false;
20
- this.tweetypie_unmention_optimization_enabled = false;
21
- this.verified_phone_label_enabled = false;
22
- this.vibe_api_enabled = false;
23
- this.view_counts_everywhere_api_enabled = false;
24
- this.view_counts_public_visibility_enabled = false;
25
- }
26
- /**
27
- * Converts this object to it's string representation.
28
- *
29
- * @returns 'this' object's string representation.
30
- */
31
- Features.prototype.toString = function () {
32
- return "".concat(encodeURIComponent(JSON.stringify(this)));
33
- };
34
- return Features;
35
- }());
36
- exports.Features = Features;
37
- //# sourceMappingURL=Features.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Features.js","sourceRoot":"","sources":["../../../src/twitter/payloads/Features.ts"],"names":[],"mappings":";;;AAGA;;GAEG;AACH;IAAA;QACI,+DAA0D,GAAG,KAAK,CAAC;QACnE,6BAAwB,GAAG,KAAK,CAAC;QACjC,4CAAuC,GAAG,KAAK,CAAC;QAChD,0CAAqC,GAAG,KAAK,CAAC;QAC9C,yCAAoC,GAAG,KAAK,CAAC;QAC7C,uDAAkD,GAAG,KAAK,CAAC;QAC3D,8CAAyC,GAAG,KAAK,CAAC;QAClD,0DAAqD,GAAG,KAAK,CAAC;QAC9D,kCAA6B,GAAG,KAAK,CAAC;QACtC,gCAA2B,GAAG,KAAK,CAAC;QACpC,4EAAuE,GAAG,KAAK,CAAC;QAChF,6CAAwC,GAAG,KAAK,CAAC;QACjD,iCAA4B,GAAG,KAAK,CAAC;QACrC,qBAAgB,GAAG,KAAK,CAAC;QACzB,uCAAkC,GAAG,KAAK,CAAC;QAC3C,0CAAqC,GAAG,KAAK,CAAC;IAUlD,CAAC;IARG;;;;OAIG;IACH,2BAAQ,GAAR;QACI,OAAO,UAAG,kBAAkB,CAAC,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,CAAE,CAAC;IACzD,CAAC;IACL,eAAC;AAAD,CAAC,AA1BD,IA0BC;AA1BY,4BAAQ"}
@@ -1,41 +0,0 @@
1
- import { Args } from './Args';
2
- import { IVariables } from '../types/request/Query';
3
- import { ResourceType } from '../enums/Resources';
4
- /**
5
- * The variables that must be sent as payload while making requests to Twitter API.
6
- */
7
- export declare class Variables implements IVariables {
8
- tweetId?: string;
9
- focalTweetId?: string;
10
- userId?: string;
11
- screen_name?: string;
12
- count?: number;
13
- cursor?: string;
14
- includePromotedContent: boolean;
15
- referrer: string;
16
- withBirdwatchNotes: boolean;
17
- withCommunity: boolean;
18
- withDownvotePerspective: boolean;
19
- withQuickPromoteEligibilityTweetFields: boolean;
20
- withReactionsMetadata: boolean;
21
- withReactionsPerspective: boolean;
22
- withSuperFollowsTweetFields: boolean;
23
- withSuperFollowsUserFields: boolean;
24
- withV2Timeline: boolean;
25
- withVoice: boolean;
26
- with_rux_injections: boolean;
27
- withClientEventToken: boolean;
28
- /**
29
- * Initializes the appropriate Variables object based on the requred resource type and parameters.
30
- *
31
- * @param resourceType The type of resource that is requested.
32
- * @param args The additional user-defined arguments for fetching the resource.
33
- */
34
- constructor(resourceType: ResourceType, args: Args);
35
- /**
36
- * Converts this object to it's string representation.
37
- *
38
- * @returns 'this' object's string representation.
39
- */
40
- toString(): string;
41
- }
@@ -1,64 +0,0 @@
1
- "use strict";
2
- exports.__esModule = true;
3
- exports.Variables = void 0;
4
- // ENUMS
5
- var Resources_1 = require("../enums/Resources");
6
- /**
7
- * The variables that must be sent as payload while making requests to Twitter API.
8
- */
9
- var Variables = /** @class */ (function () {
10
- /**
11
- * Initializes the appropriate Variables object based on the requred resource type and parameters.
12
- *
13
- * @param resourceType The type of resource that is requested.
14
- * @param args The additional user-defined arguments for fetching the resource.
15
- */
16
- function Variables(resourceType, args) {
17
- this.includePromotedContent = false;
18
- this.referrer = '';
19
- this.withBirdwatchNotes = false;
20
- this.withCommunity = false;
21
- this.withDownvotePerspective = false;
22
- this.withQuickPromoteEligibilityTweetFields = false;
23
- this.withReactionsMetadata = false;
24
- this.withReactionsPerspective = false;
25
- this.withSuperFollowsTweetFields = false;
26
- this.withSuperFollowsUserFields = false;
27
- this.withV2Timeline = true;
28
- this.withVoice = false;
29
- this.with_rux_injections = false;
30
- this.withClientEventToken = false;
31
- if (resourceType == Resources_1.ResourceType.TWEET_DETAILS) {
32
- this.focalTweetId = args.id;
33
- this.count = args.count;
34
- this.cursor = args.cursor;
35
- }
36
- else if (resourceType == Resources_1.ResourceType.TWEET_LIKES || resourceType == Resources_1.ResourceType.TWEET_RETWEETS) {
37
- this.tweetId = args.id;
38
- this.count = args.count;
39
- this.cursor = args.cursor;
40
- }
41
- else if (resourceType == Resources_1.ResourceType.USER_DETAILS) {
42
- this.screen_name = args.id;
43
- }
44
- else if (resourceType == Resources_1.ResourceType.USER_DETAILS_BY_ID) {
45
- this.userId = args.id;
46
- }
47
- else if (resourceType == Resources_1.ResourceType.USER_FOLLOWERS || resourceType == Resources_1.ResourceType.USER_FOLLOWING || resourceType == Resources_1.ResourceType.USER_LIKES || resourceType == Resources_1.ResourceType.USER_TWEETS) {
48
- this.userId = args.id;
49
- this.count = args.count;
50
- this.cursor = args.cursor;
51
- }
52
- }
53
- /**
54
- * Converts this object to it's string representation.
55
- *
56
- * @returns 'this' object's string representation.
57
- */
58
- Variables.prototype.toString = function () {
59
- return "".concat(encodeURIComponent(JSON.stringify(this)));
60
- };
61
- return Variables;
62
- }());
63
- exports.Variables = Variables;
64
- //# sourceMappingURL=Variables.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Variables.js","sourceRoot":"","sources":["../../../src/twitter/payloads/Variables.ts"],"names":[],"mappings":";;;AAMA,QAAQ;AACR,gDAAkD;AAElD;;GAEG;AACH;IAsBI;;;;;OAKG;IACH,mBAAY,YAA0B,EAAE,IAAU;QArBlD,2BAAsB,GAAY,KAAK,CAAC;QACxC,aAAQ,GAAW,EAAE,CAAC;QACtB,uBAAkB,GAAY,KAAK,CAAC;QACpC,kBAAa,GAAY,KAAK,CAAC;QAC/B,4BAAuB,GAAY,KAAK,CAAC;QACzC,2CAAsC,GAAY,KAAK,CAAC;QACxD,0BAAqB,GAAY,KAAK,CAAC;QACvC,6BAAwB,GAAY,KAAK,CAAC;QAC1C,gCAA2B,GAAY,KAAK,CAAC;QAC7C,+BAA0B,GAAY,KAAK,CAAC;QAC5C,mBAAc,GAAY,IAAI,CAAC;QAC/B,cAAS,GAAY,KAAK,CAAC;QAC3B,wBAAmB,GAAY,KAAK,CAAC;QACrC,yBAAoB,GAAY,KAAK,CAAC;QASlC,IAAI,YAAY,IAAI,wBAAY,CAAC,aAAa,EAAE;YAC5C,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,EAAE,CAAC;YAC5B,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;YACxB,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC;SAC7B;aACI,IAAI,YAAY,IAAI,wBAAY,CAAC,WAAW,IAAI,YAAY,IAAI,wBAAY,CAAC,cAAc,EAAE;YAC9F,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,EAAE,CAAC;YACvB,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;YACxB,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC;SAC7B;aACI,IAAI,YAAY,IAAI,wBAAY,CAAC,YAAY,EAAE;YAChD,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC,EAAE,CAAC;SAC9B;aACI,IAAI,YAAY,IAAI,wBAAY,CAAC,kBAAkB,EAAE;YACtD,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,EAAE,CAAC;SACzB;aACI,IAAI,YAAY,IAAI,wBAAY,CAAC,cAAc,IAAI,YAAY,IAAI,wBAAY,CAAC,cAAc,IAAI,YAAY,IAAI,wBAAY,CAAC,UAAU,IAAI,YAAY,IAAI,wBAAY,CAAC,WAAW,EAAE;YACxL,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,EAAE,CAAC;YACtB,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;YACxB,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC;SAC7B;IACL,CAAC;IAED;;;;OAIG;IACH,4BAAQ,GAAR;QACI,OAAO,UAAG,kBAAkB,CAAC,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,CAAE,CAAC;IACzD,CAAC;IACL,gBAAC;AAAD,CAAC,AA5DD,IA4DC;AA5DY,8BAAS"}
@@ -1,86 +0,0 @@
1
- export interface IArgs {
2
- query?: string;
3
- id?: string;
4
- count?: number;
5
- cursor?: string;
6
- }
7
- export interface IVariables {
8
- tweetId?: string;
9
- focalTweetId?: string;
10
- userId?: string;
11
- screen_name?: string;
12
- count?: number;
13
- cursor?: string;
14
- includePromotedContent: boolean;
15
- referrer: string;
16
- withBirdwatchNotes: boolean;
17
- withCommunity: boolean;
18
- withDownvotePerspective: boolean;
19
- withQuickPromoteEligibilityTweetFields: boolean;
20
- withReactionsMetadata: boolean;
21
- withReactionsPerspective: boolean;
22
- withSuperFollowsTweetFields: boolean;
23
- withSuperFollowsUserFields: boolean;
24
- withV2Timeline: boolean;
25
- withVoice: boolean;
26
- with_rux_injections: boolean;
27
- withClientEventToken: boolean;
28
- }
29
- export interface IFeatures {
30
- graphql_is_translatable_rweb_tweet_is_translatable_enabled: boolean;
31
- interactive_text_enabled: boolean;
32
- longform_notetweets_consumption_enabled: boolean;
33
- responsive_web_edit_tweet_api_enabled: boolean;
34
- responsive_web_enhance_cards_enabled: boolean;
35
- responsive_web_graphql_timeline_navigation_enabled: boolean;
36
- responsive_web_text_conversations_enabled: boolean;
37
- responsive_web_twitter_blue_verified_badge_is_enabled: boolean;
38
- responsive_web_uc_gql_enabled: boolean;
39
- standardized_nudges_misinfo: boolean;
40
- tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled: boolean;
41
- tweetypie_unmention_optimization_enabled: boolean;
42
- verified_phone_label_enabled: boolean;
43
- vibe_api_enabled: boolean;
44
- view_counts_everywhere_api_enabled: boolean;
45
- view_counts_public_visibility_enabled: boolean;
46
- }
47
- export interface IQuery {
48
- cards_platform?: string;
49
- count?: number;
50
- cursor?: string;
51
- ext?: string;
52
- include_blocked_by?: number;
53
- include_blocking?: number;
54
- include_can_dm?: number;
55
- include_can_media_tag?: number;
56
- include_cards?: number;
57
- include_entities?: boolean;
58
- include_ext_alt_text?: boolean;
59
- include_ext_collab_control?: boolean;
60
- include_ext_edit_control?: boolean;
61
- include_ext_has_nft_avatar?: number;
62
- include_ext_is_blue_verified?: number;
63
- include_ext_limited_action_results?: boolean;
64
- include_ext_media_availability?: boolean;
65
- include_ext_media_color?: boolean;
66
- include_ext_sensitive_media_warning?: boolean;
67
- include_ext_trusted_friends_metadata?: boolean;
68
- include_ext_verified_type?: number;
69
- include_ext_views?: boolean;
70
- include_followed_by?: number;
71
- include_mute_edge?: number;
72
- include_profile_interstitial_type?: number;
73
- include_quote_count?: boolean;
74
- include_reply_count?: number;
75
- include_user_entities?: boolean;
76
- include_want_retweets?: number;
77
- pc?: number;
78
- q?: string;
79
- query_source?: string;
80
- send_error_codes?: boolean;
81
- simple_quoted_tweet?: boolean;
82
- skip_status?: number;
83
- spelling_corrections?: number;
84
- tweet_mode?: string;
85
- tweet_search_mode?: string;
86
- }
@@ -1,4 +0,0 @@
1
- "use strict";
2
- exports.__esModule = true;
3
- ;
4
- //# sourceMappingURL=Query.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Query.js","sourceRoot":"","sources":["../../../../src/twitter/types/request/Query.ts"],"names":[],"mappings":";;AAKC,CAAC"}
@@ -1,164 +0,0 @@
1
- export default interface Root {
2
- data: Data;
3
- }
4
- export interface Data {
5
- favoriters_timeline: FavoritersTimeline;
6
- }
7
- export interface FavoritersTimeline {
8
- timeline: Timeline;
9
- }
10
- export interface Timeline {
11
- instructions: Instruction[];
12
- responseObjects: ResponseObjects;
13
- }
14
- export interface Instruction {
15
- type: string;
16
- entries: Entry[];
17
- }
18
- export interface Entry {
19
- entryId: string;
20
- sortIndex: string;
21
- content: Content;
22
- }
23
- export interface Content {
24
- entryType: string;
25
- itemContent?: ItemContent;
26
- value?: string;
27
- cursorType?: string;
28
- stopOnEmptyResponse?: boolean;
29
- }
30
- export interface ItemContent {
31
- itemType: string;
32
- user_results: UserResults;
33
- userDisplayType: string;
34
- }
35
- export interface UserResults {
36
- result: Result;
37
- }
38
- export interface Result {
39
- __typename: string;
40
- id: string;
41
- rest_id: string;
42
- affiliates_highlighted_label: AffiliatesHighlightedLabel;
43
- has_nft_avatar: boolean;
44
- legacy: Legacy;
45
- professional?: Professional;
46
- super_follow_eligible: boolean;
47
- super_followed_by: boolean;
48
- super_following: boolean;
49
- }
50
- export interface AffiliatesHighlightedLabel {
51
- }
52
- export interface Legacy {
53
- blocked_by: boolean;
54
- blocking: boolean;
55
- can_dm: boolean;
56
- can_media_tag: boolean;
57
- created_at: string;
58
- default_profile: boolean;
59
- default_profile_image: boolean;
60
- description: string;
61
- entities: Entities;
62
- fast_followers_count: number;
63
- favourites_count: number;
64
- follow_request_sent: boolean;
65
- followed_by: boolean;
66
- followers_count: number;
67
- following: boolean;
68
- friends_count: number;
69
- has_custom_timelines: boolean;
70
- is_translator: boolean;
71
- listed_count: number;
72
- location: string;
73
- media_count: number;
74
- muting: boolean;
75
- name: string;
76
- normal_followers_count: number;
77
- notifications: boolean;
78
- pinned_tweet_ids_str: string[];
79
- possibly_sensitive: boolean;
80
- profile_banner_extensions?: ProfileBannerExtensions;
81
- profile_banner_url?: string;
82
- profile_image_extensions?: ProfileImageExtensions;
83
- profile_image_url_https: string;
84
- profile_interstitial_type: string;
85
- protected: boolean;
86
- screen_name: string;
87
- statuses_count: number;
88
- translator_type: string;
89
- url?: string;
90
- verified: boolean;
91
- want_retweets: boolean;
92
- withheld_in_countries: any[];
93
- }
94
- export interface Entities {
95
- description: Description;
96
- url?: Url;
97
- }
98
- export interface Description {
99
- urls: any[];
100
- }
101
- export interface Url {
102
- urls: Url2[];
103
- }
104
- export interface Url2 {
105
- display_url: string;
106
- expanded_url: string;
107
- url: string;
108
- indices: number[];
109
- }
110
- export interface ProfileBannerExtensions {
111
- mediaColor: MediaColor;
112
- }
113
- export interface MediaColor {
114
- r: R;
115
- }
116
- export interface R {
117
- ok: Ok;
118
- }
119
- export interface Ok {
120
- palette: Palette[];
121
- }
122
- export interface Palette {
123
- percentage: number;
124
- rgb: Rgb;
125
- }
126
- export interface Rgb {
127
- blue: number;
128
- green: number;
129
- red: number;
130
- }
131
- export interface ProfileImageExtensions {
132
- mediaColor: MediaColor2;
133
- }
134
- export interface MediaColor2 {
135
- r: R2;
136
- }
137
- export interface R2 {
138
- ok: Ok2;
139
- }
140
- export interface Ok2 {
141
- palette: Palette2[];
142
- }
143
- export interface Palette2 {
144
- percentage: number;
145
- rgb: Rgb2;
146
- }
147
- export interface Rgb2 {
148
- blue: number;
149
- green: number;
150
- red: number;
151
- }
152
- export interface Professional {
153
- rest_id: string;
154
- professional_type: string;
155
- category: Category[];
156
- }
157
- export interface Category {
158
- id: number;
159
- name: string;
160
- }
161
- export interface ResponseObjects {
162
- feedbackActions: any[];
163
- immediateReactions: any[];
164
- }
@@ -1,3 +0,0 @@
1
- "use strict";
2
- exports.__esModule = true;
3
- //# sourceMappingURL=Favouriters.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Favouriters.js","sourceRoot":"","sources":["../../../../src/twitter/types/tweet/Favouriters.ts"],"names":[],"mappings":""}