Student Database

Just POST to save JSON and GET to retrieve. No login, no complexity. Perfect for students learning programming.

Quick Start

1 Create your first document

POST a JSON document to create a database. The database is created automatically on first request!

const response = await fetch('https://tinkr.ee/sdb/my_database', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ name: 'John', age: 25 })
});
const data = await response.json();
console.log(data); // {"id": "...", "name": "John", "age": 25}

2 Retrieve all documents

GET all documents from your database as a JSON array

const response = await fetch('https://tinkr.ee/sdb/my_database');
const documents = await response.json();
console.log(documents); // Array of all documents

3 Update a document

PATCH a document by its ID to update it

const docId = '550e8400-e29b-41d4-a716-446655440000';
const response = await fetch(`https://tinkr.ee/sdb/my_database/${docId}`, {
method: 'PATCH',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ name: 'Jane', age: 26 })
});
const updated = await response.json();

4 Delete a document

DELETE a document by its ID

const docId = '550e8400-e29b-41d4-a716-446655440000';
await fetch(`https://tinkr.ee/sdb/my_database/${docId}`, {
method: 'DELETE'
});

5 Polling for new documents

Use the since parameter to fetch only documents created after a specific ID

const lastId = '550e8400-e29b-41d4-a716-446655440000';
const response = await fetch(`https://tinkr.ee/sdb/my_database?since=${lastId}`);
const newDocuments = await response.json();

API Reference

Method Endpoint Description
POST /sdb/:db_name Create a document (creates database on first request)
GET /sdb/:db_name Get all documents
GET /sdb/:db_name?since=:id Get documents created after the given ID
PATCH /sdb/:db_name/:id Update a document by ID
DELETE /sdb/:db_name/:id Delete a document by ID

Namespaced Databases

Registered users can create persistent databases with namespaces. Just add the namespace before the database name:

POST /sdb/:namespace/:db_name
GET /sdb/:namespace/:db_name
PATCH /sdb/:namespace/:db_name/:id
DELETE /sdb/:namespace/:db_name/:id

Important Notes

Choose Any Database Name

Just pick any name you want for your database in the URL: my_todos, game_scores, chat_messages - anything! The database is created automatically when you POST to it for the first time.

Anonymous databases expire after 24 hours

If you need persistent storage, register for free and create a namespaced database.

Default Limits

  • Maximum 500 documents per database (oldest deleted when exceeded)
  • Maximum 10KB per document
  • 1 request per second rate limit

Security

By default, all operations are public. Registered users can enable API key authentication and configure permissions per database in the settings.

Planned Features

Features we're planning to add for registered users:

Persistent Databases

Create databases that never expire

API Key Authentication

Protect your database with private mode

Custom Limits

Configure row limits, rate limits, and document size

Schema Validation

Enforce structure for your documents

Granular Permissions

Control CRUD operations independently

Security Settings

HTML sanitization, HTTPS enforcement, and more

Perfect For

Learning Projects

Practice building web apps without setting up a backend

Prototypes

Quickly test ideas and build proof-of-concepts

Student Projects

Perfect for classroom assignments and coding bootcamps

CodePen/JSFiddle

Add real database functionality to your demos

Hackathons

Get started fast without backend setup

Data Collection

Simple forms and surveys for small projects