### Start Development Server Source: https://context7_llms Command to start your development server and verify database connection. ```bash npm run dev ``` -------------------------------- ### Database Connection String Examples Source: https://context7_llms Examples of connection strings for different database providers. Ensure you replace placeholders with your actual credentials. ```bash # Neon (PostgreSQL): postgresql://[user]:[password]@[neon-host]/[database] ``` ```bash # Supabase (PostgreSQL): postgresql://postgres:[YOUR-PASSWORD]@db.[project-ref].supabase.co:5432/postgres ``` ```bash # PlanetScale (MySQL): mysql://[username]:[password]@[host]/[database]?sslaccept=strict ``` -------------------------------- ### Neon PostgreSQL Setup Guide Source: https://docs.indiekit.pro/setup/database Instructions for setting up a PostgreSQL database with Neon for an Indie Kit project. This includes account creation, project setup, and connection string retrieval. ```markdown ### Setting up Neon (PostgreSQL) 🎯 1. **Create a Neon Account** πŸ‘€ * Go to [Neon](https://neon.tech/) * Click "Sign Up" and create your account * You can use GitHub for quick signup 2. **Create a New Project** πŸ“¦ * Click "New Project" in your Neon dashboard * Choose a name for your project * Select the region closest to your users * Click "Create Project" 3. **Get Your Connection String** πŸ”— ```bash psql "postgresql://alex:V6OxTg8sXf0A@ep-green-tree-77239718.eu-central-1.aws.neon.tech/main?sslmode=require" ``` ``` -------------------------------- ### Email Authentication Setup Guide Source: https://docs.indiekit.pro/launch-with-waitlist Guide for setting up email authentication in Indiekit Pro. This typically involves configuring your application to handle user sign-ups and logins via email. ```N/A self.__next_f.push([1,"84:[\"$\",\"$L50\",null,{\"href\":\"/setup/auth\",\"children\":\"Email Authentication Setup Guide\"}]\n ``` -------------------------------- ### NextJS Project Setup and Build Source: https://indiekit.pro/ This output details the process of setting up and running a NextJS project. It includes cloning the repository, installing dependencies, starting the development server, and building the project for production. The commands demonstrate typical Next.js workflows using npm or yarn. ```bash Cloning into 'indie-kit'... remote: Enumerating objects: 1247, done. remote: Counting objects: 100% (1247/1247), done. Receiving objects: 100% (1247/1247), 2.34 MiB | 1.52 MiB/s, done. Resolving deltas: 100% (567/567), done. Lockfile is up to date, resolution step is skipped Already up to date Progress: resolved 847, reused 847, downloaded 0, added 847 βœ” Dependencies installed successfully Done in 3.2s > indie-kit@1.0.0 dev > next dev βœ” Ready - started server on 0.0.0.0:3000 Local: http://localhost:3000 βœ” Compiled successfully Vercel CLI 37.4.1 πŸ” Inspect: https://vercel.com/indie-kit/indie-kit/abc123 βœ… Running "build" command βœ… Creating an optimized production build βœ… Compiled successfully βœ… Deployment completed πŸš€ https://indie-kit-git-main-your-team.vercel.app ``` -------------------------------- ### MDX Frontmatter Example Source: https://context7_llms Shows the required frontmatter for an MDX documentation page, including title, description, and an optional icon. ```mdx --- title: Your Page Title description: A helpful description for SEO icon: Rocket --- # Your Content Here Write your documentation in MDX format! ``` -------------------------------- ### Example Plan Configurations (TSX) Source: https://context7_llms Provides example configurations for different subscription tiers (Basic, Pro, Enterprise) using TypeScript and JSX. Each configuration includes the plan name, codes required, and a list of features. ```tsx // Basic Tier { name: "LTD Basic", codesRequired: 1, features: [ "10 projects", "Basic support", "Lifetime access" ] } // Pro Tier { name: "LTD Pro", codesRequired: 2, features: [ "100 projects", "Priority support", "Advanced features", "Lifetime access" ] } // Enterprise Tier { name: "LTD Enterprise", codesRequired: 3, features: [ "Unlimited projects", "24/7 support", "All features", "Lifetime access" ] } ``` -------------------------------- ### Project Setup: Install Dependencies (Shell) Source: https://docs.indiekit.pro/multi-tenancy/b2b-kit Commands to clone the Indiekit Pro LLMs B2B boilerplate repository and install its dependencies using pnpm. ```shell git clone https://github.com/Indie-Kit/b2b-boilerplate cd b2b-boilerplate pnpm install ``` -------------------------------- ### Indiekit Pro LLM - Setup Instructions Source: https://docs.indiekit.pro/seo/google-search-console These instructions guide users through the initial setup process for Indiekit Pro LLMs. They outline the steps for navigating the application and making essential choices, such as selecting the property type. ```text Go to Click \"Start now\" or \"Add property\" if you already have an account You'll see two options - choose \"URL prefix\" ``` -------------------------------- ### Database Setup (Bash) Source: https://context7_llms Command to push the database schema to the connected database using pnpm. ```bash pnpm db:push # Push schema to database ``` -------------------------------- ### Content Organization Structure Source: https://context7_llms Provides a recommended directory structure for organizing different types of documentation content, such as getting started, setup, features, guides, and API reference. ```tree content/docs/ β”œβ”€β”€ getting-started.mdx # First steps β”œβ”€β”€ setup/ # Installation guides β”œβ”€β”€ features/ # Feature documentation β”œβ”€β”€ guides/ # How-to guides └── api/ # API reference ``` -------------------------------- ### DodoPayments Environment Variable Setup (Bash) Source: https://context7_llms Configuration for integrating DodoPayments for credit purchases. Requires setting the DodoPayments product ID as an environment variable in your `.env` file. This setup is specific to using DodoPayments as a supported payment provider. ```bash DODO_CREDITS_PRODUCT_ID="pdt_xxxxxxxxxxxxx" ``` -------------------------------- ### Google Login Setup Guide Source: https://docs.indiekit.pro/launch-with-waitlist Instructions for integrating Google login into your Indiekit Pro application. This allows users to authenticate using their existing Google accounts. ```N/A self.__next_f.push([1,"85:[\"$\",\"$L50\",null,{\"href\":\"/setup/auth/google-login\",\"children\":\"Google Login Setup Guide\"}]\n ``` -------------------------------- ### Example Quotas for Different Plans in TypeScript Source: https://context7_llms Illustrates example quota configurations for Free, Pro, and Enterprise plans. This includes numerical limits for projects and API calls, and string values for storage, with '-1' indicating unlimited usage. ```typescript // Free Plan { canUseApp: true, projects: 3, apiCalls: 100, storage: "1GB" } // Pro Plan { canUseApp: true, projects: 100, apiCalls: 10000, storage: "100GB" } // Enterprise Plan { canUseApp: true, projects: -1, // -1 = unlimited apiCalls: -1, storage: "unlimited" } ``` -------------------------------- ### JavaScript Module Import Example Source: https://docs.indiekit.pro/setup/auth/user-authentication A basic example of importing a module in JavaScript. This is a fundamental operation for utilizing code from other files or libraries. ```javascript import auth from './auth' ``` -------------------------------- ### Connection String Setup Instructions Source: https://docs.indiekit.pro/setup/database These instructions guide users on where to find their connection string and emphasize the importance of using the complete string. It's vital for successful database integration within the application. ```text Find the connection string in your project dashboard Make sure to use the full connection string with your credentials ``` -------------------------------- ### SWR Basic Fetching Example Source: https://context7_llms Demonstrates the most basic usage of the `useSWR` hook to fetch data from a given API endpoint. It directly returns the data, error, and loading state. ```javascript const { data, error, isLoading } = useSWR('/api/endpoint') ``` -------------------------------- ### Stripe Webhook Configuration Example (Bash) Source: https://context7_llms Illustrates how to set Stripe environment variables, differentiating between development (test mode) and production (live mode) keys and webhook secrets. ```bash # Development: Test mode STRIPE_SECRET_KEY=sk_test_... # Production: Live mode STRIPE_SECRET_KEY=sk_live_... STRIPE_WEBHOOK_SECRET=whsec_... ``` -------------------------------- ### Database Connection and Version Query (Go) Source: https://neon.tech/ This Go code snippet shows the basic structure for importing the `database/sql` package and starting a Go program. It's a foundational example for database interactions in Go. ```go package main import ( "database/sql" ) ``` -------------------------------- ### GET /api/products Source: https://context7_llms Fetches a list of products. This endpoint can be used to display product data and demonstrates handling loading and error states. ```APIDOC ## GET /api/products ### Description Fetches a list of products. This endpoint can be used to display product data and demonstrates handling loading and error states. ### Method GET ### Endpoint /api/products ### Parameters #### Query Parameters None ### Request Example ```json {} ``` ### Response #### Success Response (200) - **data** (array) - A list of products. #### Response Example ```json [ { "id": 1, "name": "Product A", "price": 10.00 }, { "id": 2, "name": "Product B", "price": 20.00 } ] ``` ``` -------------------------------- ### React Card Component Example Source: https://context7_llms Demonstrates the usage of Card and Cards components from 'fumadocs-ui' for creating navigation and feature summaries within the application's overview page. ```jsx import { Card, Cards } from 'fumadocs-ui/components/card'; // ... inside a React component Get Indie Kit running locally in 5 minutes Go live with a beautiful landing page Build hype before launch ``` -------------------------------- ### MDX Callout Component Example Source: https://context7_llms Shows how to use the `Callout` component within MDX to highlight important information with different types like 'warning'. ```mdx This is a callout component! ``` -------------------------------- ### Display Waitlist Entry Details (Text) Source: https://context7_llms Shows an example of how waitlist entries are displayed, including Name, Email, and Signup Date. This is a simple text-based representation. ```text Name: Sarah Johnson Email: sarah@example.com Signed up: Oct 15, 2025, 3:45 PM ``` -------------------------------- ### Project Setup and Integration Guide (Markdown) Source: https://21st.dev/ Provides a comprehensive guide for integrating the React component into a shadcn/ui project. It covers dependency installation, file structure recommendations, and essential questions to consider during integration. ```markdown You are given a task to integrate an existing React component in the codebase The codebase should support: - shadcn project structure - Tailwind CSS - Typescript If it doesn't, provide instructions on how to setup project via shadcn CLI, install Tailwind or Typescript. Determine the default path for components and styles. If default path for components is not /components/ui, provide instructions on why it's important to create this folder Copy-paste this component to /components/ui folder: ```tsx prism.tsx import { useEffect, useRef } from "react"; import { Renderer, Triangle, Program, Mesh } from "ogl"; const Prism = ({ height = 3.5, baseWidth = 5.5, animationType = "rotate", glow = 1, offset = { x: 0, y: 0 }, noise = 0.5, transparent = true, scale = 3.6, hueShift = 0, colorFrequency = 1, hoverStrength = 2, inertia = 0.05, bloom = 1, suspendWhenOffscreen = false, timeScale = 0.5, }) => { const containerRef = useRef(null); useEffect(() => { const container = containerRef.current; if (!container) return; const H = Math.max(0.001, height); const BW = Math.max(0.001, baseWidth); const BASE_HALF = BW * 0.5; const GLOW = Math.max(0.0, glow); const NOISE = Math.max(0.0, noise); const offX = offset?.x ?? 0; const offY = offset?.y ?? 0; const SAT = transparent ? 1.5 : 1; const SCALE = Math.max(0.001, scale); const HUE = hueShift || 0; const CFREQ = Math.max(0.0, colorFrequency || 1); const BLOOM = Math.max(0.0, bloom || 1); const RSX = 1; const RSY = 1; const RSZ = 1; ``` -------------------------------- ### Combining Multiple Components Example (JavaScript) Source: https://docs.indiekit.pro/customisation/installed-components Shows how to build a complete landing page by combining various components like Hero, FeatureGrid, TestimonialGrid, and CTA1. ```javascript import Hero1 from "@/components/sections/hero-1"; import FeatureGrid from "@/components/sections/feature-grid"; import TestimonialGrid from "@/components/sections/testimonial-grid"; import CTA1 from "@/components/website/cta-1"; export default function LandingPage() { return (
); } ``` -------------------------------- ### App Router: Getting Started Source: https://nextjs.org/docs/app/api-reference/file-conventions/metadata/sitemap Guide to creating full-stack web applications with the Next.js App Router. ```APIDOC ## App Router: Getting Started ### Description Learn how to create full-stack web applications with the Next.js App Router. ### Method Not specified ### Endpoint /llmstxt/indiekit_pro_llms-full_txt/app/getting-started ### Parameters None specified ### Request Example None specified ### Response #### Success Response (200) Not specified #### Response Example None specified ``` ```APIDOC ## App Router: Installation ### Description Learn how to create a new Next.js application with the `create-next-app` CLI, and set up TypeScript, ESLint, and Module Path Aliases. ### Method Not specified ### Endpoint /llmstxt/indiekit_pro_llms-full_txt/app/getting-started/installation ### Parameters None specified ### Request Example None specified ### Response #### Success Response (200) Not specified #### Response Example None specified ``` ```APIDOC ## App Router: Project Structure ### Description Learn the folder and file conventions in Next.js, and how to organize your project. ### Method Not specified ### Endpoint /llmstxt/indiekit_pro_llms-full_txt/app/getting-started/project-structure ### Parameters None specified ### Request Example None specified ### Response #### Success Response (200) Not specified #### Response Example None specified ``` ```APIDOC ## App Router: Layouts and Pages ### Description Learn how to create your first pages and layouts, and link between them with the Link component. ### Method Not specified ### Endpoint /llmstxt/indiekit_pro_llms-full_txt/app/getting-started/layouts-and-pages ### Parameters None specified ### Request Example None specified ### Response #### Success Response (200) Not specified #### Response Example None specified ``` ```APIDOC ## App Router: Linking and Navigating ### Description Learn how the built-in navigation optimizations work, including prefetching, prerendering, and client-side navigation, and how to optimize navigation for dynamic routes and slow networks. ### Method Not specified ### Endpoint /llmstxt/indiekit_pro_llms-full_txt/app/getting-started/linking-and-navigating ### Parameters None specified ### Request Example None specified ### Response #### Success Response (200) Not specified #### Response Example None specified ``` -------------------------------- ### React Component Integration and Setup Guide Source: https://21st.dev/ Instructions for integrating a React component into a project using shadcn, Tailwind CSS, and TypeScript. It details project setup via shadcn CLI, Tailwind and TypeScript installation, and component placement within the standard '/components/ui' directory. ```markdown You are given a task to integrate an existing React component in the codebase\ \ The codebase should support:\ - shadcn project structure \ - Tailwind CSS\ - Typescript\ \ If it doesn't, provide instructions on how to setup project via shadcn CLI, install Tailwind or Typescript.\ \ Determine the default path for components and styles. \ If default path for components is not /components/ui, provide instructions on why it's important to create this folder\ Copy-paste this component to /components/ui folder:\ ```tsx\ ai-prompt-box.tsx\ import React from \"react\";\ import * as TooltipPrimitive from \"@radix-ui/react-tooltip\";\ import * as DialogPrimitive from \"@radix-ui/react-dialog\";\ import { ArrowUp, Paperclip, Square, X, StopCircle, Mic, Globe, BrainCog, FolderCode } from \"lucide-react\";\ import { motion, AnimatePresence } from \"framer-motion\";\ \ // Utility function for className merging\ const cn = (...classes: (string | undefined | null | false)[]) => classes.filter(Boolean).join(\" \");\ \ // Embedded CSS for minimal custom styles\ const styles = `\ *:focus-visible {\ outline-offset: 0 !important;\ --ring-offset: 0 !important;\ }\ textarea::-webkit-scrollbar {\ width: 6px;\ }\ textarea::-webkit-scrollbar-track {\ background: transparent;\ }\ textarea::-webkit-scrollbar-thumb {\ background-color: #444444;\ border-radius: 3px;\ }\ textarea::-webkit-scrollbar-thumb:hover {\ background-color: #555555;\ }\ `;\ \ // Inject styles into document\ const styleSheet = document.createElement(\"style\");\ styleSheet.innerText = styles;\ document.head.appendChild(styleSheet);\ \ // Textarea Component\ interface TextareaProps extends React.TextareaHTMLAttributes {\ className?: string;\ }\ const Textarea = React.forwardRef(({ className, ...props }, ref) => (\ \ ));\ Textarea.displayName = \"Textarea\";\ \ // Tooltip Components\ const TooltipProvider ``` -------------------------------- ### LemonSqueezy Webhook Setup Example Source: https://docs.indiekit.pro/setup/payments/lemonsqueezy This snippet shows the structure for configuring a webhook endpoint in LemonSqueezy. It specifies the URL to receive events and lists the essential subscription-related events to enable for seamless integration. ```text Webhook Endpoint: https://your-domain.com/api/webhooks/lemonsqueezy Enable these webhook events: - subscription_created - subscription_updated - subscription_cancelled - subscription_resumed - order_created ``` -------------------------------- ### Basic Component Usage Example (JavaScript) Source: https://docs.indiekit.pro/customisation/installed-components Demonstrates the basic usage of the Hero1 component within a React page. It shows how to import and render the component. ```javascript import Hero1 from "@/components/sections/hero-1"; export default function HomePage() { return (
); } ``` -------------------------------- ### Complete Lifetime Access Purchase Button Example Source: https://context7_llms This React component example demonstrates how to build a 'Get Lifetime Access' button. It fetches plan details, calculates savings, and uses the `getSubscribeUrl` helper to create a direct purchase link. The component conditionally renders only if the plan has one-time pricing enabled. ```tsx import Link from 'next/link' import { Button } from '@/components/ui/button' import getSubscribeUrl, { PlanType, PlanProvider } from '@/lib/plans/getSubscribeUrl' function LifetimeAccessCard({ plan }) { if (!plan.hasOnetimePricing) return null const price = plan.onetimePrice / 100 const savings = (plan.monthlyPrice * 12) - plan.onetimePrice const savingsPercent = Math.round((savings / (plan.monthlyPrice * 12)) * 100) return (

{plan.name}

Save {savingsPercent}%
${price} one-time
    {plan.featuresList.map((feature, i) => (
  • {feature}
  • ))}

✨ One-time payment β€’ Lifetime access β€’ No recurring fees

) } ``` -------------------------------- ### Programmatic SEO: Include Database Items in Sitemap (TypeScript) Source: https://context7_llms This example shows how to generate a sitemap that includes items from a database, such as blog posts and projects. It fetches data from the database and maps it to the sitemap format, ensuring dynamic content is included for SEO. Requires `next` and database connection setup. ```typescript import { MetadataRoute } from "next"; import { getAllBlogs } from "@/lib/mdx/blogs"; import { db } from "@/db"; // Your database instance import { projects } from "@/db/schema"; // Your projects table export default async function sitemap(): Promise { const baseUrl = process.env.NEXT_PUBLIC_APP_URL!; const blogs = await getAllBlogs(); // Fetch all projects from database const allProjects = await db.select().from(projects); // Static pages const staticPages = [ "", "/about", "/contact", "/projects", // Projects listing page ].map((route) => ({ url: `${baseUrl}${route}`, lastModified: new Date(), changeFrequency: "monthly" as const, priority: route === "" ? 1 : 0.8, })); // Blog pages const blogPages = blogs.map((blog) => ({ url: `${baseUrl}/blog/${blog.slug}`, lastModified: new Date(blog.frontmatter.createdDate), changeFrequency: "weekly" as const, priority: 0.6, })); // 🎯 Project pages from database const projectPages = allProjects.map((project) => ({ url: `${baseUrl}/projects/${project.slug}`, lastModified: project.updatedAt || project.createdAt, changeFrequency: "weekly" as const, priority: 0.7, })); return [...staticPages, ...blogPages, ...projectPages]; } ``` -------------------------------- ### Install Project Dependencies Source: https://docs.indiekit.pro/getting-started Installs all the necessary project dependencies using pnpm. This command should be run after cloning the repository or setting up the project. ```bash pnpm install ``` -------------------------------- ### Environment Variables Setup (Bash) Source: https://context7_llms Essential environment variables for configuring database connections, authentication (NextAuth URL and secret), OAuth providers (Google Client ID and Secret), email services (AWS SES keys and region), and payment gateways (Stripe keys). ```bash DATABASE_URL=your_database_connection_string NEXTAUTH_URL=https://your-domain.com NEXTAUTH_SECRET=your_secret_key GOOGLE_CLIENT_ID=your_google_client_id GOOGLE_CLIENT_SECRET=your_google_client_secret AWS_ACCESS_KEY_ID=your_aws_access_key AWS_SECRET_ACCESS_KEY=your_aws_secret_key AWS_SES_REGION=us-east-1 STRIPE_SECRET_KEY=sk_live_... STRIPE_WEBHOOK_SECRET=whsec_... NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY=pk_live_... ``` -------------------------------- ### Local Development Setup Instructions Source: https://docs.indiekit.pro/setup/background-jobs Provides instructions and the endpoint for setting up and running the local development server for the Indiekit Pro LLMs project. Includes commands to start the server and monitor jobs. ```bash self.__next_f.push([1,"70:[\"$\",\"h2\",null,{\"className\":\"flex scroll-m-28 flex-row items-center gap-2\",\"id\":\"local-development-\",\"children\":[[\"$\",\"a\",null,{\"data-card\":\"\",\"href\":\"#local-development-\",\"className\":\"peer\",\"children\":\"Local Development πŸ’»\"}], [\"$\",\"svg\",null,{\"ref\":\"$undefined\",\"xmlns\":\"http://www.w3.org/2000/svg\",\"width\":24,\"height\":24,\"viewBox\":\"0 0 24 24\",\"fill\":\"none\",\"stroke\":\"currentColor\",\"strokeWidth\":2,\"strokeLinecap\":\"round\",\"strokeLinejoin\":\"round\",\"className\":\"lucide size-3.5 shrink-0 text-fd-muted-foreground opacity-0 transition-opacity peer-hover:opacity-100\",\"aria-label\":\"Link to section\",\"children\":[[[\"$\",\"path\",\"1cjeqo\",{\"d\":\"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71\"}], [\"$\",\"path\",\"19qd67\",{\"d\":\"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71\"}] ],\"$undefined\" ]} ]]} ]) self.__next_f.push([1,"71:[\"$\",\"p\",null,{\"children\":\"Your local Inngest server runs automatically at:\"}] ]) self.__next_f.push([1,"72:[\"$\",\"$La2\",null,{\"className\":\"shiki shiki-themes github-light github-dark\",\"style\":{\"--shiki-light\":\"#24292e\",\"--shiki-dark\":\"#e1e4e8\",\"--shiki-light-bg\":\"#fff\",\"--shiki-dark-bg\":\"#24292e\"},\"tabIndex\":\"0\",\"icon\":\"\n\n\",\"children\":[\"$\",\"$La3\",null,{\"children\":[\"$\",\"code\",null,{\"children\":[\"$\",\"span\",null,{\"className\":\"line\",\"children\":[\"$\",\"span\",null,{\"children\":\"http://localhost:8288/stream\"}]}]}]}]}] ]) self.__next_f.push([1,"73:[\"$\",\"p\",null,{\"children\":[\"$\",\"strong\",null,{\"children\":\"Monitor your jobs:\"}]}] 74:[\"$\",\"ol\",null,{\"children\":[\"\\n\",[\"$\",\"li\",null,{\"children\":[\"Start your dev server: \",[\"$\",\"code\",null,{\"children\":\"pnpm dev\"}]\]}],\"\\n\",[\"$\",\"li\",null,{\"children\"}]}]} ``` -------------------------------- ### GET /api/app/profile Source: https://context7_llms Retrieves user profile data after authenticating the request. ```APIDOC ## GET /api/app/profile ### Description Retrieves the profile information for the currently authenticated user. ### Method GET ### Endpoint /api/app/profile ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) - **id** (string) - The unique identifier of the user. - **name** (string) - The name of the user. - **email** (string) - The email address of the user. #### Response Example ```json { "id": "user123", "name": "John Doe", "email": "john.doe@example.com" } ``` ``` -------------------------------- ### Import and Use shadcn/ui Calendar Component Source: https://context7_llms After installing the calendar component using pnpm, import it into your React component and use it as needed. This example demonstrates setting up a single-date selection calendar. ```tsx import { Calendar } from "@/components/ui/calendar"; export default function MyPage() { return (
); } ``` ```tsx "use client"; import { Calendar } from "@/components/ui/calendar"; import { useState } from "react"; export default function BookingPage() { const [date, setDate] = useState(new Date()); return (
); } ``` -------------------------------- ### Render Deployment Steps for IndieKit Pro Source: https://docs.indiekit.pro/deployment This snippet details the deployment process for IndieKit Pro projects on Render. It covers account creation, GitHub connection, repository selection, environment variable setup, and the final deployment click. Render is highlighted as a cost-effective option for bootstrappers. ```text Deployment steps: 1. Create account 2. Connect GitHub β†’ Authorize repository access 3. Select repository β†’ Choose your Indie Kit project 4. Add environment variables β†’ Copy from .env.local 5. Deploy! β†’ Click deploy and you're live! πŸŽ‰ Need help? The creator is super helpful! Contact them via: πŸ“§ Email from their website πŸ’¬ Discord community ``` -------------------------------- ### DKIM DNS Record Example Source: https://context7_llms An example of a DKIM DNS TXT record, used to verify the authenticity of emails sent from a domain. This record contains the public key used for signature verification. ```txt selector._domainkey.yourdomain.com TXT "v=DKIM1; k=rsa; p=MIGfMA0GCSqGSIb3DQEBAQUAA4..." ``` -------------------------------- ### Basic Route Handler: GET Request Source: https://nextjs.org/docs/app/building-your-application/routing/route-handlers This snippet demonstrates a simple GET request handler that returns a JSON response. It uses the `Response.json()` method for creating the response. This is a fundamental example for setting up a basic API endpoint. ```typescript export async function GET() { return Response.json({ message: 'Hello World' }) } ``` -------------------------------- ### HTTP GET Method Implementation Source: https://context7_llms Implements the HTTP GET method for fetching data from a database. This server-side function retrieves data and returns it as a JSON response using NextResponse.json. It assumes the existence of a fetchFromDatabase function. ```tsx export async function GET() { const data = await fetchFromDatabase() return NextResponse.json(data) } ``` -------------------------------- ### Initialize Fumadocs App Source: https://fumadocs.vercel.app/ Command to initialize a new Fumadocs documentation project. It prompts for project name and content source. ```bash npm create fumadocs-app β—‡ Project nameβ”‚ my-appβ”‚β—† Choose a content sourceβ”‚ ● Fumadocs MDXβ”‚ β—‹ Content Collections ``` -------------------------------- ### React Server Component Example with Authentication Source: https://docs.indiekit.pro/setup/auth/user-authentication An example illustrating how to use authentication checks within React Server Components. This pattern helps in rendering content conditionally based on user authentication status. ```javascript import { getSession } from "@auth0/nextjs-auth0"; export default async function ServerSideComponent() { const session = await getSession(); if (!session || !session.user) { // Render a login prompt or redirect return

