Codapult
ЦеныПлагиныБлогДокументацияДемо

SaaS-бойлерплейт для разработчиков

© 2026 Codapult. Все права защищены.

Сделано на Codapult

Проект

  • Цены
  • Плагины
  • Документация
  • Сравнение SaaS-шаблонов

О нас

  • Контакты

Правовая информация

  • Политика конфиденциальности
  • Условия использования
Все статьи

Getting Started

  • Introduction
  • Quick Start
  • Project Structure
  • License and Permitted Use

Configuration

  • Environment Variables
  • App Configuration

Authentication

  • Authentication
  • OAuth Providers
  • Two-Factor & Passwordless
  • Enterprise SSO (SAML)

Database

  • Database
  • Migrations

Teams

  • Teams & Organizations
  • Permissions & RBAC
  • SCIM Provisioning

Payments

  • Payments & Billing
  • Stripe Setup
  • LemonSqueezy Setup
  • Polar Setup
  • Payment Webhooks

Api

  • API Layer
  • tRPC
  • GraphQL

Ai

  • AI Features
  • Streaming Chat
  • RAG and Semantic Search
  • Quotas and Memory

Email

  • Email
  • Email Templates

Infrastructure

  • Infrastructure
  • Self-Hosting
  • File Storage
  • Docker
  • Background Jobs
  • Terraform & Pulumi
  • Kubernetes

Ui

  • UI & Theming

I18n

  • Internationalization

Content Management

  • Content Management

Admin

  • Admin Panel

Security

  • Security

Monitoring

  • Analytics & Monitoring

Modules

  • Module Architecture
  • Waitlist
  • Audit Log
  • White-Labeling
  • Workflow Automation
  • A/B Testing
  • Welcome Page
  • Referrals
  • GDPR Export and Deletion
  • Outgoing Webhooks

Plugins

  • Plugin System
  • AI Kit Plugin
  • CRM Plugin
  • Helpdesk Plugin
  • Email Marketing Plugin

Deployment

  • Deployment
  • Troubleshooting

Upgrading

  • Upgrading Codapult

Developer Tools

  • AI Agents & IDEs
  • MCP Server
  • Testing
Api

GraphQL

Add an optional GraphQL API to Codapult with graphql-yoga, SDL schema definitions, typed resolvers, authentication, and rate-limited route handlers.

Codapult includes an optional graphql-yoga server for teams that prefer GraphQL over REST or tRPC. It is an independent module and can be removed without affecting other API layers.

File Structure

PathDescription
src/lib/graphql/schema.tsSDL type definitions
src/lib/graphql/resolvers.tsResolver implementations
src/app/api/graphql/route.tsHTTP endpoint (GET + POST)

Endpoint

The GraphQL endpoint is available at /api/graphql. It supports both GET (for queries via URL params) and POST (standard JSON body) methods.

In development, graphql-yoga serves a built-in GraphiQL playground at the same URL when accessed from a browser.

When to Use GraphQL vs tRPC

Use caseRecommended
Internal frontend ↔ backend communicationtRPC
Public API for third-party consumersGraphQL
Mobile app with varied data requirementsGraphQL
Dashboard with full-stack TypeScripttRPC
Need introspection/schema discoveryGraphQL

Both layers share the same auth primitives (getAppSession) and rate limiting. You can use both simultaneously.

Authentication

The GraphQL route checks auth and applies rate limiting (60 requests per 60 seconds):

const session = await getAppSession();
// session is available in resolver context

Pass the session to resolvers via the context object. Protected resolvers should check ctx.session before returning data.

Removal

GraphQL is an independently removable module. Use the setup wizard:

npx @codapult/cli setup

Or remove manually: delete src/lib/graphql/, src/app/api/graphql/, and uninstall graphql, graphql-yoga, and graphql-tag dependencies.

tRPCAI Features