description:'Title of the post, up to 300 characters long.',
displayOptions:{
show:{
resource:[
'post',
],
operation:[
'create',
],
},
},
},
{
displayName:'URL',
name:'url',
type:'string',
required: true,
default:'',
description:'URL of the post.',
displayOptions:{
show:{
resource:[
'post',
],
operation:[
'create',
],
kind:[
'link',
'image',
],
},
},
},
{
displayName:'Text',
name:'text',
type:'string',
required: true,
default:'',
description:'Text of the post. Markdown supported.',
displayOptions:{
show:{
resource:[
'post',
],
operation:[
'create',
],
kind:[
'self',
],
},
},
},
{
displayName:'Resubmit',
name:'resubmit',
type:'boolean',
default:false,
description:'If toggled on, the URL will be posted even if<br>it was already posted to the subreddit before.<br>Otherwise, the re-posting will trigger an error.',
displayOptions:{
show:{
resource:[
'post',
],
operation:[
'create',
],
kind:[
'link',
'image',
],
},
},
},
// ----------------------------------
// post: delete
// ----------------------------------
{
displayName:'Post ID',
name:'postId',
type:'string',
required: true,
default:'',
description:'ID of the post to delete. Found in the post URL:<br><code>/r/[subreddit_name]/comments/[post_id]/[post_title]</code>',
placeholder:'gla7fmt',
displayOptions:{
show:{
resource:[
'post',
],
operation:[
'delete',
],
},
},
},
// ----------------------------------
// post: get
// ----------------------------------
{
displayName:'Subreddit',
name:'subreddit',
type:'string',
required: true,
default:'',
description:'The name of subreddit to retrieve the post from.',
displayOptions:{
show:{
resource:[
'post',
],
operation:[
'get',
],
},
},
},
{
displayName:'Post ID',
name:'postId',
type:'string',
required: true,
default:'',
description:'ID of the post to retrieve. Found in the post URL:<br><code>/r/[subreddit_name]/comments/[post_id]/[post_title]</code>',
placeholder:'l0me7x',
displayOptions:{
show:{
resource:[
'post',
],
operation:[
'get',
],
},
},
},
// ----------------------------------
// post: getAll
// ----------------------------------
{
displayName:'Subreddit',
name:'subreddit',
type:'string',
required: true,
default:'',
description:'The name of subreddit to retrieve the posts from.',