Please log in to view this content.

; } // Render authenticated content return (

Welcome, {session.user.name}!

{/* ... protected content ... */}
); } ``` -------------------------------- ### Run Authentication Setup Command Source: https://docs.indiekit.pro/setup/auth This snippet provides the command to execute for setting up authentication in Indiekit Pro LLMs. Ensure environment variables are correctly configured before running this command. ```bash Your authentication setup command here. ``` -------------------------------- ### Implementing Optimistic Updates for Instant UI Feedback Source: https://context7_llms Provides a concise example of implementing optimistic updates to make the user interface feel instantaneous. It shows the pattern of updating the UI first, then performing the asynchronous API call, and finally revalidating the data. ```tsx // Update UI first mutate('/api/todos', [...todos, newTodo], false) // Then make API call await createTodo(newTodo) // Finally revalidate mutate('/api/todos') ``` -------------------------------- ### Copy Component Example (Shell) Source: https://docs.indiekit.pro/customisation/installed-components This snippet demonstrates the shell command to copy an existing component to create a new variant. It's a foundational step for customization. ```shell # Copy an existing component cp src/components/sections/hero-1.tsx src/components/sections/hero-custom.tsx ``` -------------------------------- ### GET /api/app/org/[slug]/billing Source: https://context7_llms Fetches billing information for the authenticated organization. Requires owner privileges. ```APIDOC ## GET /api/app/org/[slug]/billing ### Description Retrieves the billing information for the specified organization. Access is restricted to organization owners. ### Method GET ### Endpoint `/api/app/org/[slug]/billing` ### Parameters #### Path Parameters - **slug** (string) - Required - The unique identifier for the organization. #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) - **Billing Information Object** (object) - Contains details about the organization's billing. ```json { "plan": { "id": "plan_premium", "name": "Premium", "codename": "premium", "default": false, "quotas": {}, "requiredCouponCount": 0 }, "paymentMethod": "credit_card", "nextBillingDate": "2024-01-01T00:00:00Z" } ``` #### Response Example ```json { "plan": { "id": "plan_premium", "name": "Premium", "codename": "premium", "default": false, "quotas": {}, "requiredCouponCount": 0 }, "paymentMethod": "credit_card", "nextBillingDate": "2024-01-01T00:00:00Z" } ``` ``` -------------------------------- ### SPF DNS Record Example Source: https://context7_llms An example of an SPF DNS TXT record, which specifies which mail servers are authorized to send emails on behalf of your domain. It helps prevent email spoofing by listing allowed IP addresses or include mechanisms. ```txt yourdomain.com TXT "v=spf1 include:_spf.google.com include:_spf.mailgun.org ~all" ``` -------------------------------- ### JavaScript: Connecting and Querying with Neon Serverless Driver Source: https://neon.tech/ This JavaScript example shows a basic connection to a Neon database using the serverless driver and executing a 'SELECT * FROM posts' query. It's a concise demonstration of client-side interaction with Neon. Replace placeholder credentials and host with your actual database connection details. ```javascript import { neon } from '@neondatabase/ serverless'; const sql = neon('postgresql:// usr:pass@proj.us-east-2.aws.neon.tech/db'); const posts = await sql('SELECT * FROM posts'); ``` -------------------------------- ### Deployment Step - Platform Specific Source: https://docs.indiekit.pro/setup/background-jobs This section outlines the third step in the deployment process: platform-specific instructions. It indicates that users should choose their hosting platform, with Vercel being the recommended option. ```HTML

