Class: FullSubmission
#
Hierarchy_Submission<typeof default, this> & default<this>
↳ FullSubmission
#
Implements#
Properties#
approved• approved: null
| default
Inherited from: _Submission(FullPost).approved
Defined in: objects/post/full.ts:40
#
archived• archived: boolean
Inherited from: _Submission(FullPost).archived
Defined in: objects/post/full.ts:34
#
author• author: null
| SubmissionUser
The user who posted this or null if he's 'u/[deleted]'
Inherited from: _Submission(FullPost).author
Defined in: objects/post/full.ts:12
#
awardCount• awardCount: number
Inherited from: _Submission(FullPost).awardCount
Defined in: objects/post/full.ts:30
#
awards• awards: GivenAward[]
Inherited from: _Submission(FullPost).awards
Defined in: objects/post/full.ts:31
#
body• body: null
| Content
Defined in: objects/post/submission/full.ts:59
#
collections• collections: Collection[]
The collections this submission is a part of
Defined in: objects/post/submission/full.ts:52
#
commentCount• commentCount: number
Defined in: objects/post/submission/full.ts:34
#
created• created: Date
The date this thing was created.
Inherited from: _Submission(FullPost).created
Defined in: objects/post/full.ts:17
#
crosspost• crosspost: null
| FullSubmission
The crosspost this submission contains
Defined in: objects/post/submission/full.ts:40
#
crosspostCount• crosspostCount: number
How often this submission has been crossposted to other subreddits
see
crossposts to fetch them
Defined in: objects/post/submission/full.ts:46
#
crosspostable• crosspostable: boolean
Whether the subreddit allows this submission to be crossposted
Defined in: objects/post/submission/full.ts:49
#
deleted• deleted: boolean
Inherited from: _Submission(FullPost).deleted
Defined in: objects/post/full.ts:39
#
distinguished• distinguished: DistinguishKinds
Inherited from: _Submission(FullPost).distinguished
Defined in: objects/post/full.ts:37
#
edited• edited: null
| Date
The date the body was edited or null
if it wasn't.
Inherited from: _Submission(FullPost).edited
Defined in: objects/post/full.ts:19
#
embed• embed: null
| Embed
Defined in: objects/post/submission/full.ts:67
#
event• event: null
| default
Defined in: objects/post/submission/full.ts:54
#
flair• flair: null
| Flair
Defined in: objects/post/submission/full.ts:30
#
fullId• fullId: string
Implementation of: Submission.fullId
Inherited from: _Submission(FullPost).fullId
Defined in: objects/post/small.ts:15
#
hidden• hidden: boolean
Defined in: objects/post/submission/full.ts:36
#
id• id: string
Implementation of: Submission.id
Inherited from: _Submission(FullPost).id
Defined in: objects/post/small.ts:14
#
imagesDefined in: objects/post/submission/full.ts:62
#
link• link: null
| string
Defined in: objects/post/submission/full.ts:56
#
locked• locked: boolean
Inherited from: _Submission(FullPost).locked
Defined in: objects/post/full.ts:35
#
nsfw• nsfw: boolean
Defined in: objects/post/submission/full.ts:28
#
oc• oc: boolean
Defined in: objects/post/submission/full.ts:26
#
poll• poll: null
| Poll
Defined in: objects/post/submission/full.ts:66
#
promoted• promoted: null
| default
Defined in: objects/post/submission/full.ts:68
#
quarantine• quarantine: boolean
Defined in: objects/post/submission/full.ts:37
#
r• r: Reddit
Implementation of: Submission.r
Inherited from: _Submission(FullPost).r
Defined in: objects/post/small.ts:12
#
rawLink• rawLink: string
Defined in: objects/post/submission/full.ts:57
#
removed• removed: null
| default
Inherited from: _Submission(FullPost).removed
Defined in: objects/post/full.ts:41
#
robotIndexable• robotIndexable: boolean
Defined in: objects/post/submission/full.ts:32
#
rpan• rpan: null
| Stream
Defined in: objects/post/submission/full.ts:64
#
saved• saved: boolean
Inherited from: _Submission(FullPost).saved
Defined in: objects/post/full.ts:33
#
score• score: null
| number
The fuzzed score it has or null
if it's hidden.
Inherited from: _Submission(FullPost).score
Defined in: objects/post/full.ts:24
#
scoreHidden• scoreHidden: boolean
Whether the score is hidden.
Inherited from: _Submission(FullPost).scoreHidden
Defined in: objects/post/full.ts:26
#
spoiler• spoiler: boolean
Defined in: objects/post/submission/full.ts:27
#
sticky• sticky: boolean
Inherited from: _Submission(FullPost).sticky
Defined in: objects/post/full.ts:36
#
subreddit• subreddit: User | Subreddit
The subreddit it was posted on or a user if it was posted directly on it's profile
Inherited from: _Submission(FullPost).subreddit
Defined in: objects/post/full.ts:14
#
thumbnail• thumbnail: null
| Image
Defined in: objects/post/submission/full.ts:60
#
title• title: string
The title of the submission.
Defined in: objects/post/submission/full.ts:22
#
upvoteRatio• upvoteRatio: number
Defined in: objects/post/submission/full.ts:24
#
url• url: string
Inherited from: _Submission(FullPost).url
Defined in: objects/post/full.ts:21
#
video• video: null
| Video
Defined in: objects/post/submission/full.ts:63
#
voted• voted: VoteDirection
The vote the user casted on this. Use vote to change it.
Inherited from: _Submission(FullPost).voted
Defined in: objects/post/full.ts:28
#
Accessors#
key• get key(): string
Returns: string
Defined in: objects/post/small.ts:17
#
shortUrl• get shortUrl(): string
Returns: string
Defined in: objects/post/submission/small.ts:10
#
Methods#
approveâ–¸ approve(): Promise<void>
Returns: Promise<void>
Implementation of: Submission.approve
Inherited from: _Submission(FullPost).approve
Defined in: objects/post/small.ts:103
#
awardâ–¸ award(award
: Award, anonymous
: boolean): Promise<void>
#
ParametersName | Type |
---|---|
award | Award |
anonymous | boolean |
Returns: Promise<void>
Implementation of: Submission.award
Inherited from: _Submission(FullPost).award
Defined in: objects/post/small.ts:53
#
commentâ–¸ comment(body
: string): Promise<void>
#
ParametersName | Type |
---|---|
body | string |
Returns: Promise<void>
Implementation of: Submission.comment
Inherited from: _Submission(FullPost).comment
Defined in: objects/post/small.ts:108
#
commentsâ–¸ comments(): Promise<CommentTree<Submission | FullComment>>
Returns: Promise<CommentTree<Submission | FullComment>>
Implementation of: Submission.comments
Inherited from: _Submission(FullPost).comments
Defined in: objects/post/submission/small.ts:22
#
crosspostsâ–¸ crossposts(options?
: CrosspostsOptions): Promise<Page<FullSubmission, any>>
Returns all crossposts of this submission
see
crosspostsStream
#
ParametersName | Type |
---|---|
options? | CrosspostsOptions |
Returns: Promise<Page<FullSubmission, any>>
Defined in: objects/post/submission/full.ts:267
#
crosspostsStreamâ–¸ crosspostsStream(options?
: CrosspostsStreamOptions): AsyncIterator<FullSubmission, any, undefined>
#
ParametersName | Type |
---|---|
options? | CrosspostsStreamOptions |
Returns: AsyncIterator<FullSubmission, any, undefined>
Defined in: objects/post/submission/full.ts:271
#
deleteâ–¸ delete(): Promise<void>
Delete this thing
Returns: Promise<void>
Implementation of: Submission.delete
Inherited from: _Submission(FullPost).delete
Defined in: objects/post/small.ts:30
#
distinguishâ–¸ distinguish(kind?
: DistinguishKinds): Promise<void>
#
ParametersName | Type | Default value |
---|---|---|
kind | DistinguishKinds | "mod" |
Returns: Promise<void>
Implementation of: Submission.distinguish
Inherited from: _Submission(FullPost).distinguish
Defined in: objects/post/small.ts:95
#
duplicatesâ–¸ duplicates(options?
: DuplicatesOptions): Promise<Page<FullSubmission, any>>
Returns all duplicates of this submission
see
duplicatesStream
#
ParametersName | Type |
---|---|
options? | DuplicatesOptions |
Returns: Promise<Page<FullSubmission, any>>
Defined in: objects/post/submission/full.ts:281
#
duplicatesStreamâ–¸ duplicatesStream(options?
: DuplicatesStreamOptions): AsyncIterator<FullSubmission, any, undefined>
#
ParametersName | Type |
---|---|
options? | DuplicatesStreamOptions |
Returns: AsyncIterator<FullSubmission, any, undefined>
Defined in: objects/post/submission/full.ts:298
#
editâ–¸ edit(body
: string): Promise<void>
Edit the body of a submission or comment
#
ParametersName | Type | Description |
---|---|---|
body | string | The new body in markdown |
Returns: Promise<void>
Implementation of: Submission.edit
Inherited from: _Submission(FullPost).edit
Defined in: objects/post/small.ts:66
#
fetchâ–¸ fetch(): Promise<FullSubmission>
Returns: Promise<FullSubmission>
Implementation of: Submission.fetch
Inherited from: _Submission(FullPost).fetch
Defined in: objects/post/submission/small.ts:14
#
followâ–¸ follow(follow?
: boolean): Promise<void>
#
ParametersName | Type | Default value |
---|---|---|
follow | boolean | true |
Returns: Promise<void>
Implementation of: Submission.follow
Inherited from: _Submission(FullPost).follow
Defined in: objects/post/submission/small.ts:30
#
hideâ–¸ hide(save?
: boolean): Promise<void>
#
ParametersName | Type | Default value |
---|---|---|
save | boolean | true |
Returns: Promise<void>
Implementation of: Submission.hide
Inherited from: _Submission(FullPost).hide
Defined in: objects/post/small.ts:81
#
lockâ–¸ lock(lock?
: boolean): Promise<void>
#
ParametersName | Type | Default value |
---|---|---|
lock | boolean | true |
Returns: Promise<void>
Implementation of: Submission.lock
Inherited from: _Submission(FullPost).lock
Defined in: objects/post/small.ts:88
#
markNsfwâ–¸ markNsfw(nsfw?
: boolean): Promise<void>
#
ParametersName | Type | Default value |
---|---|---|
nsfw | boolean | true |
Returns: Promise<void>
Implementation of: Submission.markNsfw
Inherited from: _Submission(FullPost).markNsfw
Defined in: objects/post/submission/small.ts:46
#
markOcâ–¸ markOc(oc?
: boolean): Promise<void>
#
ParametersName | Type | Default value |
---|---|---|
oc | boolean | true |
Returns: Promise<void>
Implementation of: Submission.markOc
Inherited from: _Submission(FullPost).markOc
Defined in: objects/post/submission/small.ts:38
#
markSpoilerâ–¸ markSpoiler(spoiler?
: boolean): Promise<void>
#
ParametersName | Type | Default value |
---|---|---|
spoiler | boolean | true |
Returns: Promise<void>
Implementation of: Submission.markSpoiler
Inherited from: _Submission(FullPost).markSpoiler
Defined in: objects/post/submission/small.ts:53
#
markVisitedâ–¸ markVisited(): Promise<void>
Returns: Promise<void>
Implementation of: Submission.markVisited
Inherited from: _Submission(FullPost).markVisited
Defined in: objects/post/submission/small.ts:60
#
saveâ–¸ save(save?
: boolean): Promise<void>
#
ParametersName | Type | Default value |
---|---|---|
save | boolean | true |
Returns: Promise<void>
Implementation of: Submission.save
Inherited from: _Submission(FullPost).save
Defined in: objects/post/small.ts:74
#
voteâ–¸ vote(dir
: VoteDirection): Promise<void>
Casting a vote on a submission or comment
Note: votes must be cast by humans. That is, API clients proxying a human's action one-for-one are OK, but bots deciding how to vote on content or amplifying a human's vote are not. See the reddit rules for more details on what constitutes vote cheating.
#
ParametersName | Type | Description |
---|---|---|
dir | VoteDirection | The direction of the vote 1 = upvote \ 0 = unvote \ -1 = downvote |
Returns: Promise<void>
Implementation of: Submission.vote
Inherited from: _Submission(FullPost).vote
Defined in: objects/post/small.ts:48