Full Interactive API Sandbox

API Playground & Sandbox

Execute live REST endpoints, inspect HTTP wire bytes, and observe database execution in real time.

Live Server Connected
Filter:
Protocol Basics
Live API

1. Request Anatomy Inspector

Intercepts your raw HTTP byte stream and echoes back every parsed header, query param, body field, and client IP.

Headers:Content-Type: application/jsonX-First-Principles-Client: WebPlayground/1.0X-Student-Goal: MasteringBackendArchitecture
Request Body (JSON Payload)Valid JSON
Status Codes
Live API

2. Status Code Matrix

Returns realistic HTTP responses for standard status codes across 2xx, 3xx, 4xx, and 5xx families.

Security & Browsers
Live API

3. CORS Flow & Preflight Inspector

Toggle Access-Control headers to simulate allowed vs blocked cross-origin requests and watch OPTIONS preflight handshakes.

Headers:Content-Type: application/jsonX-First-Principles-Auth: session-token-preflight-abc123
Request Body (JSON Payload)Valid JSON
Performance
Live API

4. HTTP Caching & 304 Validation

Serves ETag and Cache-Control headers. Repeat GET with If-None-Match to witness a 304 Not Modified 0-byte transfer.

Headers:If-None-Match: W/"f9a8b7c6d5e4"
HTTP Standards
Live API

5. Content Negotiation Engine

Test how server adapts its response MIME format and language based on client Accept and Accept-Language headers.

Headers:Accept: application/jsonAccept-Language: en
Performance
Live API

6. Payload Compression (Gzip)

Fetches a large 300-record dataset with gzip compression active vs disabled to measure transfer size shrink (~85% savings).

Data Transfer
Live API

7. Multipart Form-Data Upload

Transmits binary file metadata and text fields separated by RFC multipart boundary delimiters.

Request Body (JSON Payload)Valid JSON
Real-Time Protocols
Live API

8. Chunked Streaming & SSE

Opens a persistent HTTP socket connection with Transfer-Encoding: chunked and watches Server-Sent Events arrive live.

API Design & State
Live API

9. Idempotency & Safe Methods

Fires GET, POST, PUT, and DELETE to observe which methods alter state upon repetition vs which guarantee identical end state.

Headers:Content-Type: application/json
Request Body (JSON Payload)Valid JSON
Routing
Live API

10. Static Routing (GET vs POST)

Demonstrates static route mapping where the same fixed path serves different handlers based on the HTTP method.

Headers:Content-Type: application/json
Routing
Live API

11. Dynamic Path Parameters (:id)

Extracts dynamic entity identifiers from path slots (:id) to perform database record lookups.

Routing
Live API

12. Query Parameters & Search

Transmits non-semantic filtering and search criteria using key-value pairs after the ? delimiter.

Routing
Live API

13. Pagination Data Contracts

Slices large datasets into pages with metadata (currentPage, limit, totalPages, totalRecords).

Routing
Live API

14. Nested Entity Routes

Expresses parent-child domain hierarchies (User #123 ➔ Post #456) in clean REST paths.

Routing
Live API

15. Route Versioning (v1 Legacy)

Serves legacy contract format with name field for older client applications.

Routing
Live API

16. Route Versioning (v2 Breaking Schema)

Serves modern schema with title, currency, and SKU fields without breaking v1 clients.

Serialization
Live API

17. JSON Wire Serialization & Parsing

Sends a structured JSON payload, inspects server-side deserialization into memory, and observes re-serialized JSON response.

Headers:Content-Type: application/json
Request Body (JSON Payload)Valid JSON
Serialization
Live API

18. Format Comparison: JSON vs YAML vs XML vs Protobuf

Compares text-based formats (JSON, YAML, XML) with binary wire formats (Protobuf) showing byte compactness and parsing differences.

Headers:Content-Type: application/json
Request Body (JSON Payload)Valid JSON
Authentication
Live API

19. Login & Token Issuer (JWT vs Session)

Simulates secure credential verification with constant-time timing protection, generic error responses, and dual issuance of stateless JWT and stateful Session ID.

Headers:Content-Type: application/json
Request Body (JSON Payload)Valid JSON
Authentication
Live API

20. Stateless JWT Signature Verification

Cryptographically verifies the HMAC-SHA256 signature and decodes token claims in memory without requiring any database lookups.

Headers:Content-Type: application/json
Request Body (JSON Payload)Valid JSON
Authorization
Live API

21. Role-Based Access Control (RBAC Guard)

Enforces permission boundaries across viewer, editor, and admin roles, differentiating 401 Unauthorized from 403 Forbidden.

Headers:Content-Type: application/json
Request Body (JSON Payload)Valid JSON
Validation
Live API

22. Multi-Layer Validation Pipeline (Type, Syntactic, Semantic, Complex)

Tests incoming request payloads against Type, Syntactic (email/phone), Semantic (DOB/age range), and Complex (password match, conditional partner) rules before service execution.

Headers:Content-Type: application/json
Request Body (JSON Payload)Valid JSON
Validation
Live API

23. Transformation & Type Casting Pipeline

Casts raw query string parameters to typed integers, trims and lowercases email strings, and normalizes phone numbers into E.164 format before reaching the service layer.

Headers:Content-Type: application/json
Request Body (JSON Payload)Valid JSON
Architecture
Live API

24. 3-Layer Architecture & Middleware Pipeline Trace

Traces the exact flow of an incoming HTTP request through Ingress Middleware, Request Context injection, Controller input validation, HTTP-agnostic Service orchestration, and Repository database persistence.

Headers:Content-Type: application/jsonX-Request-ID: req_firstprinciples_777
Request Body (JSON Payload)Valid JSON
Architecture
Live API

25. Request Context & Anti-Spoofing Security

Compares insecure client-supplied request body user IDs against cryptographically verified identity claims stored in per-request Context.

Headers:Content-Type: application/json
Request Body (JSON Payload)Valid JSON
API Design
Live API

26. REST CRUD with Sane Defaults, Pagination & Sorting

Demonstrates professional REST resource collections (/projects) with automatic fallback sane defaults (page=1, limit=10), status filtering, and sorting.

Headers:Accept: application/json
API Design
Live API

27. Non-CRUD Custom Action & PUT vs PATCH Semantics

Executes a custom business action (POST /projects/:id/clone) that falls outside standard CRUD, creating a duplicated resource draft.

Headers:Content-Type: application/json
Request Body (JSON Payload)Valid JSON
Databases & Storage
Live API

28. B-Tree Index Scan vs Full Table Scan Benchmark

Simulates querying 1,000,000 PostgreSQL rows with B-Tree Index (O(log N)) vs sequential scan (O(N)), returning EXPLAIN ANALYZE and buffer page I/O metrics.

Headers:Content-Type: application/json
Request Body (JSON Payload)Valid JSON
Databases & Security
Live API

29. SQL Injection vs Parameterized Prepared Statements

Compares raw string concatenation vulnerability against parameterized queries ($1), showing how prepared statements isolate user input from executable bytecode.

Headers:Content-Type: application/json
Request Body (JSON Payload)Valid JSON
Databases & API Patterns
Live API

30. Deterministic LIMIT & OFFSET Database Pagination

Demonstrates safe SQL pagination using ORDER BY, LIMIT, and OFFSET with full pagination metadata (page, limit, totalPages, hasNextPage).

Headers:Accept: application/json