Skip to main content
Glama
datasourcesApi.ts1.54 kB
import { makeApi, makeEndpoint, ZodiosEndpointDefinitions } from '@zodios/core'; import { z } from 'zod'; import { dataSourceSchema } from '../types/dataSource.js'; import { paginationSchema } from '../types/pagination.js'; import { paginationParameters } from './paginationParameters.js'; const listDatasourcesEndpoint = makeEndpoint({ method: 'get', path: '/sites/:siteId/datasources', alias: 'listDatasources', description: 'Returns a list of published data sources on the specified site. Supports a filter string as a query parameter in the format field:operator:value.', parameters: [ ...paginationParameters, { name: 'siteId', type: 'Path', schema: z.string(), }, { name: 'filter', type: 'Query', schema: z.string().optional(), description: 'Filter string in the format field:operator:value (e.g., name:eq:Project Views)', }, ], response: z.object({ pagination: paginationSchema, datasources: z.object({ datasource: z.optional(z.array(dataSourceSchema)), }), }), }); const queryDatasourceEndpoint = makeEndpoint({ method: 'get', path: '/sites/:siteId/datasources/:datasourceId', alias: 'queryDatasource', description: 'Returns information about the specified data source.', response: z.object({ datasource: dataSourceSchema, }), }); const datasourcesApi = makeApi([listDatasourcesEndpoint, queryDatasourceEndpoint]); export const datasourcesApis = [...datasourcesApi] as const satisfies ZodiosEndpointDefinitions;

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