@posty5/mcp 2.0.0 → 2.1.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/dist/index.js CHANGED
@@ -1647,9 +1647,11 @@ var SOCIAL_POST_STATUSES = [
1647
1647
  "retrying",
1648
1648
  "removing",
1649
1649
  "removed",
1650
- "removeFailed"
1650
+ "removeFailed",
1651
+ "partiallyRemoved"
1651
1652
  ];
1652
1653
  var SOCIAL_POST_PLATFORMS = ["youtube", "facebook", "instagram", "tiktok"];
1654
+ var SOCIAL_POST_REMOVE_PLATFORMS = ["youtube", "facebook", "instagram", "tiktok", "threads", "twitter"];
1653
1655
  var VIDEO_PLATFORM_BLOCKS = ["youtube", "tiktok", "facebook", "instagram"];
1654
1656
  var SOCIAL_POST_TARGETS = ["workspaceId", "accountId"];
1655
1657
  var TIKTOK_PRIVACY_LEVELS = ["PUBLIC_TO_EVERYONE", "FOLLOWER_OF_CREATOR", "MUTUAL_FOLLOW_FRIENDS", "SELF_ONLY"];
@@ -2113,19 +2115,23 @@ var SOCIAL_PUBLISHER_TOOLS = [
2113
2115
  toolset: "social-publisher",
2114
2116
  access: "full",
2115
2117
  title: "Remove a post from the platforms",
2116
- description: "Deletes a published post's media from the platforms it was published to, at once. Instagram and TikTok offer no delete through their APIs, so media there stays. Irreversible. Paid, only when the removal succeeds: the price is in account_get_operation_costs.",
2117
- input: zod.z.object({ id: idField(POST_ID), version: versionField("the post") }),
2118
+ description: "Deletes a published post's media from the platforms it was published to, at once, or from one platform when `platform` is given (the others keep their copies and the post becomes partiallyRemoved). Instagram and TikTok offer no delete through their APIs, so media there stays. Irreversible. Paid, only when the removal succeeds: the price is in account_get_operation_costs.",
2119
+ input: zod.z.object({
2120
+ id: idField(POST_ID),
2121
+ version: versionField("the post"),
2122
+ platform: zod.z.enum(SOCIAL_POST_REMOVE_PLATFORMS).optional().describe("Remove from this platform only. The post must have been published there. Omit to remove from every platform.")
2123
+ }),
2118
2124
  annotations: { destructive: true, idempotent: true },
2119
2125
  confirm: {
2120
- describe: async ({ id }, { clients }) => {
2126
+ describe: async ({ id, platform }, { clients }) => {
2121
2127
  const post = await clients.posts.getStatus(id);
2122
- const platforms = postPlatforms(post);
2128
+ const platforms = platform ? [platform] : postPlatforms(post);
2123
2129
  const where = platforms.length ? platforms.join(", ") : "the platforms it was published to";
2124
2130
  return `Remove post #${post.numbering} from ${where}. The published media is deleted from those platforms immediately, and this is irreversible \u2014 it cannot be restored or re-published from here. Instagram and TikTok offer no delete through their APIs, so media there stays.`;
2125
2131
  },
2126
2132
  costFeaturePath: "socialMediaPublisher.removePost"
2127
2133
  },
2128
- run: ({ id, version }, { clients }) => clients.posts.removePost(id, version),
2134
+ run: ({ id, version, platform }, { clients }) => clients.posts.removePost(id, version, platform),
2129
2135
  entity: (_result, args) => ({ entityType: "socialPost", entityId: args.id })
2130
2136
  })
2131
2137
  ];