create-split
v0.1.2
Published
CLI tool to connect Next.js sites to Split AI content delivery system
Readme
create-split
Connect your Next.js site to Split's AI content delivery system
This CLI tool configures your Next.js project to receive AI-generated content from Split, the AI content delivery platform designed for Next.js sites.
Installation & Usage
You can use this tool directly with npx:
npx create-splitThis will:
- Install a webhook endpoint in your Next.js project
- Set up the necessary environment variables
- Create content directories
- Update your sitemap.xml and llms.txt files
- Register your site with Split
Prerequisites
- A Next.js project
- Credentials from your Split dashboard
How it Works
Split delivers AI-generated content to your site through a secure webhook. This CLI tool configures your Next.js project to:
- Accept content through a secure webhook endpoint
- Store content in a designated directory
- Make content discoverable to search engines and LLMs
API Credentials
You'll need to generate API credentials from your Split dashboard. These consist of:
SPLIT_AGENT_ID: A unique identifier for your siteSPLIT_AGENT_SECRET: A secret key used to verify webhook requests
Manual Setup
If you prefer to set things up manually:
Add your credentials to
.env.local:SPLIT_AGENT_ID=your_agent_id SPLIT_AGENT_SECRET=your_agent_secretCreate an API endpoint at
/api/split-agentin your Next.js projectCreate a content directory for AI-generated content
Update your sitemap.xml to include Split content
License
MIT
