Skip to content

Latest commit

 

History

4 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 

Repository files navigation

SCM API Documentation for AI LLMs

Complete API documentation for SEO Content Machine (SCM), optimized for consumption by AI language models.

πŸš€ Quick Start

The SCM API runs on http://localhost:8008 by default and provides endpoints for content creation, task management, and AI-powered writing tools.

Basic Usage

// Test API connectivity
fetch('http://localhost:8008/test')
  .then(r => r.json())
  .then(data => console.log(data));

// Get available AI services
fetch('http://localhost:8008/ai-services')
  .then(r => r.json())
  .then(data => console.log(data.result));

πŸ“– Documentation Files

  • scm-api-docs-for-ai.json - Complete API specification optimized for AI parsing
  • README.md - This overview file
  • docs/index.html - Interactive web interface (when hosted on GitHub Pages)

πŸ”‘ Authentication

Most endpoints are public, but blog management requires an API key:

const response = await fetch('http://localhost:8008/blog-settings?apikey=YOUR_API_KEY');

🎯 Key Endpoints

Task Management

  • GET /task/find/ - Find and filter tasks
  • POST /task/data/:id - Update task configuration
  • GET /task/run/:id - Start a task
  • GET /task/status/:id - Check task status

Content Creation

  • GET /create/articlecreator - Create article writing task
  • POST /spin - Spin/rewrite text content
  • GET /ai-services - List available AI services

Content Access

  • GET /task/cache/:id - Get cached scraped content
  • GET /task/content/:id/* - Access generated content files

πŸ“‹ Task Types

SCM supports 17 different task types:

  • Article Creator - Generate articles from keywords
  • Writing Assistant - AI-powered content writing
  • Google Scraper - Search result scraping
  • Web Scraper - Website content extraction
  • Post Uploader - Automated content publishing
  • And 12 more specialized tools

πŸ”§ Usage Examples

Create and Run Article Task

// 1. Create task
const createResponse = await fetch('http://localhost:8008/create/articlecreator');
const {id, data} = await createResponse.json();

// 2. Update settings
const updateData = {
  articleKeywordsFile: ["coffee recipes", "espresso tips"],
  aiWriterArticleCount: 5,
  articleCombinationType: "one keyword"
};

await fetch(`http://localhost:8008/task/data/${id}`, {
  method: 'POST',
  headers: {'Content-Type': 'application/json'},
  body: JSON.stringify(updateData)
});

// 3. Run task
await fetch(`http://localhost:8008/task/run/${id}`);

Batch Operations

// Find all article creator tasks
const tasks = await fetch('http://localhost:8008/task/find/?type=article%20creator')
  .then(r => r.json())
  .then(data => data.result);

// Update all tasks
for (const task of tasks) {
  await fetch(`http://localhost:8008/task/data/${task._id}`, {
    method: 'POST',
    headers: {'Content-Type': 'application/json'},
    body: JSON.stringify({aiWriterArticleCount: 10})
  });
}

πŸ€– AI Integration

This documentation is specifically formatted for AI language models to:

  • Parse endpoint specifications easily
  • Understand parameter requirements and types
  • Generate correct API calls with proper formatting
  • Handle authentication appropriately
  • Process responses and error conditions

AI-Friendly Features

  • Structured JSON format for machine parsing
  • Detailed parameter descriptions with types and constraints
  • Complete request/response examples
  • Error handling patterns
  • Task configuration schemas

πŸ“š Full API Reference

For complete endpoint documentation, see scm-api-docs-for-ai.json which contains:

  • All 25+ API endpoints with full specifications
  • Authentication requirements for each endpoint
  • Parameter schemas with validation rules
  • Response formats and examples
  • Error response patterns
  • Task type definitions and settings
  • Complete task parameter configurations - detailed parameters for all 17 task types including 50+ settings for article creator tasks

πŸš€ Getting Started with AI

  1. Download scm-api-docs-for-ai.json
  2. Attach the JSON file to your AI chat interface so it understands available endpoints
  3. Test basic endpoints like /test and /ai-services
  4. Experiment with task creation and management endpoints
  5. Integrate SCM API calls into your AI-powered workflows

πŸ“‹ Requirements

  • SCM (SEO Content Machine) running locally
  • API server accessible at http://localhost:8008
  • Optional: API key for blog management features

πŸ”— Links

πŸ“„ License

This documentation is provided for educational and integration purposes. Please refer to SCM's licensing terms for commercial use.

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors