Skip to main content
Glama

elfa_set_auth

Configure authentication for ELFA API requests by specifying key, header name, and scheme. Essential for integrating ELFA's sentiment data with crypto market analysis tools on CG Alpha MCP.

Instructions

Set ELFA API auth. Params: key (string), headerName (Authorization|x-elfa-api-key), scheme (e.g., Bearer).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
headerNameNo
keyYes
schemeNo

Implementation Reference

  • The async handler function that implements the core logic of elfa_set_auth by updating the global ELFA_AUTH object with the provided key, headerName, and scheme.
    "elfa_set_auth": async (args) => { const key = args && args.key; const headerName = args && args.headerName; const scheme = args && args.scheme; if (!key || typeof key !== "string") return { content: textContent({ ok:false, message:"Missing 'key' (string)" }), isError:true }; if (headerName && typeof headerName === "string") ELFA_AUTH.headerName = headerName; if (scheme !== undefined && typeof scheme === "string") ELFA_AUTH.scheme = scheme; ELFA_AUTH.key = key; return { content: textContent({ ok:true, headerName: ELFA_AUTH.headerName || "", scheme: ELFA_AUTH.scheme || "", key: maskKey(ELFA_AUTH.key) }) }; },
  • mcp-server.js:266-270 (registration)
    The tool registration object in the tools array, including description, input schema for validation, and annotations. Used in tools/list response.
    { name:"elfa_set_auth", description:"Set ELFA API auth. Params: key (string), headerName (Authorization|x-elfa-api-key), scheme (e.g., Bearer).", inputSchema:{ type:"object", properties:{ key:{type:"string"}, headerName:{type:"string"}, scheme:{type:"string"} }, required:["key"] }, annotations:{ title:"ELFA: Set Auth", readOnlyHint:false, openWorldHint:false } },
  • The inputSchema defining the expected parameters for the elfa_set_auth tool.
    inputSchema:{ type:"object", properties:{ key:{type:"string"}, headerName:{type:"string"}, scheme:{type:"string"} }, required:["key"] },

Other Tools

Related 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/JCF0/cg-alpha-mcp'

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