Guide
Generate test data from a SQL schema
Paste your CREATE TABLE statements and get realistic rows for every table, with foreign keys that point at real rows and values that agree with each other. Free, no sign-up.
1. Send your schema
Paste it into the generator (the "Your schema" tab), or call the API. No key is needed:
curl -X POST https://api.boxai.dev/api/generate/schema \
-H "Content-Type: application/json" \
-d '{
"ddl": "CREATE TABLE customers (id SERIAL PRIMARY KEY, full_name TEXT, email TEXT UNIQUE, country TEXT);
CREATE TABLE orders (id SERIAL PRIMARY KEY, customer_id INT REFERENCES customers(id),
quantity INT, unit_price NUMERIC(10,2), total NUMERIC(10,2),
status TEXT CHECK (status IN ('pending','shipped','delivered')), created_at TIMESTAMP, shipped_at TIMESTAMP)",
"rows": 100,
"format": "sql",
"seed": "my-test"
}' -o seed.sql
Postgres, MySQL and SQLite syntax all work. Tables are filled parents first, so the SQL loads in order.
2. What you get
- Values from column names and types.
email,phone,country,price,status,created_at,latency_ms,temperature_c,ibanand hundreds more get values of the right shape and a believable range. - Your constraints.
CHECK (x IN (...))lists,UNIQUE,NOT NULLand primary keys are respected. - Links. Every foreign key points at a real parent row; two links to the same table in one row point at different rows.
- Rows that agree with themselves.
totalis quantity × unit price, an order is shipped after it is created and has no shipped date while pending, ages match dates of birth.
3. Pick a format
"format": "json" (one object with a list per table), "csv" (a zip with one file per table) or "sql" (INSERT statements; add "dialect": "mysql" for MySQL). Add "locale": "global" for names, phones and IBANs from 16 countries, or leave the default for UAE formats.
4. The same data every time
Every response carries its seed and as_of date. Send them again and you get exactly the same rows, ids included, so a failing test can be repeated exactly.
No schema yet?
Describe what you are testing in plain English or Arabic ("a clinic with patients, doctors and appointments") in the generator's "Describe it" tab. AI writes the schema, BoxAI fills it, and you get both, with a diagram of the tables.
Limits
Free: up to 200 rows per table and 12,000 values per request, rate-limited per IP. With a Pro or Team key the generator uses your plan's limits, from CI too.