Skip to main content
Glama

Storyden

by Southclaws
Mozilla Public License 2.0
229
useConfirmation.ts485 B
"use client"; import { useState } from "react"; export function useConfirmation(fn: () => Promise<void>) { const [isConfirming, setConfirming] = useState(false); async function handleConfirmAction() { if (isConfirming) { await fn(); setConfirming(false); } else { setConfirming(true); } } async function handleCancelAction() { setConfirming(false); } return { isConfirming, handleConfirmAction, handleCancelAction, }; }

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/Southclaws/storyden'

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