ModNoteMixin¶
- class praw.models.reddit.mixins.ModNoteMixin¶
Interface for classes that can have a moderator note set on them.
- author_notes(**generator_kwargs)¶
Get the moderator notes for the author of this object in the subreddit it’s posted in.
- Parameters:
generator_kwargs (
Any) – Additional keyword arguments are passed in the initialization of the moderator note generator.- Return type:
- Returns:
A generator of
ModNote.
For example, to list all notes the author of a submission, try:
for note in reddit.submission("92dd8").mod.author_notes(): print(f"{note.label}: {note.note}")
- create_note(*, label=None, note, **other_settings)¶
Create a moderator note on the author of this object in the subreddit it’s posted in.
- Parameters:
label (
str|None) – The label for the note. As of this writing, this can be one of the following:"ABUSE_WARNING","BAN","BOT_BAN","HELPFUL_USER","PERMA_BAN","SOLID_CONTRIBUTOR","SPAM_WARNING","SPAM_WATCH", orNone(default:None).note (
str) – The content of the note. As of this writing, this is limited to 250 characters.other_settings (
Any) – Additional keyword arguments are passed tocreate().
- Return type:
- Returns:
The new
ModNoteobject.
For example, to create a note on a
Submission, try:reddit.submission("92dd8").mod.create_note(label="HELPFUL_USER", note="Test note")