Step 3: Deploy (Platform-Specific)

Choose your hosting platform:

🟒 Vercel (Recommended)

  1. ``` -------------------------------- ### TypeScript API Route Handler for GET Requests Source: https://nextjs.org/docs/app/building-your-application/routing/route-handlers This TypeScript code defines an asynchronous GET request handler for an API route. It demonstrates how to create a new Response object with a string message. This is a fundamental example for building API endpoints in Next.js. ```typescript export async function GET(request: Request) { return new Response('Hello, Next.js!') } ``` -------------------------------- ### Python LLM API Call Example Source: https://coolors.co/ This Python code illustrates how to make a request to an LLM API using the 'openai' library. It includes setting up the API key, defining the prompt, and handling the response. Ensure you have the 'openai' library installed (`pip install openai`). ```python import os import openai openai.api_key = os.getenv("OPENAI_API_KEY") def get_llm_completion(prompt_text): try: response = openai.Completion.create( engine="text-davinci-003", prompt=prompt_text, max_tokens=100, n=1, stop=None, temperature=0.5 ) return response.choices[0].text.strip() except Exception as e: print(f"An error occurred: {e}") return None query = "Summarize the following article: [Article Text]" summary = get_llm_completion(query) if summary: print(f"Summary: {summary}") ``` -------------------------------- ### Customizing Components with Props Example (JavaScript) Source: https://docs.indiekit.pro/customisation/installed-components Illustrates how to customize components by passing props. This example shows passing a 'testimonials' array to the TestimonialGrid component. ```javascript import TestimonialGrid from "@/components/sections/testimonial-grid"; export default function AboutPage() { const testimonials = [ { name: "John Doe", role: "CEO at Company", content: "This product is amazing!", avatar: "/images/john.jpg" }, // ... more testimonials ]; return ( ); } ``` -------------------------------- ### IndieKit Pro: Example Credit Type Configuration (TypeScript) Source: https://docs.indiekit.pro/payments/credits-system This example illustrates the structure for defining a new credit type within the IndieKit Pro configuration. It guides developers on how to specify the name and potentially other attributes of a purchasable LLM service. ```typescript Example: ``` -------------------------------- ### Clone Indie Kit Repository Source: https://docs.indiekit.pro/getting-started This command clones the main Indie Kit repository to your local machine. Ensure you have Git installed. ```bash git clone https://github.com/Indie-Kit/indie-kit cd indie-kit ``` -------------------------------- ### GET /api/app/org/[slug]/projects Source: https://context7_llms Fetches project data associated with a specific organization. Requires organization authentication. ```APIDOC ## GET /api/app/org/[slug]/projects ### Description Fetches a list of projects belonging to the authenticated organization. ### Method GET ### Endpoint `/api/app/org/[slug]/projects` ### Parameters #### Path Parameters - **slug** (string) - Required - The unique identifier for the organization. #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) - **Array of Project Objects** (object[]) - An array containing project details. ```json [ { "id": "proj_123", "organizationId": "org_abc", "name": "My Project", "createdBy": "user_xyz", "createdAt": "2023-10-27T10:00:00Z", "updatedAt": "2023-10-27T10:00:00Z" } ] ``` #### Response Example ```json [ { "id": "proj_123", "organizationId": "org_abc", "name": "My Project", "createdBy": "user_xyz", "createdAt": "2023-10-27T10:00:00Z", "updatedAt": "2023-10-27T10:00:00Z" } ] ``` ``` -------------------------------- ### GET /api/app/org/[slug]/projects Source: https://context7_llms Retrieves a list of projects associated with a specific organization. Accessible to any member of the organization. ```APIDOC ## GET /api/app/org/[slug]/projects ### Description Retrieves a list of projects belonging to the organization. Any member of the organization can access this endpoint. ### Method GET ### Endpoint `/api/app/org/[slug]/projects` ### Parameters #### Path Parameters - **slug** (string) - Required - The unique identifier of the organization. #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) - **projects** (array) - A list of project objects associated with the organization. #### Response Example ```json [ { "id": "proj_123", "name": "Project Alpha" }, { "id": "proj_456", "name": "Project Beta" } ] ``` ``` -------------------------------- ### Local Setup Verification Steps Source: https://docs.indiekit.pro/setup/auth/google-login Steps to verify the local setup of Indiekit Pro. This involves accessing the local URL, clicking the 'Continue with Google' button, and confirming successful sign-in. ```text Visit http://localhost:3000/sign-in Click "Continue with Google" You should be able to sign in ```