Skip to main content
Glama
client.test.ts777 B
import { describe, it, expect, beforeEach } from 'vitest'; import { BitsoApiClient } from '../../src/client.js'; import { Config } from '../../src/config.js'; describe('BitsoApiClient', () => { let client: BitsoApiClient; let mockConfig: Config; beforeEach(() => { mockConfig = { apiKey: 'test-api-key', apiSecret: 'test-api-secret', apiEndpoint: 'https://api.bitso.com', timeout: 10000, cacheTtlSeconds: 300, }; client = new BitsoApiClient(mockConfig); }); describe('testConnection', () => { it('should return true when connection succeeds', async () => { // MSW will mock the API response to return success const result = await client.testConnection(); expect(result).toBe(true); }); }); });

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/blaze-xyz/bitso-mcp'

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