Skip to content

germanter/apiEngine

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

56 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸš€ API Engine

A minimal, automated engine that collects, validates, and serves public API data - all in one clean JSON.


SHORT CUT API LIST URLS

api.json:

https://raw.githubusercontent.com/germanter/apiEngine/refs/heads/main/api.json

apiCmp.json:

https://raw.githubusercontent.com/germanter/apiEngine/refs/heads/main/apiCmp.json

API-Engine site:

https://api-engine.vercel.app/

πŸ“Œ Overview

API Engine is an open-source project built to solve a simple but real problem:

There is no fast, clean, and reliable way to explore modern public APIs in one place.

So this project does exactly that β€” it collects, validates, and serves API data in a structured format that works for both humans πŸ‘€ and machines πŸ€–.


🧠 Core Idea

Instead of scattered API lists across blogs, outdated repos, or broken links:

  • βœ… You get a single source of truth
  • βœ… Automatically validated endpoints
  • βœ… Continuously updated dataset
  • βœ… Dual-format JSON optimized for different use cases

πŸ“¦ Data Outputs

πŸ‘€ api.json - Human-Friendly

Readable, structured, and descriptive.

https://raw.githubusercontent.com/germanter/apiEngine/refs/heads/main/api.json

πŸ€– apiCmp.json - Machine-Optimized

Compressed version of api.json for automation and performance.

https://raw.githubusercontent.com/germanter/apiEngine/refs/heads/main/apiCmp.json
  • ~60KB β†’ 20KB
  • ~3x smaller
  • Ideal for frontend apps, bots, and fast parsing

πŸ“₯ incoming.json - Staging Layer

Temporary dataset before validation pipeline.

  • Holds freshly scraped data
  • Prevents bad data from reaching production

βš™οΈ Tech Stack

  • Python

    • httpx β†’ async requests / endpoint validation
    • playwright β†’ scraping dynamic content
  • JSON β†’ data storage & serving

  • GitHub Actions β†’ automation (cron jobs)


πŸ”„ Data Pipeline

The entire system is fully automated:

Scraper β†’ Initial Validation β†’ incoming.json
        β†’ Deep Validation β†’ api.json
        β†’ URL Ping Check (async)
        β†’ Compression β†’ apiCmp.json
        β†’ GitHub Actions β†’ Daily Run

Or visually:

[Scrape]
   ↓
[Validate (basic)]
   ↓
[incoming.json]
   ↓
[Validate (strict)]
   ↓
[api.json]
   ↓
[Ping URLs]
   ↓
[Compress]
   ↓
[apiCmp.json]

πŸ§ͺ Validation System

βœ… Multi-Layer Protection

The engine prevents bad data from corrupting the dataset:

  • Basic validation

    • JSON structure checks
    • Required fields
  • Mid-level validation

    • Duplicate detection
    • Invalid payload filtering
  • Strict validation

    • Ensures compatibility with api.json

🌐 Endpoint Status System

Every API URL is checked using an async pinger.

Status Values:

Status Meaning
ALIVE Endpoint responded successfully
DEAD Error response received
UNKNOWN Blocked or unreachable

⚠️ Real-World Notes

  • Some APIs block automated requests β†’ marked as UNKNOWN
  • Some APIs return error codes but still work in browser
  • The system avoids aggressive retries - no need to go rogue on 200+ endpoints

πŸ“Š Data Structure

Standard Format (api.json)

{
    "name": "OpenAI API",
    "desc": "Text, image, speech, embeddings models via REST API",
    "url": "https://platform.openai.com/docs/api-reference",
    "cost": "freemium",
    "auth": true,
    "category": "AI",
    "status": "ALIVE"
}

Field Explanation

Field Description
name API name
desc Short description
url Documentation / endpoint
cost Pricing model
auth true β†’ requires API key / OAuth
category API category
status Health status from pinger

⚑ Compressed Format (apiCmp.json)

Designed for speed and minimal payload size.

{
    "n": "OpenAI API",
    "d": "Text, image, speech, embeddings models via REST API",
    "u": "https://platform.openai.com/docs/api-reference",
    "m": "freemium",
    "a": true,
    "c": "AI",
    "s": 1
}

Compression Mapping

Short Full Description
n name API name
d desc Description
u url Endpoint
m cost Pricing
a auth Auth required
c category Category
s status 1 / 0 / -1

Status Encoding

Value Meaning
1 ALIVE
0 DEAD
-1 UNKNOWN

πŸ“Œ Special Note

apiCmp.json always includes:

  • A final item (x)
  • Contains distinct category list
  • Useful for frontend filtering

πŸ€– Automation

Everything runs through a single orchestrator:

runner.py

Handles:

  • Scraping
  • Validation
  • Pinging
  • Compression
  • Final output generation

⏱ GitHub Actions

  • Runs on cron schedule (daily)
  • Fully autonomous pipeline
  • Zero manual intervention required

πŸ›‘οΈ Incident Report β€” Apr 14, 8:09 AM (GMT+4)

First real failure of the automated system.

  • Scraper failed due to a bad data entry

  • BUT:

    • incoming.json β†’ safe
    • api.json β†’ untouched

πŸ’‘ Key Insight

Validation layers successfully prevented dataset corruption.

This proved that:

  • The system is resilient
  • Bad data cannot poison production JSON
  • Failures are contained and recoverable

🌍 Live Preview


🎯 Use Cases

  • πŸ” Discover APIs quickly
  • ⚑ Build tools needing API datasets
  • πŸ€– Feed bots / automation systems
  • πŸ“Š Frontend filtering via categories
  • πŸ§ͺ Testing API availability

🚧 Limitations

  • Some endpoints block automated requests
  • Some APIs return misleading status codes
  • Not all APIs guarantee long-term stability

🧩 Philosophy

This project is intentionally:

  • Simple
  • Fast
  • Practical

No over-engineering. No unnecessary complexity.

Just:

Clean data. Reliable pipeline. Useful output.


🀝 Contributing

Contributions are welcome - especially:

  • Improving validation logic
  • Enhancing scraper reliability

πŸ’¬ Final Words

This project started from a simple frustration - and turned into a fully automated API discovery engine.

If you’ve ever struggled to find reliable APIs…

This is built for you.

About

api engine that clears public APIs from multiple sources and shows

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages