Skip to content

Free, Fast & Simple REST API Base Template | AI Integration | Canvas Generation | Auto Swagger Docs | Perfect Starter Kit for Node.js APIs

Notifications You must be signed in to change notification settings

ditss-cloud/sh-api-simple

Β 
Β 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

9 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🌸 Shiina API

Shiina API Banner

A free, simple and elegant REST API created by balxzzy for the common good

Version Status Node.js License

The Ultimate Free Node.js REST API Starter Kit πŸš€

Perfect base template for building powerful APIs with AI integration, canvas generation, and auto-documentation.

Why Choose Shiina API Base?

βœ… 100% Free & Open Source
βœ… Production Ready
βœ… AI Integration Built-in
βœ… Auto Swagger Documentation
βœ… Canvas & Image Generation
βœ… Hot Reload Development
βœ… Zero Configuration Setup


✨ Features

  • πŸ€– AI Integration - Powered by LuminAI for smart responses
  • 🎨 Canvas Generation - Create beautiful ship cards and graphics
  • πŸ› οΈ Tools & Utilities - Various helpful tools and generators
  • πŸ“š Auto Documentation - Swagger JSON generation
  • πŸ”„ Hot Reload - Automatic updates with nodemon
  • 🌐 RESTful API - Clean and simple endpoints

πŸš€ Quick Start

Prerequisites

  • Node.js 18+
  • npm or yarn package manager

Installation

# Clone the repository
git clone https://github.com/balxz/sh-api-simple.git

# Navigate to project directory
cd sh-api-simple

# Install dependencies
npm install

# Start development server
node index.js # node .

Usage

# Production mode
npm start

# Development mode with hot reload
npm run dev

The API will be available at http://localhost:3000

πŸ“ Project Structure

shiina-api/
β”œβ”€β”€ πŸ“„ configs.js          # Global configuration and setup
β”œβ”€β”€ πŸ“„ index.js            # Main application entry point
β”œβ”€β”€ πŸ“„ nodemon.json        # Nodemon configuration
β”œβ”€β”€ πŸ“„ package.json        # Package dependencies
β”œβ”€β”€ πŸ“‚ route/              # API route definitions
β”‚   β”œβ”€β”€ πŸ“‚ ai/             # AI-related endpoints
β”‚   β”‚   └── lumini-ai.js   # LuminAI integration
β”‚   β”œβ”€β”€ πŸ“‚ canvas/         # Image generation endpoints
β”‚   β”‚   └── ship.js        # Ship card generator
β”‚   β”œβ”€β”€ πŸ“‚ ex/             # Example endpoints
β”‚   β”‚   └── example.js     # API usage examples
β”‚   β”œβ”€β”€ πŸ“„ index.js        # Route index
β”‚   └── πŸ“‚ user/           # User-related endpoints
β”‚       └── say.js         # Text generation tools
└── πŸ“‚ src/                # Source code directory
    β”œβ”€β”€ πŸ“‚ lib/            # Library modules
    β”‚   β”œβ”€β”€ πŸ“‚ loader/     # Dynamic loaders
    β”‚   β”‚   β”œβ”€β”€ docs.js    # Documentation generator
    β”‚   β”‚   β”œβ”€β”€ router.js  # Route loader
    β”‚   β”‚   └── scrap.js   # Scraper loader
    β”‚   └── πŸ“‚ scraper/    # Web scraping modules
    β”‚       └── πŸ“‚ ai/
    β”‚           └── aites.js # AI scraping utilities
    └── πŸ“‚ pages/          # Static pages
        β”œβ”€β”€ πŸ“‚ 404/        # 404 error page
        β”œβ”€β”€ πŸ“„ index.html  # Landing page
        β”œβ”€β”€ πŸ“‚ maintenance/ # Maintenance page
        └── πŸ“‚ sh/         # Special pages

πŸ”— API Endpoints

πŸ€– AI Services

  • GET /api/ai - LuminAI chat completion
    • Parameters: text (required)
    • Example: /api/ai?text=hello ai!

🎨 Canvas Generation

  • GET /api/canvas/welcome - Generate ship cards
    • Description: Create beautiful welcome cards

πŸ› οΈ Tools & Utilities

  • GET /api/tools/generate - Text generation tool
    • Parameters: text, url, size, nama
    • Example: /api/tools/generate?text=hello&nama=shiina

πŸ“š Examples

  • GET /example - Basic API example
    • Returns sample response structure

πŸ”§ Configuration

Environment Setup

The API uses global configuration defined in configs.js:

const SH = () => ({
    name: "SH - API",
    version: "1.0.0",
    description: "SHIINA is a free, simple REST API...",
    banner: "https://files.catbox.moe/mbeerk.jpg",
    status: "online",
    creator: "balxzzy"
})

Route Structure

Each route follows this standard format:

module.exports = {
    name: "route-name",
    path: "/api/endpoint",
    type: "get", // or "post",
    description: "Route description",
    tags: "category",
    hidden: false,
    isDisable: false,
    params: {
        // Required parameters
    },
    code: async (req, res, { axios, scrap }) => {
        // Route logic here
    }
}

πŸ“– Auto Documentation

The API automatically generates Swagger JSON documentation with:

  • Complete endpoint listing
  • Parameter specifications
  • Response examples
  • Category organization
  • Real-time status updates

Access the documentation at http://localhost:3000/ endpoint.

πŸ›‘οΈ Security & Usage

  • Rate Limiting: Please avoid DDoS attacks
  • Free Usage: Available for everyone
  • Attribution: Created by balxzzy
  • Support: Contact pa424013@gmail.com

🀝 Contributing

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

πŸ“ License

This project is licensed under the MIT License - see the LICENSE file for details.

πŸ“ž Contact & Support


Made with ❀️ by Shiina Team

Feel free to use it, but please use it responsibly!

Footer Image

About

Free, Fast & Simple REST API Base Template | AI Integration | Canvas Generation | Auto Swagger Docs | Perfect Starter Kit for Node.js APIs

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • JavaScript 69.6%
  • HTML 23.6%
  • CSS 6.8%