-3

I'm attempting to find the user of Reddit so I can iterate through their last comments, weird reason but I'm in need of getting the user's object.

Cannot find in the docs where there's a way to get a user via username.

H. Joseph
  • 65
  • 9

1 Answers1

2
import praw 

reddit = praw.Reddit(client_id='xxxxxxxxx',
                     client_secret='xxxxxxxx', 
                     password='xxxxxxxxx',
                     user_agent='xxxxxxx',
                     username='xxxxxxxx')

user = reddit.redditor('username')

https://praw.readthedocs.io/en/latest/code_overview/models/redditor.html

Harshith Bolar
  • 728
  • 1
  • 10
  • 29