mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 18:12:04 +00:00
⚡ Add retweet, reply and like operations (#964)
This commit is contained in:
@@ -18,13 +18,23 @@ export const tweetOperations = [
|
||||
{
|
||||
name: 'Create',
|
||||
value: 'create',
|
||||
description: 'Create a new tweet',
|
||||
description: 'Create or reply a tweet',
|
||||
},
|
||||
{
|
||||
name: 'Search',
|
||||
value: 'search',
|
||||
description: 'Search tweets',
|
||||
},
|
||||
{
|
||||
name: 'Like',
|
||||
value: 'like',
|
||||
description: 'Like a tweet',
|
||||
},
|
||||
{
|
||||
name: 'Retweet',
|
||||
value: 'retweet',
|
||||
description: 'Retweet a tweet',
|
||||
},
|
||||
],
|
||||
default: 'create',
|
||||
description: 'The operation to perform.',
|
||||
@@ -87,6 +97,13 @@ export const tweetFields = [
|
||||
default: false,
|
||||
description: 'Whether or not to put a pin on the exact coordinates a Tweet has been sent from.',
|
||||
},
|
||||
{
|
||||
displayName: 'In Reply to Tweet',
|
||||
name: 'inReplyToStatusId',
|
||||
type: 'string',
|
||||
default: '',
|
||||
description: 'The ID of an existing status that the update is in reply to.',
|
||||
},
|
||||
{
|
||||
displayName: 'Location',
|
||||
name: 'locationFieldsUi',
|
||||
@@ -321,4 +338,98 @@ export const tweetFields = [
|
||||
},
|
||||
],
|
||||
},
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* tweet:like */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
{
|
||||
displayName: 'Tweet ID',
|
||||
name: 'tweetId',
|
||||
type: 'string',
|
||||
required: true,
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'like',
|
||||
],
|
||||
resource: [
|
||||
'tweet',
|
||||
],
|
||||
},
|
||||
},
|
||||
description: 'The ID of the tweet',
|
||||
},
|
||||
{
|
||||
displayName: 'Additional Fields',
|
||||
name: 'additionalFields',
|
||||
type: 'collection',
|
||||
placeholder: 'Add Field',
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'like',
|
||||
],
|
||||
resource: [
|
||||
'tweet',
|
||||
],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
{
|
||||
displayName: 'include Entities',
|
||||
name: 'includeEntities',
|
||||
type: 'boolean',
|
||||
default: false,
|
||||
description: 'The entities node will be omitted when set to false',
|
||||
},
|
||||
],
|
||||
},
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* tweet:retweet */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
{
|
||||
displayName: 'Tweet ID',
|
||||
name: 'tweetId',
|
||||
type: 'string',
|
||||
required: true,
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'retweet',
|
||||
],
|
||||
resource: [
|
||||
'tweet',
|
||||
],
|
||||
},
|
||||
},
|
||||
description: 'The ID of the tweet',
|
||||
},
|
||||
{
|
||||
displayName: 'Additional Fields',
|
||||
name: 'additionalFields',
|
||||
type: 'collection',
|
||||
placeholder: 'Add Field',
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'retweet',
|
||||
],
|
||||
resource: [
|
||||
'tweet',
|
||||
],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
{
|
||||
displayName: 'Trim User',
|
||||
name: 'trimUser',
|
||||
type: 'boolean',
|
||||
default: false,
|
||||
description: `When set to either true, each tweet returned in a timeline will include a user object including only the status authors numerical ID.`,
|
||||
},
|
||||
],
|
||||
},
|
||||
] as INodeProperties[];
|
||||
|
||||
Reference in New Issue
Block a user