blog-in

A complete blog engine for portfolio builders fast and easy to use

blog-in

  • blog-in is the solution aiming to reduce devs stress of having to rewrite codes in creating blogs site

i will try to make this readme as short as possible

installation

$ curl -sSL "https://raw.githubusercontent.com/slick-lab/blog-in/refs/heads/main/install.sh" | bash

this will install and run the install script after sucessfull installation you will get the pure binary file the run with

$ ./blog-in

you will get your admin token on first run and will alos be available to view at admin.token it should be used when sending request for admin actions to be included in x-api-key


Endpoints

  1. GET /posts
  • lists all blogs

how it works

  • Reads all .md files frok posts/ folder
  • returns filename as slug
  • returns file stats (created date, size)

response

[
  {
      "slug": "hello-word",
      "created": "2026-2815....",
      "size": "1240"
  }
]
  1. GET /posts/:slug
  • gets a single posts

how it works

lets assume slug is hello-word.md

  • looks for posts/hello-word.md
  • if exit -> reads file content
  • retuns raw markdown

response

[ 
    {
        "slug": "hello-word",
        "content": "markdownhere...",
        "version": "0.1.0"

    }
]
  1. GET /search?/q=query
  • searches for posts

how it works

  • loops through all .md files
  • searches in filename and content
  • returns matches with excerpts

response

[
    {
        "slug": "dart-post",
        "title": "DART-POST",
        "created": "2026.....",
        "excerpt": "this is about dart..
    }
]

admin Endpoints

( to be used with X-API-KEY)

  1. POST /admin/posts
  • creates new posts

headers

X-API-KEY: ink_......
Content-Type: application/json

note : all request should follow this format unless stated otherwise

Body

{
    "slug": "my-new-post",
    "content": "markdownhere"
}
  • will return 409 if slug exits
  1. PUT /admin/posts/:slug
  • updates an existing post overrides
  1. DELETE /admin/posts/:slug
  • deletes a post

my aim is to keep this as short as possible

Auth system

  • generates random token
  • saves to admin.token
  • prints the token
  • only works on first run
Repository

blog-in

Owner
Statistic
  • 1
  • 0
  • 0
  • 0
  • 1
  • about 3 hours ago
  • April 6, 2026
License

MIT License

Links
Synced at

Mon, 06 Apr 2026 18:50:23 GMT

Languages