SOHTTP
SOHTTP: Because Returning JSON is So Mainstream
SQL Over HTTP — No-Bullshit Raw Data Access, Still Runs on PHP
Welcome to SOHTTP, the minimalist data-access revolution where we throw REST conventions out the window and let SQL speak for itself — over HTTP. That’s right. SQL Over HTTP, powered by PHP, served with a touch of rebellion and a dash of raw efficiency.
What is SOHTTP?
SOHTTP (SQL Over HTTP) is a PHP-based web application that lets you send raw SQL queries via standard HTTP requests and get the results directly — raw, consistent, and precise.
Think of it as a cross between:
- An ad-hoc data faucet
- A developer’s dream tool
- And a security engineer’s worst nightmare
Perfect.
Why SOHTTP? Why Now?
Because we’re tired of:
- Bloated APIs that return a paginated mess of "data" nested under "meta" and "links" and "why-am-I-here" keys.
- SDKs that require OAuth tokens, rate limits, and hand-holding just to get the user_id.
SOHTTP cuts through the fluff. It’s the Unix philosophy in web form:
Do one thing well — let people query their damn data.
How It Works
1. Define Your Data
Use any standard SQL-compatible RDBMS: MySQL, PostgreSQL, SQLite. If it can speak SQL, it can be SOHTTP’d.
2. Expose via PHP
Deploy SOHTTP to your web server. Point it to your database. Expose it through Apache, NGINX, or PHP’s built-in development server. HTTPS is supported.
3. Query via HTTP
Send a raw SQL query in an HTTP request:
GET /sohttp.php?query=SELECT+*+FROM+users+WHERE+active=1
Get back raw, tabular output, CSV, or optionally JSON.
Security Features (We Swear, It Exists)
- HTTP Basic Auth support
- Read-only mode to restrict damage
- Query allowlisting and blocklisting options
Why It’s Better Than Traditional APIs
Feature | REST API | SOHTTP |
---|---|---|
Data format | Varies wildly | Raw SQL output or CSV |
Authentication | OAuth, JWT | HTTP Basic |
Flexibility | Predefined endpoints | Any valid SQL query |
Integration speed | Medium-slow | Extremely fast |
Error handling | Abstracted or vague | It’s your query, your error |
Use Cases
- Internal tooling
- Data scientists needing quick access to relational data
- DevOps who prefer curl over Swagger
- Power spreadsheet users
- That one guy in accounting who still uses MS Access
Legal & Moral Disclaimer
SOHTTP is released under the MIT License.
Do what you want, just don’t blame us when your VPS gets breached harder than a WordPress login page from 2006.
Important Notices:
- Do not expose SOHTTP to the public internet without authentication or VPN.
- Do not use root credentials with SOHTTP.
- Do not name your database "sus.db".
This configuration is, by all standards, highly sussus amongus.
The Future Is Raw
Forget REST. Forget GraphQL. Forget XML-RPC. With SOHTTP, the data flows unfiltered from SQL to your screen with nothing but HTTP in between.
No JSON bloat. No SDKs. Just pure, unapologetic access.
Because at the end of the day, all your fancy APIs boil down to:
SELECT * FROM stuff WHERE you_could_have_just_let_me_query_it;
So install SOHTTP. Lock it down. And for the love of George Bush, don't run it as root.
With great SQL comes great responsibility.