Reddit Comments Scraper avatar

Reddit Comments Scraper

Try for free

Pay $5.00 for 1,000 comments

View all Actors
Reddit Comments Scraper

Reddit Comments Scraper

mysteriousshadow/reddit-comments-scraper
Try for free

Pay $5.00 for 1,000 comments

Scrape comments for a post. Users can specify which comment layers to retrieve (e.g., 0 for top-level comments).

Given a reddit post, this scraper gathers the comments.

You can specify what layers of "depth" to scrape, with [0] being only getting top level comments, and [0,1] only getting top level comments and their direct replies, etc.

The scraper returns the comments in two formats:

Flat: Just a list of all the comments

Nested: The comment structure reflects the actual comment structure (comment/reply) in the post

Please contact me or create an issue if the Actor isn't outputting anything.

Example output:

1[{
2  "flat_comments": [
3    {
4      "content": "Your submission was removed for the following reason:\nRule 2: Content that is part of top of all time, reached trending in the past 2 months, or has recently been posted, is considered a repost and will be removed.\nIf you disagree with this removal, you can appeal by sending us a modmail.",
5      "commentid": "t1_lyg8d4m",
6      "depth": "0",
7      "author": "ProgrammerHumor-ModTeam",
8      "score": "1",
9      "parentid": null
10    },
11    {
12      "content": "As a compsci student procrastinating a c# assignment im now conflected",
13      "commentid": "t1_lye6tmc",
14      "depth": "0",
15      "author": "CrossFire011",
16      "score": "398",
17      "parentid": null
18    },
19    {
20      "content": "C# is the dream. So much good tooling, the BEST ide(imo) and .net core is a joy to work with.",
21      "commentid": "t1_lye9y5v",
22      "depth": "1",
23      "author": "RoutineWolverine1745",
24      "score": "353",
25      "parentid": "t1_lye6tmc"
26    },
27    {
28      "content": "The dotnet cli and omnisharp are great tools (haven't tried roslyn), but unfortunately rzls (the language server for blazor) doesn't work outside of Visual Studio or VSCode. That's the only thing lacking for me to say it has great tooling overall.",
29      "commentid": "t1_lyebnvn",
30      "depth": "2",
31      "author": "DestopLine555",
32      "score": "70",
33      "parentid": "t1_lye9y5v"
34    },
35    {
36      "content": "Doesn't work in VS Code either.",
37      "commentid": "t1_lyenm41",
38      "depth": "3",
39      "author": "sharkydad",
40      "score": "31",
41      "parentid": "t1_lyebnvn"
42    },
43    {
44      "content": "Which IDE are you talking about?",
45      "commentid": "t1_lyebynz",
46      "depth": "2",
47      "author": "Fadamaka",
48      "score": "27",
49      "parentid": "t1_lye9y5v"
50    },
51    {
52      "content": "Notepad++",
53      "commentid": "t1_lyeec48",
54      "depth": "3",
55      "author": "cosmic_cosmosis",
56      "score": "126",
57      "parentid": "t1_lyebynz"
58    },
59    {
60      "content": "Visual Studio id guess.",
61      "commentid": "t1_lyeek4p",
62      "depth": "3",
63      "author": "ToastedHedgehog",
64      "score": "30",
65      "parentid": "t1_lyebynz"
66    },
67    {
68      "content": "I think Rider is slept on, way better than VS",
69      "commentid": "t1_lyf2y4s",
70      "depth": "3",
71      "author": "Singularity42",
72      "score": "3",
73      "parentid": "t1_lyebynz"
74    },
75    {
76      "content": "Visual Studio ain't bad. Yeah it's slow and sometimes buggy but it's crazy intuitive and easy to use",
77      "commentid": "t1_lyejlf9",
78      "depth": "3",
79      "author": "OhItsJustJosh",
80      "score": "8",
81      "parentid": "t1_lyebynz"
82    }
83  ],
84  "nested_comments": [
85    {
86      "content": "Your submission was removed for the following reason:\nRule 2: Content that is part of top of all time, reached trending in the past 2 months, or has recently been posted, is considered a repost and will be removed.\nIf you disagree with this removal, you can appeal by sending us a modmail.",
87      "commentid": "t1_lyg8d4m",
88      "depth": "0",
89      "author": "ProgrammerHumor-ModTeam",
90      "score": "1",
91      "parentid": null,
92      "replies": []
93    },
94    {
95      "content": "As a compsci student procrastinating a c# assignment im now conflected",
96      "commentid": "t1_lye6tmc",
97      "depth": "0",
98      "author": "CrossFire011",
99      "score": "398",
100      "parentid": null,
101      "replies": [
102        {
103          "content": "C# is the dream. So much good tooling, the BEST ide(imo) and .net core is a joy to work with.",
104          "commentid": "t1_lye9y5v",
105          "depth": "1",
106          "author": "RoutineWolverine1745",
107          "score": "353",
108          "parentid": "t1_lye6tmc",
109          "replies": [
110            {
111              "content": "The dotnet cli and omnisharp are great tools (haven't tried roslyn), but unfortunately rzls (the language server for blazor) doesn't work outside of Visual Studio or VSCode. That's the only thing lacking for me to say it has great tooling overall.",
112              "commentid": "t1_lyebnvn",
113              "depth": "2",
114              "author": "DestopLine555",
115              "score": "70",
116              "parentid": "t1_lye9y5v",
117              "replies": [
118                {
119                  "content": "Doesn't work in VS Code either.",
120                  "commentid": "t1_lyenm41",
121                  "depth": "3",
122                  "author": "sharkydad",
123                  "score": "31",
124                  "parentid": "t1_lyebnvn",
125                  "replies": []
126                }
127              ]
128            },
129            {
130              "content": "Which IDE are you talking about?",
131              "commentid": "t1_lyebynz",
132              "depth": "2",
133              "author": "Fadamaka",
134              "score": "27",
135              "parentid": "t1_lye9y5v",
136              "replies": [
137                {
138                  "content": "Notepad++",
139                  "commentid": "t1_lyeec48",
140                  "depth": "3",
141                  "author": "cosmic_cosmosis",
142                  "score": "126",
143                  "parentid": "t1_lyebynz",
144                  "replies": []
145                },
146                {
147                  "content": "Visual Studio id guess.",
148                  "commentid": "t1_lyeek4p",
149                  "depth": "3",
150                  "author": "ToastedHedgehog",
151                  "score": "30",
152                  "parentid": "t1_lyebynz",
153                  "replies": []
154                },
155                {
156                  "content": "I think Rider is slept on, way better than VS",
157                  "commentid": "t1_lyf2y4s",
158                  "depth": "3",
159                  "author": "Singularity42",
160                  "score": "3",
161                  "parentid": "t1_lyebynz",
162                  "replies": []
163                },
164                {
165                  "content": "Visual Studio ain't bad. Yeah it's slow and sometimes buggy but it's crazy intuitive and easy to use",
166                  "commentid": "t1_lyejlf9",
167                  "depth": "3",
168                  "author": "OhItsJustJosh",
169                  "score": "8",
170                  "parentid": "t1_lyebynz",
171                  "replies": []
172                }
173              ]
174            }
175          ]
176        }
177      ]
178    }
179  ]
180}]
Developer
Maintained by Community

Actor Metrics

  • 1 monthly user

  • 0 No stars yet

  • Created in Nov 2024

  • Modified 13 hours ago

Categories