consts.nim 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. # SPDX-License-Identifier: AGPL-3.0-only
  2. import uri, strutils
  3. const
  4. consumerKey* = "3nVuSoBZnx6U4vzUxf5w"
  5. consumerSecret* = "Bcs59EFbbsdF6Sl9Ng71smgStWEGwXXKSjYvPVt7qys"
  6. gql = parseUri("https://api.x.com") / "graphql"
  7. graphUser* = gql / "u7wQyGi6oExe8_TRWGMq4Q/UserResultByScreenNameQuery"
  8. graphUserById* = gql / "oPppcargziU1uDQHAUmH-A/UserResultByIdQuery"
  9. graphUserTweets* = gql / "JLApJKFY0MxGTzCoK6ps8Q/UserWithProfileTweetsQueryV2"
  10. graphUserTweetsAndReplies* = gql / "Y86LQY7KMvxn5tu3hFTyPg/UserWithProfileTweetsAndRepliesQueryV2"
  11. graphUserMedia* = gql / "PDfFf8hGeJvUCiTyWtw4wQ/MediaTimelineV2"
  12. graphTweet* = gql / "Vorskcd2tZ-tc4Gx3zbk4Q/ConversationTimelineV2"
  13. graphTweetResult* = gql / "sITyJdhRPpvpEjg4waUmTA/TweetResultByIdQuery"
  14. graphSearchTimeline* = gql / "KI9jCXUx3Ymt-hDKLOZb9Q/SearchTimeline"
  15. graphListById* = gql / "oygmAig8kjn0pKsx_bUadQ/ListByRestId"
  16. graphListBySlug* = gql / "88GTz-IPPWLn1EiU8XoNVg/ListBySlug"
  17. graphListMembers* = gql / "kSmxeqEeelqdHSR7jMnb_w/ListMembers"
  18. graphListTweets* = gql / "BbGLL1ZfMibdFNWlk7a0Pw/ListTimeline"
  19. gqlFeatures* = """{
  20. "android_graphql_skip_api_media_color_palette": false,
  21. "blue_business_profile_image_shape_enabled": false,
  22. "creator_subscriptions_subscription_count_enabled": false,
  23. "creator_subscriptions_tweet_preview_api_enabled": true,
  24. "freedom_of_speech_not_reach_fetch_enabled": false,
  25. "graphql_is_translatable_rweb_tweet_is_translatable_enabled": false,
  26. "hidden_profile_likes_enabled": false,
  27. "highlights_tweets_tab_ui_enabled": false,
  28. "interactive_text_enabled": false,
  29. "longform_notetweets_consumption_enabled": true,
  30. "longform_notetweets_inline_media_enabled": false,
  31. "longform_notetweets_richtext_consumption_enabled": true,
  32. "longform_notetweets_rich_text_read_enabled": false,
  33. "responsive_web_edit_tweet_api_enabled": false,
  34. "responsive_web_enhance_cards_enabled": false,
  35. "responsive_web_graphql_exclude_directive_enabled": true,
  36. "responsive_web_graphql_skip_user_profile_image_extensions_enabled": false,
  37. "responsive_web_graphql_timeline_navigation_enabled": false,
  38. "responsive_web_media_download_video_enabled": false,
  39. "responsive_web_text_conversations_enabled": false,
  40. "responsive_web_twitter_article_tweet_consumption_enabled": false,
  41. "responsive_web_twitter_blue_verified_badge_is_enabled": true,
  42. "rweb_lists_timeline_redesign_enabled": true,
  43. "spaces_2022_h2_clipping": true,
  44. "spaces_2022_h2_spaces_communities": true,
  45. "standardized_nudges_misinfo": false,
  46. "subscriptions_verification_info_enabled": true,
  47. "subscriptions_verification_info_reason_enabled": true,
  48. "subscriptions_verification_info_verified_since_enabled": true,
  49. "super_follow_badge_privacy_enabled": false,
  50. "super_follow_exclusive_tweet_notifications_enabled": false,
  51. "super_follow_tweet_api_enabled": false,
  52. "super_follow_user_api_enabled": false,
  53. "tweet_awards_web_tipping_enabled": false,
  54. "tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled": false,
  55. "tweetypie_unmention_optimization_enabled": false,
  56. "unified_cards_ad_metadata_container_dynamic_card_content_query_enabled": false,
  57. "verified_phone_label_enabled": false,
  58. "vibe_api_enabled": false,
  59. "view_counts_everywhere_api_enabled": false,
  60. "premium_content_api_read_enabled": false,
  61. "communities_web_enable_tweet_community_results_fetch": false,
  62. "responsive_web_jetfuel_frame": false,
  63. "responsive_web_grok_analyze_button_fetch_trends_enabled": false,
  64. "responsive_web_grok_image_annotation_enabled": false,
  65. "rweb_tipjar_consumption_enabled": false,
  66. "profile_label_improvements_pcf_label_in_post_enabled": false,
  67. "creator_subscriptions_quote_tweet_preview_enabled": false,
  68. "c9s_tweet_anatomy_moderator_badge_enabled": false,
  69. "responsive_web_grok_analyze_post_followups_enabled": false,
  70. "rweb_video_timestamps_enabled": false,
  71. "responsive_web_grok_share_attachment_enabled": false,
  72. "articles_preview_enabled": false,
  73. "immersive_video_status_linkable_timestamps": false,
  74. "articles_api_enabled": false,
  75. "responsive_web_grok_analysis_button_from_backend": false
  76. }""".replace(" ", "").replace("\n", "")
  77. tweetVariables* = """{
  78. "focalTweetId": "$1",
  79. $2
  80. "includeHasBirdwatchNotes": false,
  81. "includePromotedContent": false,
  82. "withBirdwatchNotes": false,
  83. "withVoice": false,
  84. "withV2Timeline": true
  85. }""".replace(" ", "").replace("\n", "")
  86. # oldUserTweetsVariables* = """{
  87. # "userId": "$1", $2
  88. # "count": 20,
  89. # "includePromotedContent": false,
  90. # "withDownvotePerspective": false,
  91. # "withReactionsMetadata": false,
  92. # "withReactionsPerspective": false,
  93. # "withVoice": false,
  94. # "withV2Timeline": true
  95. # }
  96. # """
  97. userTweetsVariables* = """{
  98. "rest_id": "$1", $2
  99. "count": 20
  100. }"""
  101. listTweetsVariables* = """{
  102. "rest_id": "$1", $2
  103. "count": 20
  104. }"""