โจ Welcome to Devscribe โ Your Smart Developer Document Editor
Devscribe is a next-generation document editor designed for developers, architects, and educators.
It merges code execution, visual diagramming, and API documentation into a single elegant workspace.
console.log("๐ Welcome to Devscribe JS Runner!");
function add(a, b) {
return a + b;
}
console.log("Sum of 5 + 10 =", add(5, 10));
๐ Welcome to Devscribe JS Runner!
Sum of 5 + 10 = 15
Perfect for teaching snippets, testing logic, or sharing live examples.
๐ฉต TypeScript Example
console.log("๐ Welcome to Devscribe TypeScript Runner!");
type Product = { id: number; name: string; price: number };
function getDiscountedPrice(p: Product, discount: number): number {
return p.price - (p.price * discount) / 100;
}
const product: Product = { id: 1, name: "MacBook Air", price: 1200 };
console.log(getDiscountedPrice(product, 10));
โ Output:
๐ Welcome to Devscribe TypeScript Runner!
1080
You can mix JS and TS blocks seamlessly to show code evolution.
class Fibonacci {
public static void main(String[] args) {
int n = 8, t1 = 0, t2 = 1;
System.out.print("Fibonacci: ");
for (int i = 1; i <= n; ++i) {
System.out.print(t1 + " ");
int sum = t1 + t2;
t1 = t2;
t2 = sum;
}
}
}
โ Output:
Fibonacci: 0 1 1 2 3 5 8 13
๐งฎ SQL (MySQL – Sakila Database Example)
Devscribe comes preconfigured with the Sakila demo DB โ perfect for practicing SQL queries.
SELECT
c.customer_id,
CONCAT(c.first_name, ' ', c.last_name) AS customer_name,
c.email,
COUNT(r.rental_id) AS total_rentals,
SUM(p.amount) AS total_amount_spent,
cat.name AS favorite_category,
MAX(r.rental_date) AS last_rental_date
FROM customer c
JOIN rental r ON c.customer_id = r.customer_id
JOIN payment p ON r.rental_id = p.rental_id
JOIN inventory i ON r.inventory_id = i.inventory_id
JOIN film f ON i.film_id = f.film_id
JOIN film_category fc ON f.film_id = fc.film_id
JOIN category cat ON fc.category_id = cat.category_id
WHERE c.active = 1
GROUP BY c.customer_id, cat.name
HAVING SUM(p.amount) > 0
ORDER BY total_amount_spent DESC
LIMIT 5;
id
name
department
1
Alice
Engineering
2
Bob
Finance
๐ SQLite Example
๐งฑ Step 1: Create the Table
CREATE TABLE employees (
id INTEGER PRIMARY KEY,
name TEXT,
department TEXT
);
This creates an employees table with three columns โ id, name, and department.
๐งฉ Step 2: Insert Sample Data
INSERT INTO employees (name, department)
VALUES ('Alice', 'Engineering'), ('Bob', 'Finance');
This inserts two records into the table.
id
name
department
1
Alice
Engineering
2
Bob
Finance
๐ก Tip:
In Devscribe, you can run each block separately to see live results โ and toggle between JSON view and Table view using the table icon in the console output area.
๐งโโ๏ธ Users
๐ Orders
๐ฆ Products
๐งพ OrderItems
Relationships:
Users (1) โ Orders (M)
Orders (1) โ OrderItems (M)
Products (1) โ OrderItems (M)
Diagramly Visualization:
๐ก You can export this diagram as an image and embed it anywhere in your document.
Document and test APIs directly within your document โ no Postman or other tools needed.
Devscribe lets you execute real requests, view formatted JSON, and even define reusable environment variables.
โถ๏ธ Watch the full walkthrough to get started with API execution in Devscribe.
Devscribe supports one environment variable per file, called @baseurl.
It allows you to define a single base API URL once and reuse it across all your requests โ perfect for switching between development, staging, and production environments.
๐ก Example:
โ Devscribe automatically adds the base URL and runs it as:
You donโt need to use placeholders like {{baseUrl}}.
Just set baseUrl once โ Devscribe handles the rest.
๐ง Example Environment Setup
โ Summary
Feature
Description
๐ @baseurl Support
Define once, used across all requests
๐ Automatic URL Handling
Devscribe prepends baseUrl to relative paths
๐ File-Specific Variable
Each document has its own baseurl setup
๐ง Simple & Clean
No extra syntax โ just one variable for all APIs
๐ก Tip: โ The @baseUrl is stored per file, so every document can have its own environment setup. โ Changing @baseUrl instantly updates all request URLs in that document.