Skip to main content
Glama

mcp-google-sheets

common.ts1.22 kB
import { httpClient, HttpMethod, AuthenticationType } from '@activepieces/pieces-common'; import { PieceAuth } from '@activepieces/pieces-framework'; export const insightlyAuth = PieceAuth.SecretText({ displayName: 'API Key', description: 'Enter your Insightly API key. You can find this in your Insightly account under User Settings > API Keys.', required: true, }); export const INSIGHTLY_OBJECTS = [ 'Contacts', 'Leads', 'Opportunities', 'Organisations', 'Projects', 'Tasks', 'Events', 'Notes', 'Products', 'Quotations' ]; export async function makeInsightlyRequest( apiKey: string, endpoint: string, pod = 'na1', method: HttpMethod = HttpMethod.GET, body?: any ) { const baseUrl = `https://api.${pod}.insightly.com/v3.1`; const url = `${baseUrl}${endpoint}`; const requestConfig: any = { method, url, authentication: { type: AuthenticationType.BASIC, username: apiKey, password: '', }, }; if (body && (method === HttpMethod.POST || method === HttpMethod.PUT)) { requestConfig.headers = { 'Content-Type': 'application/json', }; requestConfig.body = body; } return await httpClient.sendRequest(requestConfig); }

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/activepieces/activepieces'

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