Skip to main content
Glama
mcpware

claude-code-organizer

list_destinations

Shows where a Claude Code item can be moved within the scope hierarchy to organize your development environment.

Instructions

List valid destination scopes for a specific item. Shows where this item can be moved to.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
categoryYesCategory of item
nameYesName of the item
scopeIdYesCurrent scope ID of the item

Implementation Reference

  • The application fetches available move destinations by querying the /api/destinations endpoint. While the tool name "list_destinations" was requested, this code interacts with the `/api/destinations` endpoint, which is the functional equivalent.
    async function openMoveModal(item) {
      const res = await fetchJson(`/api/destinations?path=${encodeURIComponent(item.path)}&category=${encodeURIComponent(item.category)}&name=${encodeURIComponent(item.name)}`);
      if (!res.ok) {
        toast(res.error, true);
        return;
      }
    
      const listEl = document.getElementById("moveDestList");
      const ordered = buildOrderedScopeEntries(res.destinations, res.currentScopeId);
      let selectedDest = null;
    
      listEl.innerHTML = ordered.map(renderDestinationRow).join("");
    
      listEl.querySelectorAll(".dest").forEach((entry) => {
        if (entry.classList.contains("cur")) return;
        entry.addEventListener("click", () => {
          listEl.querySelectorAll(".dest").forEach((node) => node.classList.remove("sel"));
          entry.classList.add("sel");
          selectedDest = entry.dataset.scopeId;
          document.getElementById("moveConfirm").disabled = false;
        });
      });
    
      document.getElementById("moveConfirm").disabled = true;
      document.getElementById("moveConfirm").onclick = async () => {
        if (!selectedDest) return;
        closeMoveModal();
        if (item.locked) {
          // Locked item — generate CC prompt instead of API call
          const destScope = getScopeById(selectedDest);
          const destName = destScope?.name || selectedDest;
          const prompt = `I want to move this Claude Code ${item.category} to a different scope.\n\nItem: "${item.name}"\nCurrent path: ${item.path}\nMove to scope: ${destName}\n\nBefore moving:\n1. Read the file and understand what it does\n2. Determine the correct destination path for the "${destName}" scope\n3. Check if a ${item.category} with the same name already exists at the destination\n4. Explain what will change — which projects will gain or lose access to this ${item.category}\n5. Warn me about any potential conflicts or breaking changes\n6. Only move the file after I confirm`;
          navigator.clipboard.writeText(prompt).then(() => {
            toast("Move prompt copied! Paste to Claude Code in your terminal.");
          });
        } else {
          await doMove(item, selectedDest);
        }
      };
    
      document.getElementById("moveModal").classList.remove("hidden");
    }

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/mcpware/claude-code-organizer'

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