c15t
/
C15T Logo
Select a version
Frameworks
Welcome to c15t Docs
Introduction to Consent Management (c15t)
AI Tools Integrations
OSS
Contributing to c15t.com
License
Building Privacy Tools in the Open
Legal
Cookie Policy
Privacy Policy
C15T Logo
HomeFrontendIntegrationsSelf HostChangelog
xbskydiscordgithub1.4k
c15t
/
C15T Logo
Select a version
Frameworks
Welcome to c15t Docs
Introduction to Consent Management (c15t)
AI Tools Integrations
OSS
Contributing to c15t.com
License
Building Privacy Tools in the Open
Legal
Cookie Policy
Privacy Policy
home-2Docs
chevron-rightSelf-host
chevron-rightV2

Getting Started

Quick start guide for self-hosting c15t with the @c15t/backend package.

DB Setup + Migrations

Run the Self Host CLI

npx @c15t/cli

Manual Setup

Install @c15t/backend Package

npm install @c15t/backend

Create a c15t instance

c15t.ts
import { c15tInstance } from '@c15t/backend/v2';
import { kyselyAdapter } from '@c15t/backend/v2/db/adapters/kysely';
import { Kysely } from 'kysely';

const handler = c15tInstance({
  appName: 'example-app',
  basePath: '/',
  adapter: kyselyAdapter({
    db: new Kysely({ }),
    provider: 'postgresql',
  }),
  trustedOrigins: ['localhost', 'vercel.app'],
  advanced: {
    disableGeoLocation: true,
    openapi: {
      enabled: true,
    },
  },
  logger: {
    level: 'debug',
  },
});

const handleRequest = async (request: NextRequest) => handler.handler(request);
C15T Logo
Leverage native React components for seamless integration and high performance in a robust Consent Management solution that empowers your development team while prioritizing privacy and compliance.
Product
  • Documentation
  • Components
Company
  • GitHub
  • Contact
Legal
  • Privacy Policy
  • Cookie Policy
c15t