Skip to main content
Glama

Storyden

by Southclaws
Mozilla Public License 2.0
229
useImageUpload.ts573 B
import { assetUpload } from "src/api/openapi-client/assets"; export function useImageUpload() { async function upload(f: File) { if (!isSupportedImage(f.type)) { throw new Error(`Unsupported image format ${f.type}`); } const asset = await assetUpload(f); return asset; } return { upload, }; } // TODO: Support uploading arbitrary files. export function isSupportedImage(mime: string): boolean { const category = mime.split("/")[0]; switch (category) { case "image": return true; default: return false; } }

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