Skip to main content
Glama

Model Context Protocol Server

by hyen43
array.js733 B
import {getStreamContents} from './contents.js'; import {identity, noop, getContentsProperty} from './utils.js'; export async function getStreamAsArray(stream, options) { return getStreamContents(stream, arrayMethods, options); } const initArray = () => ({contents: []}); const increment = () => 1; const addArrayChunk = (convertedChunk, {contents}) => { contents.push(convertedChunk); return contents; }; const arrayMethods = { init: initArray, convertChunk: { string: identity, buffer: identity, arrayBuffer: identity, dataView: identity, typedArray: identity, others: identity, }, getSize: increment, truncateChunk: noop, addChunk: addArrayChunk, getFinalChunk: noop, finalize: getContentsProperty, };

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/hyen43/mcpServer'

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