@memberjunction/actions-bizapps-social 2.61.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.turbo/turbo-build.log +4 -0
- package/CHANGELOG.md +16 -0
- package/README.md +375 -0
- package/dist/base/base-social.action.d.ts +137 -0
- package/dist/base/base-social.action.d.ts.map +1 -0
- package/dist/base/base-social.action.js +176 -0
- package/dist/base/base-social.action.js.map +1 -0
- package/dist/index.d.ts +10 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +35 -0
- package/dist/index.js.map +1 -0
- package/dist/providers/buffer/actions/create-post.action.d.ts +20 -0
- package/dist/providers/buffer/actions/create-post.action.d.ts.map +1 -0
- package/dist/providers/buffer/actions/create-post.action.js +195 -0
- package/dist/providers/buffer/actions/create-post.action.js.map +1 -0
- package/dist/providers/buffer/actions/delete-post.action.d.ts +20 -0
- package/dist/providers/buffer/actions/delete-post.action.d.ts.map +1 -0
- package/dist/providers/buffer/actions/delete-post.action.js +119 -0
- package/dist/providers/buffer/actions/delete-post.action.js.map +1 -0
- package/dist/providers/buffer/actions/get-analytics.action.d.ts +28 -0
- package/dist/providers/buffer/actions/get-analytics.action.d.ts.map +1 -0
- package/dist/providers/buffer/actions/get-analytics.action.js +143 -0
- package/dist/providers/buffer/actions/get-analytics.action.js.map +1 -0
- package/dist/providers/buffer/actions/get-pending-posts.action.d.ts +24 -0
- package/dist/providers/buffer/actions/get-pending-posts.action.d.ts.map +1 -0
- package/dist/providers/buffer/actions/get-pending-posts.action.js +161 -0
- package/dist/providers/buffer/actions/get-pending-posts.action.js.map +1 -0
- package/dist/providers/buffer/actions/get-profiles.action.d.ts +24 -0
- package/dist/providers/buffer/actions/get-profiles.action.d.ts.map +1 -0
- package/dist/providers/buffer/actions/get-profiles.action.js +128 -0
- package/dist/providers/buffer/actions/get-profiles.action.js.map +1 -0
- package/dist/providers/buffer/actions/get-sent-posts.action.d.ts +32 -0
- package/dist/providers/buffer/actions/get-sent-posts.action.d.ts.map +1 -0
- package/dist/providers/buffer/actions/get-sent-posts.action.js +187 -0
- package/dist/providers/buffer/actions/get-sent-posts.action.js.map +1 -0
- package/dist/providers/buffer/actions/index.d.ts +9 -0
- package/dist/providers/buffer/actions/index.d.ts.map +1 -0
- package/dist/providers/buffer/actions/index.js +25 -0
- package/dist/providers/buffer/actions/index.js.map +1 -0
- package/dist/providers/buffer/actions/reorder-queue.action.d.ts +20 -0
- package/dist/providers/buffer/actions/reorder-queue.action.d.ts.map +1 -0
- package/dist/providers/buffer/actions/reorder-queue.action.js +138 -0
- package/dist/providers/buffer/actions/reorder-queue.action.js.map +1 -0
- package/dist/providers/buffer/actions/search-posts.action.d.ts +28 -0
- package/dist/providers/buffer/actions/search-posts.action.d.ts.map +1 -0
- package/dist/providers/buffer/actions/search-posts.action.js +249 -0
- package/dist/providers/buffer/actions/search-posts.action.js.map +1 -0
- package/dist/providers/buffer/buffer-base.action.d.ts +95 -0
- package/dist/providers/buffer/buffer-base.action.d.ts.map +1 -0
- package/dist/providers/buffer/buffer-base.action.js +419 -0
- package/dist/providers/buffer/buffer-base.action.js.map +1 -0
- package/dist/providers/buffer/index.d.ts +3 -0
- package/dist/providers/buffer/index.d.ts.map +1 -0
- package/dist/providers/buffer/index.js +19 -0
- package/dist/providers/buffer/index.js.map +1 -0
- package/dist/providers/facebook/actions/boost-post.action.d.ts +45 -0
- package/dist/providers/facebook/actions/boost-post.action.d.ts.map +1 -0
- package/dist/providers/facebook/actions/boost-post.action.js +340 -0
- package/dist/providers/facebook/actions/boost-post.action.js.map +1 -0
- package/dist/providers/facebook/actions/create-album.action.d.ts +33 -0
- package/dist/providers/facebook/actions/create-album.action.d.ts.map +1 -0
- package/dist/providers/facebook/actions/create-album.action.js +285 -0
- package/dist/providers/facebook/actions/create-album.action.js.map +1 -0
- package/dist/providers/facebook/actions/create-post.action.d.ts +21 -0
- package/dist/providers/facebook/actions/create-post.action.d.ts.map +1 -0
- package/dist/providers/facebook/actions/create-post.action.js +223 -0
- package/dist/providers/facebook/actions/create-post.action.js.map +1 -0
- package/dist/providers/facebook/actions/get-page-insights.action.d.ts +37 -0
- package/dist/providers/facebook/actions/get-page-insights.action.d.ts.map +1 -0
- package/dist/providers/facebook/actions/get-page-insights.action.js +359 -0
- package/dist/providers/facebook/actions/get-page-insights.action.js.map +1 -0
- package/dist/providers/facebook/actions/get-page-posts.action.d.ts +29 -0
- package/dist/providers/facebook/actions/get-page-posts.action.d.ts.map +1 -0
- package/dist/providers/facebook/actions/get-page-posts.action.js +216 -0
- package/dist/providers/facebook/actions/get-page-posts.action.js.map +1 -0
- package/dist/providers/facebook/actions/get-post-insights.action.d.ts +33 -0
- package/dist/providers/facebook/actions/get-post-insights.action.d.ts.map +1 -0
- package/dist/providers/facebook/actions/get-post-insights.action.js +287 -0
- package/dist/providers/facebook/actions/get-post-insights.action.js.map +1 -0
- package/dist/providers/facebook/actions/index.d.ts +10 -0
- package/dist/providers/facebook/actions/index.d.ts.map +1 -0
- package/dist/providers/facebook/actions/index.js +26 -0
- package/dist/providers/facebook/actions/index.js.map +1 -0
- package/dist/providers/facebook/actions/respond-to-comments.action.d.ts +41 -0
- package/dist/providers/facebook/actions/respond-to-comments.action.d.ts.map +1 -0
- package/dist/providers/facebook/actions/respond-to-comments.action.js +328 -0
- package/dist/providers/facebook/actions/respond-to-comments.action.js.map +1 -0
- package/dist/providers/facebook/actions/schedule-post.action.d.ts +29 -0
- package/dist/providers/facebook/actions/schedule-post.action.d.ts.map +1 -0
- package/dist/providers/facebook/actions/schedule-post.action.js +289 -0
- package/dist/providers/facebook/actions/schedule-post.action.js.map +1 -0
- package/dist/providers/facebook/actions/search-posts.action.d.ts +54 -0
- package/dist/providers/facebook/actions/search-posts.action.d.ts.map +1 -0
- package/dist/providers/facebook/actions/search-posts.action.js +396 -0
- package/dist/providers/facebook/actions/search-posts.action.js.map +1 -0
- package/dist/providers/facebook/facebook-base.action.d.ts +230 -0
- package/dist/providers/facebook/facebook-base.action.d.ts.map +1 -0
- package/dist/providers/facebook/facebook-base.action.js +566 -0
- package/dist/providers/facebook/facebook-base.action.js.map +1 -0
- package/dist/providers/facebook/index.d.ts +3 -0
- package/dist/providers/facebook/index.d.ts.map +1 -0
- package/dist/providers/facebook/index.js +19 -0
- package/dist/providers/facebook/index.js.map +1 -0
- package/dist/providers/hootsuite/actions/bulk-schedule-posts.action.d.ts +24 -0
- package/dist/providers/hootsuite/actions/bulk-schedule-posts.action.d.ts.map +1 -0
- package/dist/providers/hootsuite/actions/bulk-schedule-posts.action.js +266 -0
- package/dist/providers/hootsuite/actions/bulk-schedule-posts.action.js.map +1 -0
- package/dist/providers/hootsuite/actions/create-scheduled-post.action.d.ts +25 -0
- package/dist/providers/hootsuite/actions/create-scheduled-post.action.d.ts.map +1 -0
- package/dist/providers/hootsuite/actions/create-scheduled-post.action.js +202 -0
- package/dist/providers/hootsuite/actions/create-scheduled-post.action.js.map +1 -0
- package/dist/providers/hootsuite/actions/delete-scheduled-post.action.d.ts +20 -0
- package/dist/providers/hootsuite/actions/delete-scheduled-post.action.d.ts.map +1 -0
- package/dist/providers/hootsuite/actions/delete-scheduled-post.action.js +172 -0
- package/dist/providers/hootsuite/actions/delete-scheduled-post.action.js.map +1 -0
- package/dist/providers/hootsuite/actions/get-analytics.action.d.ts +52 -0
- package/dist/providers/hootsuite/actions/get-analytics.action.d.ts.map +1 -0
- package/dist/providers/hootsuite/actions/get-analytics.action.js +265 -0
- package/dist/providers/hootsuite/actions/get-analytics.action.js.map +1 -0
- package/dist/providers/hootsuite/actions/get-scheduled-posts.action.d.ts +37 -0
- package/dist/providers/hootsuite/actions/get-scheduled-posts.action.d.ts.map +1 -0
- package/dist/providers/hootsuite/actions/get-scheduled-posts.action.js +208 -0
- package/dist/providers/hootsuite/actions/get-scheduled-posts.action.js.map +1 -0
- package/dist/providers/hootsuite/actions/get-social-profiles.action.d.ts +36 -0
- package/dist/providers/hootsuite/actions/get-social-profiles.action.d.ts.map +1 -0
- package/dist/providers/hootsuite/actions/get-social-profiles.action.js +212 -0
- package/dist/providers/hootsuite/actions/get-social-profiles.action.js.map +1 -0
- package/dist/providers/hootsuite/actions/search-posts.action.d.ts +53 -0
- package/dist/providers/hootsuite/actions/search-posts.action.d.ts.map +1 -0
- package/dist/providers/hootsuite/actions/search-posts.action.js +353 -0
- package/dist/providers/hootsuite/actions/search-posts.action.js.map +1 -0
- package/dist/providers/hootsuite/actions/update-scheduled-post.action.d.ts +20 -0
- package/dist/providers/hootsuite/actions/update-scheduled-post.action.d.ts.map +1 -0
- package/dist/providers/hootsuite/actions/update-scheduled-post.action.js +217 -0
- package/dist/providers/hootsuite/actions/update-scheduled-post.action.js.map +1 -0
- package/dist/providers/hootsuite/hootsuite-base.action.d.ts +101 -0
- package/dist/providers/hootsuite/hootsuite-base.action.d.ts.map +1 -0
- package/dist/providers/hootsuite/hootsuite-base.action.js +274 -0
- package/dist/providers/hootsuite/hootsuite-base.action.js.map +1 -0
- package/dist/providers/hootsuite/index.d.ts +10 -0
- package/dist/providers/hootsuite/index.d.ts.map +1 -0
- package/dist/providers/hootsuite/index.js +28 -0
- package/dist/providers/hootsuite/index.js.map +1 -0
- package/dist/providers/instagram/actions/create-post.action.d.ts +30 -0
- package/dist/providers/instagram/actions/create-post.action.d.ts.map +1 -0
- package/dist/providers/instagram/actions/create-post.action.js +269 -0
- package/dist/providers/instagram/actions/create-post.action.js.map +1 -0
- package/dist/providers/instagram/actions/create-story.action.d.ts +43 -0
- package/dist/providers/instagram/actions/create-story.action.d.ts.map +1 -0
- package/dist/providers/instagram/actions/create-story.action.js +365 -0
- package/dist/providers/instagram/actions/create-story.action.js.map +1 -0
- package/dist/providers/instagram/actions/get-account-insights.action.d.ts +50 -0
- package/dist/providers/instagram/actions/get-account-insights.action.d.ts.map +1 -0
- package/dist/providers/instagram/actions/get-account-insights.action.js +390 -0
- package/dist/providers/instagram/actions/get-account-insights.action.js.map +1 -0
- package/dist/providers/instagram/actions/get-business-posts.action.d.ts +30 -0
- package/dist/providers/instagram/actions/get-business-posts.action.d.ts.map +1 -0
- package/dist/providers/instagram/actions/get-business-posts.action.js +246 -0
- package/dist/providers/instagram/actions/get-business-posts.action.js.map +1 -0
- package/dist/providers/instagram/actions/get-comments.action.d.ts +41 -0
- package/dist/providers/instagram/actions/get-comments.action.d.ts.map +1 -0
- package/dist/providers/instagram/actions/get-comments.action.js +337 -0
- package/dist/providers/instagram/actions/get-comments.action.js.map +1 -0
- package/dist/providers/instagram/actions/get-post-insights.action.d.ts +42 -0
- package/dist/providers/instagram/actions/get-post-insights.action.d.ts.map +1 -0
- package/dist/providers/instagram/actions/get-post-insights.action.js +271 -0
- package/dist/providers/instagram/actions/get-post-insights.action.js.map +1 -0
- package/dist/providers/instagram/actions/index.d.ts +9 -0
- package/dist/providers/instagram/actions/index.d.ts.map +1 -0
- package/dist/providers/instagram/actions/index.js +26 -0
- package/dist/providers/instagram/actions/index.js.map +1 -0
- package/dist/providers/instagram/actions/schedule-post.action.d.ts +34 -0
- package/dist/providers/instagram/actions/schedule-post.action.d.ts.map +1 -0
- package/dist/providers/instagram/actions/schedule-post.action.js +234 -0
- package/dist/providers/instagram/actions/schedule-post.action.js.map +1 -0
- package/dist/providers/instagram/actions/search-posts.action.d.ts +56 -0
- package/dist/providers/instagram/actions/search-posts.action.d.ts.map +1 -0
- package/dist/providers/instagram/actions/search-posts.action.js +479 -0
- package/dist/providers/instagram/actions/search-posts.action.js.map +1 -0
- package/dist/providers/instagram/index.d.ts +3 -0
- package/dist/providers/instagram/index.d.ts.map +1 -0
- package/dist/providers/instagram/index.js +20 -0
- package/dist/providers/instagram/index.js.map +1 -0
- package/dist/providers/instagram/instagram-base.action.d.ts +76 -0
- package/dist/providers/instagram/instagram-base.action.d.ts.map +1 -0
- package/dist/providers/instagram/instagram-base.action.js +362 -0
- package/dist/providers/instagram/instagram-base.action.js.map +1 -0
- package/dist/providers/linkedin/actions/create-article.action.d.ts +28 -0
- package/dist/providers/linkedin/actions/create-article.action.d.ts.map +1 -0
- package/dist/providers/linkedin/actions/create-article.action.js +275 -0
- package/dist/providers/linkedin/actions/create-article.action.js.map +1 -0
- package/dist/providers/linkedin/actions/create-post.action.d.ts +20 -0
- package/dist/providers/linkedin/actions/create-post.action.d.ts.map +1 -0
- package/dist/providers/linkedin/actions/create-post.action.js +188 -0
- package/dist/providers/linkedin/actions/create-post.action.js.map +1 -0
- package/dist/providers/linkedin/actions/get-followers.action.d.ts +29 -0
- package/dist/providers/linkedin/actions/get-followers.action.d.ts.map +1 -0
- package/dist/providers/linkedin/actions/get-followers.action.js +222 -0
- package/dist/providers/linkedin/actions/get-followers.action.js.map +1 -0
- package/dist/providers/linkedin/actions/get-organization-posts.action.d.ts +24 -0
- package/dist/providers/linkedin/actions/get-organization-posts.action.d.ts.map +1 -0
- package/dist/providers/linkedin/actions/get-organization-posts.action.js +163 -0
- package/dist/providers/linkedin/actions/get-organization-posts.action.js.map +1 -0
- package/dist/providers/linkedin/actions/get-personal-posts.action.d.ts +25 -0
- package/dist/providers/linkedin/actions/get-personal-posts.action.d.ts.map +1 -0
- package/dist/providers/linkedin/actions/get-personal-posts.action.js +156 -0
- package/dist/providers/linkedin/actions/get-personal-posts.action.js.map +1 -0
- package/dist/providers/linkedin/actions/get-post-analytics.action.d.ts +28 -0
- package/dist/providers/linkedin/actions/get-post-analytics.action.d.ts.map +1 -0
- package/dist/providers/linkedin/actions/get-post-analytics.action.js +200 -0
- package/dist/providers/linkedin/actions/get-post-analytics.action.js.map +1 -0
- package/dist/providers/linkedin/actions/index.d.ts +9 -0
- package/dist/providers/linkedin/actions/index.d.ts.map +1 -0
- package/dist/providers/linkedin/actions/index.js +25 -0
- package/dist/providers/linkedin/actions/index.js.map +1 -0
- package/dist/providers/linkedin/actions/schedule-post.action.d.ts +22 -0
- package/dist/providers/linkedin/actions/schedule-post.action.d.ts.map +1 -0
- package/dist/providers/linkedin/actions/schedule-post.action.js +205 -0
- package/dist/providers/linkedin/actions/schedule-post.action.js.map +1 -0
- package/dist/providers/linkedin/actions/search-posts.action.d.ts +41 -0
- package/dist/providers/linkedin/actions/search-posts.action.d.ts.map +1 -0
- package/dist/providers/linkedin/actions/search-posts.action.js +292 -0
- package/dist/providers/linkedin/actions/search-posts.action.js.map +1 -0
- package/dist/providers/linkedin/index.d.ts +3 -0
- package/dist/providers/linkedin/index.d.ts.map +1 -0
- package/dist/providers/linkedin/index.js +19 -0
- package/dist/providers/linkedin/index.js.map +1 -0
- package/dist/providers/linkedin/linkedin-base.action.d.ts +166 -0
- package/dist/providers/linkedin/linkedin-base.action.d.ts.map +1 -0
- package/dist/providers/linkedin/linkedin-base.action.js +346 -0
- package/dist/providers/linkedin/linkedin-base.action.js.map +1 -0
- package/dist/providers/tiktok/actions/create-video-post.action.d.ts +21 -0
- package/dist/providers/tiktok/actions/create-video-post.action.d.ts.map +1 -0
- package/dist/providers/tiktok/actions/create-video-post.action.js +226 -0
- package/dist/providers/tiktok/actions/create-video-post.action.js.map +1 -0
- package/dist/providers/tiktok/actions/get-account-analytics.action.d.ts +32 -0
- package/dist/providers/tiktok/actions/get-account-analytics.action.d.ts.map +1 -0
- package/dist/providers/tiktok/actions/get-account-analytics.action.js +242 -0
- package/dist/providers/tiktok/actions/get-account-analytics.action.js.map +1 -0
- package/dist/providers/tiktok/actions/get-comments.action.d.ts +44 -0
- package/dist/providers/tiktok/actions/get-comments.action.d.ts.map +1 -0
- package/dist/providers/tiktok/actions/get-comments.action.js +290 -0
- package/dist/providers/tiktok/actions/get-comments.action.js.map +1 -0
- package/dist/providers/tiktok/actions/get-trending-hashtags.action.d.ts +48 -0
- package/dist/providers/tiktok/actions/get-trending-hashtags.action.d.ts.map +1 -0
- package/dist/providers/tiktok/actions/get-trending-hashtags.action.js +309 -0
- package/dist/providers/tiktok/actions/get-trending-hashtags.action.js.map +1 -0
- package/dist/providers/tiktok/actions/get-user-videos.action.d.ts +20 -0
- package/dist/providers/tiktok/actions/get-user-videos.action.d.ts.map +1 -0
- package/dist/providers/tiktok/actions/get-user-videos.action.js +131 -0
- package/dist/providers/tiktok/actions/get-user-videos.action.js.map +1 -0
- package/dist/providers/tiktok/actions/get-video-analytics.action.d.ts +28 -0
- package/dist/providers/tiktok/actions/get-video-analytics.action.d.ts.map +1 -0
- package/dist/providers/tiktok/actions/get-video-analytics.action.js +198 -0
- package/dist/providers/tiktok/actions/get-video-analytics.action.js.map +1 -0
- package/dist/providers/tiktok/actions/index.d.ts +8 -0
- package/dist/providers/tiktok/actions/index.d.ts.map +1 -0
- package/dist/providers/tiktok/actions/index.js +25 -0
- package/dist/providers/tiktok/actions/index.js.map +1 -0
- package/dist/providers/tiktok/actions/search-videos.action.d.ts +89 -0
- package/dist/providers/tiktok/actions/search-videos.action.d.ts.map +1 -0
- package/dist/providers/tiktok/actions/search-videos.action.js +653 -0
- package/dist/providers/tiktok/actions/search-videos.action.js.map +1 -0
- package/dist/providers/tiktok/index.d.ts +3 -0
- package/dist/providers/tiktok/index.d.ts.map +1 -0
- package/dist/providers/tiktok/index.js +20 -0
- package/dist/providers/tiktok/index.js.map +1 -0
- package/dist/providers/tiktok/tiktok-base.action.d.ts +87 -0
- package/dist/providers/tiktok/tiktok-base.action.d.ts.map +1 -0
- package/dist/providers/tiktok/tiktok-base.action.js +294 -0
- package/dist/providers/tiktok/tiktok-base.action.js.map +1 -0
- package/dist/providers/twitter/actions/create-thread.action.d.ts +28 -0
- package/dist/providers/twitter/actions/create-thread.action.d.ts.map +1 -0
- package/dist/providers/twitter/actions/create-thread.action.js +217 -0
- package/dist/providers/twitter/actions/create-thread.action.js.map +1 -0
- package/dist/providers/twitter/actions/create-tweet.action.d.ts +24 -0
- package/dist/providers/twitter/actions/create-tweet.action.d.ts.map +1 -0
- package/dist/providers/twitter/actions/create-tweet.action.js +199 -0
- package/dist/providers/twitter/actions/create-tweet.action.js.map +1 -0
- package/dist/providers/twitter/actions/delete-tweet.action.d.ts +24 -0
- package/dist/providers/twitter/actions/delete-tweet.action.d.ts.map +1 -0
- package/dist/providers/twitter/actions/delete-tweet.action.js +158 -0
- package/dist/providers/twitter/actions/delete-tweet.action.js.map +1 -0
- package/dist/providers/twitter/actions/get-analytics.action.d.ts +44 -0
- package/dist/providers/twitter/actions/get-analytics.action.d.ts.map +1 -0
- package/dist/providers/twitter/actions/get-analytics.action.js +399 -0
- package/dist/providers/twitter/actions/get-analytics.action.js.map +1 -0
- package/dist/providers/twitter/actions/get-mentions.action.d.ts +24 -0
- package/dist/providers/twitter/actions/get-mentions.action.d.ts.map +1 -0
- package/dist/providers/twitter/actions/get-mentions.action.js +229 -0
- package/dist/providers/twitter/actions/get-mentions.action.js.map +1 -0
- package/dist/providers/twitter/actions/get-timeline.action.d.ts +24 -0
- package/dist/providers/twitter/actions/get-timeline.action.d.ts.map +1 -0
- package/dist/providers/twitter/actions/get-timeline.action.js +249 -0
- package/dist/providers/twitter/actions/get-timeline.action.js.map +1 -0
- package/dist/providers/twitter/actions/index.d.ts +14 -0
- package/dist/providers/twitter/actions/index.d.ts.map +1 -0
- package/dist/providers/twitter/actions/index.js +30 -0
- package/dist/providers/twitter/actions/index.js.map +1 -0
- package/dist/providers/twitter/actions/schedule-tweet.action.d.ts +30 -0
- package/dist/providers/twitter/actions/schedule-tweet.action.d.ts.map +1 -0
- package/dist/providers/twitter/actions/schedule-tweet.action.js +250 -0
- package/dist/providers/twitter/actions/schedule-tweet.action.js.map +1 -0
- package/dist/providers/twitter/actions/search-tweets.action.d.ts +41 -0
- package/dist/providers/twitter/actions/search-tweets.action.d.ts.map +1 -0
- package/dist/providers/twitter/actions/search-tweets.action.js +559 -0
- package/dist/providers/twitter/actions/search-tweets.action.js.map +1 -0
- package/dist/providers/twitter/index.d.ts +8 -0
- package/dist/providers/twitter/index.d.ts.map +1 -0
- package/dist/providers/twitter/index.js +24 -0
- package/dist/providers/twitter/index.js.map +1 -0
- package/dist/providers/twitter/twitter-base.action.d.ts +185 -0
- package/dist/providers/twitter/twitter-base.action.d.ts.map +1 -0
- package/dist/providers/twitter/twitter-base.action.js +484 -0
- package/dist/providers/twitter/twitter-base.action.js.map +1 -0
- package/dist/providers/youtube/actions/create-playlist.action.d.ts +28 -0
- package/dist/providers/youtube/actions/create-playlist.action.d.ts.map +1 -0
- package/dist/providers/youtube/actions/create-playlist.action.js +235 -0
- package/dist/providers/youtube/actions/create-playlist.action.js.map +1 -0
- package/dist/providers/youtube/actions/get-channel-analytics.action.d.ts +60 -0
- package/dist/providers/youtube/actions/get-channel-analytics.action.d.ts.map +1 -0
- package/dist/providers/youtube/actions/get-channel-analytics.action.js +429 -0
- package/dist/providers/youtube/actions/get-channel-analytics.action.js.map +1 -0
- package/dist/providers/youtube/actions/get-channel-videos.action.d.ts +28 -0
- package/dist/providers/youtube/actions/get-channel-videos.action.d.ts.map +1 -0
- package/dist/providers/youtube/actions/get-channel-videos.action.js +263 -0
- package/dist/providers/youtube/actions/get-channel-videos.action.js.map +1 -0
- package/dist/providers/youtube/actions/get-comments.action.d.ts +40 -0
- package/dist/providers/youtube/actions/get-comments.action.d.ts.map +1 -0
- package/dist/providers/youtube/actions/get-comments.action.js +381 -0
- package/dist/providers/youtube/actions/get-comments.action.js.map +1 -0
- package/dist/providers/youtube/actions/get-video-analytics.action.d.ts +48 -0
- package/dist/providers/youtube/actions/get-video-analytics.action.d.ts.map +1 -0
- package/dist/providers/youtube/actions/get-video-analytics.action.js +280 -0
- package/dist/providers/youtube/actions/get-video-analytics.action.js.map +1 -0
- package/dist/providers/youtube/actions/index.d.ts +10 -0
- package/dist/providers/youtube/actions/index.d.ts.map +1 -0
- package/dist/providers/youtube/actions/index.js +26 -0
- package/dist/providers/youtube/actions/index.js.map +1 -0
- package/dist/providers/youtube/actions/schedule-video.action.d.ts +24 -0
- package/dist/providers/youtube/actions/schedule-video.action.d.ts.map +1 -0
- package/dist/providers/youtube/actions/schedule-video.action.js +225 -0
- package/dist/providers/youtube/actions/schedule-video.action.js.map +1 -0
- package/dist/providers/youtube/actions/search-videos.action.d.ts +40 -0
- package/dist/providers/youtube/actions/search-videos.action.d.ts.map +1 -0
- package/dist/providers/youtube/actions/search-videos.action.js +483 -0
- package/dist/providers/youtube/actions/search-videos.action.js.map +1 -0
- package/dist/providers/youtube/actions/update-video-metadata.action.d.ts +32 -0
- package/dist/providers/youtube/actions/update-video-metadata.action.d.ts.map +1 -0
- package/dist/providers/youtube/actions/update-video-metadata.action.js +298 -0
- package/dist/providers/youtube/actions/update-video-metadata.action.js.map +1 -0
- package/dist/providers/youtube/actions/upload-video.action.d.ts +28 -0
- package/dist/providers/youtube/actions/upload-video.action.d.ts.map +1 -0
- package/dist/providers/youtube/actions/upload-video.action.js +266 -0
- package/dist/providers/youtube/actions/upload-video.action.js.map +1 -0
- package/dist/providers/youtube/index.d.ts +3 -0
- package/dist/providers/youtube/index.d.ts.map +1 -0
- package/dist/providers/youtube/index.js +19 -0
- package/dist/providers/youtube/index.js.map +1 -0
- package/dist/providers/youtube/youtube-base.action.d.ts +83 -0
- package/dist/providers/youtube/youtube-base.action.d.ts.map +1 -0
- package/dist/providers/youtube/youtube-base.action.js +319 -0
- package/dist/providers/youtube/youtube-base.action.js.map +1 -0
- package/package.json +42 -0
- package/social_actions_summary.md +439 -0
- package/src/base/base-social.action.ts +270 -0
- package/src/index.ts +26 -0
- package/src/providers/buffer/actions/create-post.action.ts +205 -0
- package/src/providers/buffer/actions/delete-post.action.ts +116 -0
- package/src/providers/buffer/actions/get-analytics.action.ts +146 -0
- package/src/providers/buffer/actions/get-pending-posts.action.ts +161 -0
- package/src/providers/buffer/actions/get-profiles.action.ts +126 -0
- package/src/providers/buffer/actions/get-sent-posts.action.ts +189 -0
- package/src/providers/buffer/actions/index.ts +8 -0
- package/src/providers/buffer/actions/reorder-queue.action.ts +141 -0
- package/src/providers/buffer/actions/search-posts.action.ts +262 -0
- package/src/providers/buffer/buffer-base.action.ts +490 -0
- package/src/providers/buffer/index.ts +2 -0
- package/src/providers/facebook/actions/boost-post.action.ts +412 -0
- package/src/providers/facebook/actions/create-album.action.ts +335 -0
- package/src/providers/facebook/actions/create-post.action.ts +243 -0
- package/src/providers/facebook/actions/get-page-insights.action.ts +427 -0
- package/src/providers/facebook/actions/get-page-posts.action.ts +241 -0
- package/src/providers/facebook/actions/get-post-insights.action.ts +338 -0
- package/src/providers/facebook/actions/index.ts +9 -0
- package/src/providers/facebook/actions/respond-to-comments.action.ts +372 -0
- package/src/providers/facebook/actions/schedule-post.action.ts +310 -0
- package/src/providers/facebook/actions/search-posts.action.ts +449 -0
- package/src/providers/facebook/facebook-base.action.ts +750 -0
- package/src/providers/facebook/index.ts +2 -0
- package/src/providers/hootsuite/actions/bulk-schedule-posts.action.ts +293 -0
- package/src/providers/hootsuite/actions/create-scheduled-post.action.ts +206 -0
- package/src/providers/hootsuite/actions/delete-scheduled-post.action.ts +173 -0
- package/src/providers/hootsuite/actions/get-analytics.action.ts +281 -0
- package/src/providers/hootsuite/actions/get-scheduled-posts.action.ts +220 -0
- package/src/providers/hootsuite/actions/get-social-profiles.action.ts +220 -0
- package/src/providers/hootsuite/actions/search-posts.action.ts +395 -0
- package/src/providers/hootsuite/actions/update-scheduled-post.action.ts +222 -0
- package/src/providers/hootsuite/hootsuite-base.action.ts +346 -0
- package/src/providers/hootsuite/index.ts +12 -0
- package/src/providers/instagram/README.md +129 -0
- package/src/providers/instagram/actions/create-post.action.ts +329 -0
- package/src/providers/instagram/actions/create-story.action.ts +415 -0
- package/src/providers/instagram/actions/get-account-insights.action.ts +449 -0
- package/src/providers/instagram/actions/get-business-posts.action.ts +281 -0
- package/src/providers/instagram/actions/get-comments.action.ts +395 -0
- package/src/providers/instagram/actions/get-post-insights.action.ts +302 -0
- package/src/providers/instagram/actions/index.ts +9 -0
- package/src/providers/instagram/actions/schedule-post.action.ts +248 -0
- package/src/providers/instagram/actions/search-posts.action.ts +569 -0
- package/src/providers/instagram/index.ts +3 -0
- package/src/providers/instagram/instagram-base.action.ts +430 -0
- package/src/providers/linkedin/actions/create-article.action.ts +301 -0
- package/src/providers/linkedin/actions/create-post.action.ts +190 -0
- package/src/providers/linkedin/actions/get-followers.action.ts +226 -0
- package/src/providers/linkedin/actions/get-organization-posts.action.ts +164 -0
- package/src/providers/linkedin/actions/get-personal-posts.action.ts +158 -0
- package/src/providers/linkedin/actions/get-post-analytics.action.ts +205 -0
- package/src/providers/linkedin/actions/index.ts +8 -0
- package/src/providers/linkedin/actions/schedule-post.action.ts +206 -0
- package/src/providers/linkedin/actions/search-posts.action.ts +323 -0
- package/src/providers/linkedin/index.ts +2 -0
- package/src/providers/linkedin/linkedin-base.action.ts +481 -0
- package/src/providers/tiktok/actions/create-video-post.action.ts +234 -0
- package/src/providers/tiktok/actions/get-account-analytics.action.ts +255 -0
- package/src/providers/tiktok/actions/get-comments.action.ts +332 -0
- package/src/providers/tiktok/actions/get-trending-hashtags.action.ts +341 -0
- package/src/providers/tiktok/actions/get-user-videos.action.ts +136 -0
- package/src/providers/tiktok/actions/get-video-analytics.action.ts +218 -0
- package/src/providers/tiktok/actions/index.ts +8 -0
- package/src/providers/tiktok/actions/search-videos.action.ts +717 -0
- package/src/providers/tiktok/index.ts +3 -0
- package/src/providers/tiktok/tiktok-base.action.ts +356 -0
- package/src/providers/twitter/README.md +207 -0
- package/src/providers/twitter/actions/create-thread.action.ts +227 -0
- package/src/providers/twitter/actions/create-tweet.action.ts +204 -0
- package/src/providers/twitter/actions/delete-tweet.action.ts +153 -0
- package/src/providers/twitter/actions/get-analytics.action.ts +440 -0
- package/src/providers/twitter/actions/get-mentions.action.ts +233 -0
- package/src/providers/twitter/actions/get-timeline.action.ts +248 -0
- package/src/providers/twitter/actions/index.ts +14 -0
- package/src/providers/twitter/actions/schedule-tweet.action.ts +259 -0
- package/src/providers/twitter/actions/search-tweets.action.ts +588 -0
- package/src/providers/twitter/index.ts +8 -0
- package/src/providers/twitter/twitter-base.action.ts +629 -0
- package/src/providers/youtube/actions/create-playlist.action.ts +256 -0
- package/src/providers/youtube/actions/get-channel-analytics.action.ts +502 -0
- package/src/providers/youtube/actions/get-channel-videos.action.ts +286 -0
- package/src/providers/youtube/actions/get-comments.action.ts +411 -0
- package/src/providers/youtube/actions/get-video-analytics.action.ts +298 -0
- package/src/providers/youtube/actions/index.ts +9 -0
- package/src/providers/youtube/actions/schedule-video.action.ts +246 -0
- package/src/providers/youtube/actions/search-videos.action.ts +530 -0
- package/src/providers/youtube/actions/update-video-metadata.action.ts +321 -0
- package/src/providers/youtube/actions/upload-video.action.ts +288 -0
- package/src/providers/youtube/index.ts +2 -0
- package/src/providers/youtube/youtube-base.action.ts +373 -0
- package/tsconfig.json +18 -0
|
@@ -0,0 +1,220 @@
|
|
|
1
|
+
import { RegisterClass } from '@memberjunction/global';
|
|
2
|
+
import { HootSuiteBaseAction, HootSuiteProfile } from '../hootsuite-base.action';
|
|
3
|
+
import { ActionParam, ActionResultSimple, RunActionParams } from '@memberjunction/actions-base';
|
|
4
|
+
import { LogStatus, LogError } from '@memberjunction/core';
|
|
5
|
+
/**
|
|
6
|
+
* Action to retrieve social profiles connected to HootSuite account
|
|
7
|
+
*/
|
|
8
|
+
@RegisterClass(HootSuiteBaseAction, 'HootSuiteGetSocialProfilesAction')
|
|
9
|
+
export class HootSuiteGetSocialProfilesAction extends HootSuiteBaseAction {
|
|
10
|
+
/**
|
|
11
|
+
* Get social profiles from HootSuite
|
|
12
|
+
*/
|
|
13
|
+
protected async InternalRunAction(params: RunActionParams): Promise<ActionResultSimple> {
|
|
14
|
+
const { Params, ContextUser } = params;
|
|
15
|
+
|
|
16
|
+
try {
|
|
17
|
+
// Initialize OAuth
|
|
18
|
+
const companyIntegrationId = this.getParamValue(Params, 'CompanyIntegrationID');
|
|
19
|
+
if (!await this.initializeOAuth(companyIntegrationId)) {
|
|
20
|
+
throw new Error('Failed to initialize OAuth connection');
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
// Extract parameters
|
|
24
|
+
const includeInactive = this.getParamValue(Params, 'IncludeInactive') || false;
|
|
25
|
+
const socialNetwork = this.getParamValue(Params, 'SocialNetwork');
|
|
26
|
+
|
|
27
|
+
// Get all profiles
|
|
28
|
+
LogStatus('Fetching social profiles...');
|
|
29
|
+
const profiles = await this.getSocialProfiles();
|
|
30
|
+
|
|
31
|
+
// Filter profiles based on parameters
|
|
32
|
+
let filteredProfiles = profiles;
|
|
33
|
+
|
|
34
|
+
// Filter by social network if specified
|
|
35
|
+
if (socialNetwork) {
|
|
36
|
+
filteredProfiles = filteredProfiles.filter(p =>
|
|
37
|
+
p.socialNetworkId.toLowerCase() === socialNetwork.toLowerCase()
|
|
38
|
+
);
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
// Process profiles to add additional information
|
|
42
|
+
const enrichedProfiles = await Promise.all(
|
|
43
|
+
filteredProfiles.map(async (profile) => {
|
|
44
|
+
try {
|
|
45
|
+
// Get additional profile details if available
|
|
46
|
+
const details = await this.getProfileDetails(profile.id);
|
|
47
|
+
|
|
48
|
+
return {
|
|
49
|
+
id: profile.id,
|
|
50
|
+
displayName: profile.displayName,
|
|
51
|
+
socialNetwork: this.mapSocialNetworkId(profile.socialNetworkId),
|
|
52
|
+
socialNetworkId: profile.socialNetworkId,
|
|
53
|
+
socialNetworkUserId: profile.socialNetworkUserId,
|
|
54
|
+
avatarUrl: profile.avatarUrl,
|
|
55
|
+
type: profile.type,
|
|
56
|
+
ownerId: profile.ownerId,
|
|
57
|
+
isActive: details?.isActive !== false,
|
|
58
|
+
followerCount: details?.followerCount,
|
|
59
|
+
followingCount: details?.followingCount,
|
|
60
|
+
postCount: details?.postCount,
|
|
61
|
+
profileUrl: details?.profileUrl,
|
|
62
|
+
verified: details?.verified || false
|
|
63
|
+
};
|
|
64
|
+
} catch (error) {
|
|
65
|
+
// If we can't get details, return basic info
|
|
66
|
+
LogStatus(`Could not get details for profile ${profile.id}: ${error instanceof Error ? error.message : 'Unknown error'}`);
|
|
67
|
+
return {
|
|
68
|
+
id: profile.id,
|
|
69
|
+
displayName: profile.displayName,
|
|
70
|
+
socialNetwork: this.mapSocialNetworkId(profile.socialNetworkId),
|
|
71
|
+
socialNetworkId: profile.socialNetworkId,
|
|
72
|
+
socialNetworkUserId: profile.socialNetworkUserId,
|
|
73
|
+
avatarUrl: profile.avatarUrl,
|
|
74
|
+
type: profile.type,
|
|
75
|
+
ownerId: profile.ownerId,
|
|
76
|
+
isActive: true
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
})
|
|
80
|
+
);
|
|
81
|
+
|
|
82
|
+
// Filter out inactive profiles if requested
|
|
83
|
+
const finalProfiles = includeInactive
|
|
84
|
+
? enrichedProfiles
|
|
85
|
+
: enrichedProfiles.filter(p => p.isActive);
|
|
86
|
+
|
|
87
|
+
// Create summary
|
|
88
|
+
const summary = {
|
|
89
|
+
totalProfiles: finalProfiles.length,
|
|
90
|
+
byNetwork: this.groupByNetwork(finalProfiles),
|
|
91
|
+
byType: this.groupByType(finalProfiles),
|
|
92
|
+
activeProfiles: finalProfiles.filter(p => p.isActive).length,
|
|
93
|
+
inactiveProfiles: finalProfiles.filter(p => !p.isActive).length,
|
|
94
|
+
verifiedProfiles: finalProfiles.filter(p => p.verified).length
|
|
95
|
+
};
|
|
96
|
+
|
|
97
|
+
// Store default profile in custom attribute if not set
|
|
98
|
+
if (finalProfiles.length > 0 && !this.getCustomAttribute(1)) {
|
|
99
|
+
const defaultProfile = finalProfiles.find(p => p.isActive) || finalProfiles[0];
|
|
100
|
+
await this.setCustomAttribute(1, defaultProfile.id);
|
|
101
|
+
LogStatus(`Set default profile to: ${defaultProfile.displayName} (${defaultProfile.id})`);
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
// Update output parameters
|
|
105
|
+
const outputParams = [...Params];
|
|
106
|
+
const profilesParam = outputParams.find(p => p.Name === 'Profiles');
|
|
107
|
+
if (profilesParam) profilesParam.Value = finalProfiles;
|
|
108
|
+
const summaryParam = outputParams.find(p => p.Name === 'Summary');
|
|
109
|
+
if (summaryParam) summaryParam.Value = summary;
|
|
110
|
+
|
|
111
|
+
return {
|
|
112
|
+
Success: true,
|
|
113
|
+
ResultCode: 'SUCCESS',
|
|
114
|
+
Message: `Retrieved ${finalProfiles.length} social profiles`,
|
|
115
|
+
Params: outputParams
|
|
116
|
+
};
|
|
117
|
+
|
|
118
|
+
} catch (error) {
|
|
119
|
+
const errorMessage = error instanceof Error ? error.message : 'Unknown error occurred';
|
|
120
|
+
|
|
121
|
+
return {
|
|
122
|
+
Success: false,
|
|
123
|
+
ResultCode: 'ERROR',
|
|
124
|
+
Message: `Failed to get social profiles: ${errorMessage}`,
|
|
125
|
+
Params
|
|
126
|
+
};
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
/**
|
|
131
|
+
* Get additional details for a profile
|
|
132
|
+
*/
|
|
133
|
+
private async getProfileDetails(profileId: string): Promise<any> {
|
|
134
|
+
try {
|
|
135
|
+
const response = await this.axiosInstance.get(`/socialProfiles/${profileId}`);
|
|
136
|
+
return response.data;
|
|
137
|
+
} catch (error) {
|
|
138
|
+
// Details endpoint might not be available for all profiles
|
|
139
|
+
return null;
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
/**
|
|
144
|
+
* Map social network ID to readable name
|
|
145
|
+
*/
|
|
146
|
+
private mapSocialNetworkId(networkId: string): string {
|
|
147
|
+
const networkMap: Record<string, string> = {
|
|
148
|
+
'TWITTER': 'Twitter',
|
|
149
|
+
'FACEBOOK': 'Facebook',
|
|
150
|
+
'FACEBOOK_PAGE': 'Facebook Page',
|
|
151
|
+
'INSTAGRAM': 'Instagram',
|
|
152
|
+
'INSTAGRAM_BUSINESS': 'Instagram Business',
|
|
153
|
+
'LINKEDIN': 'LinkedIn',
|
|
154
|
+
'LINKEDIN_COMPANY': 'LinkedIn Company',
|
|
155
|
+
'PINTEREST': 'Pinterest',
|
|
156
|
+
'YOUTUBE': 'YouTube',
|
|
157
|
+
'TIKTOK': 'TikTok'
|
|
158
|
+
};
|
|
159
|
+
|
|
160
|
+
return networkMap[networkId.toUpperCase()] || networkId;
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
/**
|
|
164
|
+
* Group profiles by network
|
|
165
|
+
*/
|
|
166
|
+
private groupByNetwork(profiles: any[]): Record<string, number> {
|
|
167
|
+
return profiles.reduce((groups, profile) => {
|
|
168
|
+
const network = profile.socialNetwork;
|
|
169
|
+
groups[network] = (groups[network] || 0) + 1;
|
|
170
|
+
return groups;
|
|
171
|
+
}, {} as Record<string, number>);
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
/**
|
|
175
|
+
* Group profiles by type
|
|
176
|
+
*/
|
|
177
|
+
private groupByType(profiles: any[]): Record<string, number> {
|
|
178
|
+
return profiles.reduce((groups, profile) => {
|
|
179
|
+
const type = profile.type || 'Unknown';
|
|
180
|
+
groups[type] = (groups[type] || 0) + 1;
|
|
181
|
+
return groups;
|
|
182
|
+
}, {} as Record<string, number>);
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
/**
|
|
186
|
+
* Define the parameters this action expects
|
|
187
|
+
*/
|
|
188
|
+
public get Params(): ActionParam[] {
|
|
189
|
+
return [
|
|
190
|
+
...this.oauthParams,
|
|
191
|
+
{
|
|
192
|
+
Name: 'IncludeInactive',
|
|
193
|
+
Type: 'Input',
|
|
194
|
+
Value: null
|
|
195
|
+
},
|
|
196
|
+
{
|
|
197
|
+
Name: 'SocialNetwork',
|
|
198
|
+
Type: 'Input',
|
|
199
|
+
Value: null
|
|
200
|
+
},
|
|
201
|
+
{
|
|
202
|
+
Name: 'Profiles',
|
|
203
|
+
Type: 'Output',
|
|
204
|
+
Value: null
|
|
205
|
+
},
|
|
206
|
+
{
|
|
207
|
+
Name: 'Summary',
|
|
208
|
+
Type: 'Output',
|
|
209
|
+
Value: null
|
|
210
|
+
}
|
|
211
|
+
];
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
/**
|
|
215
|
+
* Get action description
|
|
216
|
+
*/
|
|
217
|
+
public get Description(): string {
|
|
218
|
+
return 'Retrieves all social profiles connected to the HootSuite account with optional filtering';
|
|
219
|
+
}
|
|
220
|
+
}
|
|
@@ -0,0 +1,395 @@
|
|
|
1
|
+
import { RegisterClass } from '@memberjunction/global';
|
|
2
|
+
import { HootSuiteBaseAction, HootSuitePost } from '../hootsuite-base.action';
|
|
3
|
+
import { ActionParam, ActionResultSimple, RunActionParams } from '@memberjunction/actions-base';
|
|
4
|
+
import { LogStatus, LogError } from '@memberjunction/core';
|
|
5
|
+
import { SearchParams, SocialPost } from '../../../base/base-social.action';
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Action to search historical posts in HootSuite
|
|
9
|
+
*/
|
|
10
|
+
@RegisterClass(HootSuiteBaseAction, 'HootSuiteSearchPostsAction')
|
|
11
|
+
export class HootSuiteSearchPostsAction extends HootSuiteBaseAction {
|
|
12
|
+
/**
|
|
13
|
+
* Search for posts in HootSuite
|
|
14
|
+
*/
|
|
15
|
+
protected async InternalRunAction(params: RunActionParams): Promise<ActionResultSimple> {
|
|
16
|
+
const { Params, ContextUser } = params;
|
|
17
|
+
|
|
18
|
+
try {
|
|
19
|
+
// Initialize OAuth
|
|
20
|
+
const companyIntegrationId = this.getParamValue(Params, 'CompanyIntegrationID');
|
|
21
|
+
if (!await this.initializeOAuth(companyIntegrationId)) {
|
|
22
|
+
throw new Error('Failed to initialize OAuth connection');
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
// Extract search parameters
|
|
26
|
+
const query = this.getParamValue(Params, 'Query');
|
|
27
|
+
const hashtags = this.getParamValue(Params, 'Hashtags');
|
|
28
|
+
const startDate = this.getParamValue(Params, 'StartDate');
|
|
29
|
+
const endDate = this.getParamValue(Params, 'EndDate');
|
|
30
|
+
const profileId = this.getParamValue(Params, 'ProfileID');
|
|
31
|
+
const postState = this.getParamValue(Params, 'PostState') || 'PUBLISHED';
|
|
32
|
+
const limit = this.getParamValue(Params, 'Limit') || 100;
|
|
33
|
+
const includeAnalytics = this.getParamValue(Params, 'IncludeAnalytics') || false;
|
|
34
|
+
const sortBy = this.getParamValue(Params, 'SortBy') || 'publishedTime';
|
|
35
|
+
const sortOrder = this.getParamValue(Params, 'SortOrder') || 'DESC';
|
|
36
|
+
|
|
37
|
+
// Build search parameters
|
|
38
|
+
const searchParams: SearchParams = {
|
|
39
|
+
query: query,
|
|
40
|
+
hashtags: hashtags,
|
|
41
|
+
startDate: startDate ? new Date(startDate) : undefined,
|
|
42
|
+
endDate: endDate ? new Date(endDate) : undefined,
|
|
43
|
+
limit: limit
|
|
44
|
+
};
|
|
45
|
+
|
|
46
|
+
// Perform the search
|
|
47
|
+
LogStatus('Searching for posts...');
|
|
48
|
+
const posts = await this.searchPosts(searchParams);
|
|
49
|
+
|
|
50
|
+
// Filter by profile if specified
|
|
51
|
+
let filteredPosts = posts;
|
|
52
|
+
if (profileId) {
|
|
53
|
+
filteredPosts = posts.filter(p =>
|
|
54
|
+
p.profileId.includes(profileId) ||
|
|
55
|
+
(p.platformSpecificData?.socialProfileIds?.includes(profileId))
|
|
56
|
+
);
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
// Sort results
|
|
60
|
+
filteredPosts = this.sortPosts(filteredPosts, sortBy, sortOrder);
|
|
61
|
+
|
|
62
|
+
// Limit results
|
|
63
|
+
if (limit && filteredPosts.length > limit) {
|
|
64
|
+
filteredPosts = filteredPosts.slice(0, limit);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
// Optionally include analytics
|
|
68
|
+
if (includeAnalytics) {
|
|
69
|
+
LogStatus('Fetching analytics for posts...');
|
|
70
|
+
filteredPosts = await this.enrichPostsWithAnalytics(filteredPosts);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
// Analyze content patterns
|
|
74
|
+
const contentAnalysis = this.analyzePostContent(filteredPosts);
|
|
75
|
+
|
|
76
|
+
// Create summary
|
|
77
|
+
const summary = {
|
|
78
|
+
totalResults: filteredPosts.length,
|
|
79
|
+
dateRange: {
|
|
80
|
+
start: startDate || 'Not specified',
|
|
81
|
+
end: endDate || 'Not specified',
|
|
82
|
+
actualStart: filteredPosts.length > 0
|
|
83
|
+
? filteredPosts[filteredPosts.length - 1].publishedAt.toISOString()
|
|
84
|
+
: null,
|
|
85
|
+
actualEnd: filteredPosts.length > 0
|
|
86
|
+
? filteredPosts[0].publishedAt.toISOString()
|
|
87
|
+
: null
|
|
88
|
+
},
|
|
89
|
+
byProfile: this.groupByProfile(filteredPosts),
|
|
90
|
+
byMonth: this.groupByMonth(filteredPosts),
|
|
91
|
+
contentAnalysis: contentAnalysis,
|
|
92
|
+
topHashtags: this.extractTopHashtags(filteredPosts),
|
|
93
|
+
performanceStats: includeAnalytics ? this.calculatePerformanceStats(filteredPosts) : null
|
|
94
|
+
};
|
|
95
|
+
|
|
96
|
+
// Update output parameters
|
|
97
|
+
const outputParams = [...Params];
|
|
98
|
+
const postsParam = outputParams.find(p => p.Name === 'Posts');
|
|
99
|
+
if (postsParam) postsParam.Value = filteredPosts;
|
|
100
|
+
const summaryParam = outputParams.find(p => p.Name === 'Summary');
|
|
101
|
+
if (summaryParam) summaryParam.Value = summary;
|
|
102
|
+
|
|
103
|
+
return {
|
|
104
|
+
Success: true,
|
|
105
|
+
ResultCode: 'SUCCESS',
|
|
106
|
+
Message: `Found ${filteredPosts.length} posts matching search criteria`,
|
|
107
|
+
Params: outputParams
|
|
108
|
+
};
|
|
109
|
+
|
|
110
|
+
} catch (error) {
|
|
111
|
+
const errorMessage = error instanceof Error ? error.message : 'Unknown error occurred';
|
|
112
|
+
|
|
113
|
+
return {
|
|
114
|
+
Success: false,
|
|
115
|
+
ResultCode: 'ERROR',
|
|
116
|
+
Message: `Failed to search posts: ${errorMessage}`,
|
|
117
|
+
Params
|
|
118
|
+
};
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
/**
|
|
123
|
+
* Search for posts implementation
|
|
124
|
+
*/
|
|
125
|
+
protected async searchPosts(params: SearchParams): Promise<SocialPost[]> {
|
|
126
|
+
const queryParams: any = {
|
|
127
|
+
limit: Math.min(params.limit || 100, 100),
|
|
128
|
+
maxResults: params.limit
|
|
129
|
+
};
|
|
130
|
+
|
|
131
|
+
// Add state filter - default to published for historical search
|
|
132
|
+
queryParams.state = 'PUBLISHED';
|
|
133
|
+
|
|
134
|
+
// Add date filters
|
|
135
|
+
if (params.startDate) {
|
|
136
|
+
queryParams.publishedAfter = this.formatHootSuiteDate(params.startDate);
|
|
137
|
+
}
|
|
138
|
+
if (params.endDate) {
|
|
139
|
+
queryParams.publishedBefore = this.formatHootSuiteDate(params.endDate);
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
// Add text search
|
|
143
|
+
if (params.query) {
|
|
144
|
+
queryParams.text = params.query;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
// Add hashtag search
|
|
148
|
+
if (params.hashtags && params.hashtags.length > 0) {
|
|
149
|
+
// HootSuite API may require hashtags in the text query
|
|
150
|
+
const hashtagQuery = params.hashtags.map(tag =>
|
|
151
|
+
tag.startsWith('#') ? tag : `#${tag}`
|
|
152
|
+
).join(' ');
|
|
153
|
+
|
|
154
|
+
queryParams.text = params.query
|
|
155
|
+
? `${params.query} ${hashtagQuery}`
|
|
156
|
+
: hashtagQuery;
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
// Make paginated request
|
|
160
|
+
const hootSuitePosts = await this.makePaginatedRequest<HootSuitePost>('/messages', queryParams);
|
|
161
|
+
|
|
162
|
+
// Convert to common format
|
|
163
|
+
return hootSuitePosts.map(post => this.normalizePost(post));
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
/**
|
|
167
|
+
* Enrich posts with analytics data
|
|
168
|
+
*/
|
|
169
|
+
private async enrichPostsWithAnalytics(posts: SocialPost[]): Promise<SocialPost[]> {
|
|
170
|
+
const enrichedPosts: SocialPost[] = [];
|
|
171
|
+
|
|
172
|
+
for (const post of posts) {
|
|
173
|
+
try {
|
|
174
|
+
const response = await this.axiosInstance.get(`/analytics/posts/${post.id}`);
|
|
175
|
+
const analytics = response.data;
|
|
176
|
+
|
|
177
|
+
enrichedPosts.push({
|
|
178
|
+
...post,
|
|
179
|
+
analytics: this.normalizeAnalytics(analytics.metrics)
|
|
180
|
+
});
|
|
181
|
+
} catch (error) {
|
|
182
|
+
// If analytics fail, include post without analytics
|
|
183
|
+
LogStatus(`Could not get analytics for post ${post.id}`);
|
|
184
|
+
enrichedPosts.push(post);
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
return enrichedPosts;
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
/**
|
|
192
|
+
* Sort posts by specified criteria
|
|
193
|
+
*/
|
|
194
|
+
private sortPosts(posts: SocialPost[], sortBy: string, sortOrder: string): SocialPost[] {
|
|
195
|
+
return posts.sort((a, b) => {
|
|
196
|
+
let compareValue = 0;
|
|
197
|
+
|
|
198
|
+
switch (sortBy) {
|
|
199
|
+
case 'publishedTime':
|
|
200
|
+
compareValue = a.publishedAt.getTime() - b.publishedAt.getTime();
|
|
201
|
+
break;
|
|
202
|
+
case 'engagements':
|
|
203
|
+
compareValue = (a.analytics?.engagements || 0) - (b.analytics?.engagements || 0);
|
|
204
|
+
break;
|
|
205
|
+
case 'impressions':
|
|
206
|
+
compareValue = (a.analytics?.impressions || 0) - (b.analytics?.impressions || 0);
|
|
207
|
+
break;
|
|
208
|
+
default:
|
|
209
|
+
compareValue = a.publishedAt.getTime() - b.publishedAt.getTime();
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
return sortOrder === 'DESC' ? -compareValue : compareValue;
|
|
213
|
+
});
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
/**
|
|
217
|
+
* Analyze post content patterns
|
|
218
|
+
*/
|
|
219
|
+
private analyzePostContent(posts: SocialPost[]): any {
|
|
220
|
+
const totalPosts = posts.length;
|
|
221
|
+
if (totalPosts === 0) return null;
|
|
222
|
+
|
|
223
|
+
const contentLengths = posts.map(p => p.content.length);
|
|
224
|
+
const avgLength = contentLengths.reduce((a, b) => a + b, 0) / totalPosts;
|
|
225
|
+
|
|
226
|
+
const withMedia = posts.filter(p => p.mediaUrls && p.mediaUrls.length > 0).length;
|
|
227
|
+
const withHashtags = posts.filter(p => p.content.includes('#')).length;
|
|
228
|
+
const withLinks = posts.filter(p =>
|
|
229
|
+
p.content.includes('http://') || p.content.includes('https://')
|
|
230
|
+
).length;
|
|
231
|
+
|
|
232
|
+
return {
|
|
233
|
+
averageLength: Math.round(avgLength),
|
|
234
|
+
minLength: Math.min(...contentLengths),
|
|
235
|
+
maxLength: Math.max(...contentLengths),
|
|
236
|
+
withMedia: withMedia,
|
|
237
|
+
withMediaPercentage: (withMedia / totalPosts) * 100,
|
|
238
|
+
withHashtags: withHashtags,
|
|
239
|
+
withHashtagsPercentage: (withHashtags / totalPosts) * 100,
|
|
240
|
+
withLinks: withLinks,
|
|
241
|
+
withLinksPercentage: (withLinks / totalPosts) * 100
|
|
242
|
+
};
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
/**
|
|
246
|
+
* Extract top hashtags from posts
|
|
247
|
+
*/
|
|
248
|
+
private extractTopHashtags(posts: SocialPost[]): Array<{ hashtag: string; count: number }> {
|
|
249
|
+
const hashtagCounts: Record<string, number> = {};
|
|
250
|
+
|
|
251
|
+
posts.forEach(post => {
|
|
252
|
+
const hashtags = post.content.match(/#\w+/g) || [];
|
|
253
|
+
hashtags.forEach(tag => {
|
|
254
|
+
const normalized = tag.toLowerCase();
|
|
255
|
+
hashtagCounts[normalized] = (hashtagCounts[normalized] || 0) + 1;
|
|
256
|
+
});
|
|
257
|
+
});
|
|
258
|
+
|
|
259
|
+
return Object.entries(hashtagCounts)
|
|
260
|
+
.map(([hashtag, count]) => ({ hashtag, count }))
|
|
261
|
+
.sort((a, b) => b.count - a.count)
|
|
262
|
+
.slice(0, 10);
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
/**
|
|
266
|
+
* Calculate performance statistics
|
|
267
|
+
*/
|
|
268
|
+
private calculatePerformanceStats(posts: SocialPost[]): any {
|
|
269
|
+
const postsWithAnalytics = posts.filter(p => p.analytics);
|
|
270
|
+
if (postsWithAnalytics.length === 0) return null;
|
|
271
|
+
|
|
272
|
+
const totalEngagements = postsWithAnalytics.reduce((sum, p) =>
|
|
273
|
+
sum + (p.analytics?.engagements || 0), 0
|
|
274
|
+
);
|
|
275
|
+
const totalImpressions = postsWithAnalytics.reduce((sum, p) =>
|
|
276
|
+
sum + (p.analytics?.impressions || 0), 0
|
|
277
|
+
);
|
|
278
|
+
|
|
279
|
+
const avgEngagements = totalEngagements / postsWithAnalytics.length;
|
|
280
|
+
const avgImpressions = totalImpressions / postsWithAnalytics.length;
|
|
281
|
+
const engagementRate = totalImpressions > 0
|
|
282
|
+
? (totalEngagements / totalImpressions) * 100
|
|
283
|
+
: 0;
|
|
284
|
+
|
|
285
|
+
return {
|
|
286
|
+
postsAnalyzed: postsWithAnalytics.length,
|
|
287
|
+
averageEngagements: Math.round(avgEngagements),
|
|
288
|
+
averageImpressions: Math.round(avgImpressions),
|
|
289
|
+
totalEngagements: totalEngagements,
|
|
290
|
+
totalImpressions: totalImpressions,
|
|
291
|
+
engagementRate: engagementRate.toFixed(2)
|
|
292
|
+
};
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
/**
|
|
296
|
+
* Group posts by profile
|
|
297
|
+
*/
|
|
298
|
+
private groupByProfile(posts: SocialPost[]): Record<string, number> {
|
|
299
|
+
const groups: Record<string, number> = {};
|
|
300
|
+
|
|
301
|
+
posts.forEach(post => {
|
|
302
|
+
const profiles = post.platformSpecificData?.socialProfileIds || [post.profileId];
|
|
303
|
+
profiles.forEach((profileId: string) => {
|
|
304
|
+
groups[profileId] = (groups[profileId] || 0) + 1;
|
|
305
|
+
});
|
|
306
|
+
});
|
|
307
|
+
|
|
308
|
+
return groups;
|
|
309
|
+
}
|
|
310
|
+
|
|
311
|
+
/**
|
|
312
|
+
* Group posts by month
|
|
313
|
+
*/
|
|
314
|
+
private groupByMonth(posts: SocialPost[]): Record<string, number> {
|
|
315
|
+
const groups: Record<string, number> = {};
|
|
316
|
+
|
|
317
|
+
posts.forEach(post => {
|
|
318
|
+
const monthKey = post.publishedAt.toISOString().substring(0, 7);
|
|
319
|
+
groups[monthKey] = (groups[monthKey] || 0) + 1;
|
|
320
|
+
});
|
|
321
|
+
|
|
322
|
+
return groups;
|
|
323
|
+
}
|
|
324
|
+
|
|
325
|
+
/**
|
|
326
|
+
* Define the parameters this action expects
|
|
327
|
+
*/
|
|
328
|
+
public get Params(): ActionParam[] {
|
|
329
|
+
return [
|
|
330
|
+
...this.commonSocialParams,
|
|
331
|
+
{
|
|
332
|
+
Name: 'Query',
|
|
333
|
+
Type: 'Input',
|
|
334
|
+
Value: null
|
|
335
|
+
},
|
|
336
|
+
{
|
|
337
|
+
Name: 'Hashtags',
|
|
338
|
+
Type: 'Input',
|
|
339
|
+
Value: null
|
|
340
|
+
},
|
|
341
|
+
{
|
|
342
|
+
Name: 'StartDate',
|
|
343
|
+
Type: 'Input',
|
|
344
|
+
Value: null
|
|
345
|
+
},
|
|
346
|
+
{
|
|
347
|
+
Name: 'EndDate',
|
|
348
|
+
Type: 'Input',
|
|
349
|
+
Value: null
|
|
350
|
+
},
|
|
351
|
+
{
|
|
352
|
+
Name: 'PostState',
|
|
353
|
+
Type: 'Input',
|
|
354
|
+
Value: null
|
|
355
|
+
},
|
|
356
|
+
{
|
|
357
|
+
Name: 'Limit',
|
|
358
|
+
Type: 'Input',
|
|
359
|
+
Value: null
|
|
360
|
+
},
|
|
361
|
+
{
|
|
362
|
+
Name: 'IncludeAnalytics',
|
|
363
|
+
Type: 'Input',
|
|
364
|
+
Value: null
|
|
365
|
+
},
|
|
366
|
+
{
|
|
367
|
+
Name: 'SortBy',
|
|
368
|
+
Type: 'Input',
|
|
369
|
+
Value: null
|
|
370
|
+
},
|
|
371
|
+
{
|
|
372
|
+
Name: 'SortOrder',
|
|
373
|
+
Type: 'Input',
|
|
374
|
+
Value: null
|
|
375
|
+
},
|
|
376
|
+
{
|
|
377
|
+
Name: 'Posts',
|
|
378
|
+
Type: 'Output',
|
|
379
|
+
Value: null
|
|
380
|
+
},
|
|
381
|
+
{
|
|
382
|
+
Name: 'Summary',
|
|
383
|
+
Type: 'Output',
|
|
384
|
+
Value: null
|
|
385
|
+
}
|
|
386
|
+
];
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
/**
|
|
390
|
+
* Get action description
|
|
391
|
+
*/
|
|
392
|
+
public get Description(): string {
|
|
393
|
+
return 'Searches historical posts in HootSuite with support for text queries, hashtags, date ranges, and content analysis';
|
|
394
|
+
}
|
|
395
|
+
}
|