Skip to main content
Glama

mcp-google-sheets

audit-event-module.ts1.6 kB
import { ListAuditEventsRequest } from '@activepieces/ee-shared' import { EndpointScope, PrincipalType, } from '@activepieces/shared' import { FastifyPluginAsyncTypebox } from '@fastify/type-provider-typebox' import { platformMustBeOwnedByCurrentUser, platformMustHaveFeatureEnabled } from '../authentication/ee-authorization' import { auditLogService } from './audit-event-service' export const auditEventModule: FastifyPluginAsyncTypebox = async (app) => { app.addHook('preHandler', platformMustHaveFeatureEnabled((platform) => platform.plan.auditLogEnabled)) app.addHook('preHandler', platformMustBeOwnedByCurrentUser) await app.register(auditEventController, { prefix: '/v1/audit-events' }) } const auditEventController: FastifyPluginAsyncTypebox = async (app) => { app.get('/', ListAuditEventsRequestEndpoint, async (request) => { return auditLogService(request.log).list({ platformId: request.principal.platform.id, cursorRequest: request.query.cursor ?? null, limit: request.query.limit ?? 20, action: request.query.action ?? undefined, projectId: request.query.projectId ?? undefined, userId: request.query.userId ?? undefined, createdBefore: request.query.createdBefore ?? undefined, createdAfter: request.query.createdAfter ?? undefined, }) }) } const ListAuditEventsRequestEndpoint = { schema: { querystring: ListAuditEventsRequest, allowedPrincipals: [PrincipalType.UNKNOWN], scope: EndpointScope.PLATFORM, }, }

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