Skip to main content
Glama
listPulseMetricDefinitionsFromDefinitionIds.test.ts1.08 kB
import z from 'zod'; import { pulseMetricDefinitionSchema } from '../../../src/sdks/tableau/types/pulse.js'; import { getPulseDefinition } from '../../constants.js'; import { getDefaultEnv, resetEnv, setEnv } from '../../testEnv.js'; import { callTool } from '../client.js'; describe('list-pulse-metric-definitions-from-definition-ids', () => { beforeAll(setEnv); afterAll(resetEnv); it('should list all pulse metrics from a metric definition id', async () => { const env = getDefaultEnv(); const tableauMcpDefinition = getPulseDefinition(env.SERVER, env.SITE_NAME, 'Tableau MCP'); const definitions = await callTool('list-pulse-metric-definitions-from-definition-ids', { env, schema: z.array(pulseMetricDefinitionSchema), toolArgs: { metricDefinitionIds: [tableauMcpDefinition.id], view: 'DEFINITION_VIEW_BASIC', }, }); expect(definitions.length).toBeGreaterThan(0); const definition = definitions.find((d) => d.metadata.id === tableauMcpDefinition.id); expect(definition).toBeDefined(); }); });

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/datalabs89/tableau-mcp'

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