Skip to main content
Glama
ampcome-mcps

Shortcut MCP Server

by ampcome-mcps

remove-external-link-from-story

Remove external URLs from Shortcut stories to maintain clean project documentation and prevent broken references in your workflow.

Instructions

Remove an external link from a Shortcut story

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
storyPublicIdYesThe public ID of the story
externalLinkYesThe external link URL to remove

Implementation Reference

  • Registers the 'remove-external-link-from-story' tool with MCP server, including description, Zod input schema (storyPublicId: positive number, externalLink: URL string max 2048 chars), and handler lambda delegating to StoryTools method.
    server.tool(
    	"remove-external-link-from-story",
    	"Remove an external link from a Shortcut story",
    	{
    		storyPublicId: z.number().positive().describe("The public ID of the story"),
    		externalLink: z.string().url().max(2048).describe("The external link URL to remove"),
    	},
    	async ({ storyPublicId, externalLink }) =>
    		await tools.removeExternalLinkFromStory(storyPublicId, externalLink),
    );
  • StoryTools.removeExternalLinkFromStory: Validates inputs, invokes client method to perform the removal, and returns a user-friendly success message with story URL.
    async removeExternalLinkFromStory(storyPublicId: number, externalLink: string) {
    	if (!storyPublicId) throw new Error("Story public ID is required");
    	if (!externalLink) throw new Error("External link is required");
    
    	const updatedStory = await this.client.removeExternalLinkFromStory(storyPublicId, externalLink);
    
    	return this.toResult(
    		`Removed external link from story sc-${storyPublicId}. Story URL: ${updatedStory.app_url}`,
    	);
    }
  • ShortcutClientWrapper.removeExternalLinkFromStory: Fetches the story, filters external_links array to remove the matching link (case-insensitive match), then calls updateStory to persist the change via Shortcut API.
    async removeExternalLinkFromStory(storyPublicId: number, externalLink: string): Promise<Story> {
    	const story = await this.getStory(storyPublicId);
    	if (!story) throw new Error(`Story ${storyPublicId} not found`);
    
    	const currentLinks = story.external_links || [];
    	const updatedLinks = currentLinks.filter(
    		(link) => link.toLowerCase() !== externalLink.toLowerCase(),
    	);
    
    	return await this.updateStory(storyPublicId, { external_links: updatedLinks });
    }
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries full burden for behavioral disclosure. It states the tool performs a removal action, implying mutation, but lacks critical details: whether this requires specific permissions, if the operation is reversible, what happens on success/failure, or any rate limits. For a mutation tool with zero annotation coverage, this is a significant gap in transparency.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that front-loads the core action and target. There's no wasted language, repetition, or unnecessary elaboration. It directly communicates the tool's function without ambiguity, making it highly concise and well-structured.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given this is a mutation tool with no annotations and no output schema, the description is incomplete. It doesn't address behavioral aspects like permissions, side effects, or error handling, nor does it explain what the tool returns. For a tool that modifies data, more context is needed to ensure safe and correct usage by an agent.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, with both parameters ('storyPublicId' and 'externalLink') well-documented in the schema. The description doesn't add any parameter-specific details beyond what the schema provides (e.g., it doesn't clarify format constraints or examples). According to guidelines, when schema coverage is high (>80%), the baseline score is 3 even without param info in the description.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('Remove') and target resource ('an external link from a Shortcut story'), making the purpose immediately understandable. It distinguishes from siblings like 'add-external-link-to-story' by specifying removal rather than addition. However, it doesn't explicitly contrast with other modification tools like 'set-story-external-links' or 'update-story', which prevents a perfect score.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., the link must exist), exclusions, or comparisons to sibling tools like 'set-story-external-links' (which might manage multiple links) or 'update-story' (which might handle broader story edits). Without this context, agents must infer usage from the tool name alone.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ampcome-mcps/shortcut-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server