Skip to content
Article App Studio — Guide
☀️ Light Clean and bright
📜 Sepia Warm and vintage
🌤️ Light Gray Subtle and neutral
🔵 Light Blue Calm and serene
🌙 Dark Easy on the eyes
🌑 Dark Gray Deep and modern
🔷 Dark Blue Professional and sleek
🌿 Forest Calm and natural

Building Apps with App Studio

1. How an app fits together

App Studio is the no-code builder inside the note editor: you add your tables or saved queries, place blocks on pages, link them, and publish. The published app opens in its own window for anyone allowed to open the project, and each person sees only the data their role allows.

The four parts of an app

PartWhat it is
Data sourceA table from one of your databases, a saved query from the query builder, or (admins only) a SQLite store. Blocks read and write through sources.
PageA tab across the top of the running app. Every app has at least one.
BlockOne piece of a page (table, list, form, chart, clock…) placed on a 12-column grid. There are 21 block types.
Pop-up formA form that opens in a window when a row button, a pick or a Button block triggers it.

This is the one idea to understand before building. Selectors are blocks where the user picks a record: Table, Cards, Board, Calendar, Timeline, Gallery, List and Dropdown. Any other block can be linked to a selector and then follows whatever is picked.

Link kindUsed byYou setEffect
Filter linkTable, Cards, Board, List, Dropdown, Calendar, Number, Chart, Timer, Add formsTheir column → my columnShows only rows where my column equals the picked record's column. Example: Customers id → Orders customer_id.
Record linkDetail, Text, Image, Edit formsJust the selectorShows or edits the picked record itself.
  • Until something is picked, a linked block shows Select a record in ….
  • Links chain (Dropdown → List → Table); changing an upper pick clears the picks below it. Linking two dropdowns gives cascading dropdowns (country → city).
  • Links can cross pages: an Open a page action passes the picked record, which the new page reads as {{page.column}}.
  • A Filter bar is a third way to narrow blocks, using the user's search text, choice, date range or yes/no.

Record blocks: picked record or first match

Detail, Text, Image and Edit forms show one record. If linked, they show the picked record. If not linked but given their own data and filters, they show the first matching row. That is how you build a "my profile" page: data = users table, filter user_uid equals {{me}}.

New records fill themselves in

When any block adds a record, it automatically fills every equals filter on the block, the link value, and (for pop-ups) the Fill from pair. A list filtered to done = 0 and owner = {{me}} therefore adds items that are not done and belong to you, with no extra setup.

Tokens

Tokens work in filter values, field defaults, "Set a field" values, rules, after-save steps and text.

TokenBecomes
{{me}}The signed-in user's key
{{today}} / {{now}}Today's date / the current date and time
{{app}}The app's name
{{user.column}}A column of the signed-in user's record (needs Signed-in user set up, section 5)
{{page.column}}A value the page was opened with (a picked record or a deep link)
{{column}}A field of the current record, in text, captions, pop-up titles, row-action labels

The key column and security

Each source needs a Key column (its primary key) to edit, delete, tick, drag on a board, link and log time. The Studio guesses it; a source with no key, or marked Read-only, hides all changing actions.

The Studio never bypasses the engine. Reads use fetchData, writes use insertMultiple / updateMultiple / deleteMultiple, and filter values are always sent as bound parameters. Role, table and sharing permissions apply exactly as elsewhere in SepoDesk. Show when rules only change what is shown; the server still decides what each user may read and change.

2. Before you start

You need an existing project in the note editor, the tables the app will use, and a user account allowed to read them. Admins and regular users can both build apps; each builder only sees the data their role allows.

  • [ ] Tables exist. App Studio uses existing tables and never creates them. Build them first in the schema builder.
  • [ ] Each table you edit has a primary key. Without one, edit, delete, tick, board drag and links are hidden.
  • [ ] Saved queries (optional) are made in the legacy query builder. Query sources can be read, updated and deleted, but not added to.
  • [ ] A users table (optional) if the app should know the signed-in user's name, role or department.
  • [ ] The deployed files match. sp-app-runtime.js and sp-app-studio.js must be replaced together; both carry KIT_VERSION (currently 2026.10.3). A mismatch shows a message naming both versions.

Where to find App Studio

Open the note editor → Projects list → click App Studio on the project's row. It opens inside the note editor, not as a separate shell app.

The Studio screen

AreaWhat it holds
Top barApp name (click to rename) · save state · ⚠ N to check · Undo / Redo · Design / Preview with desktop ▭ and phone ▯ widths · Templates · ⟲ Versions · \</> JSON · Save draft · Publish
Left panelData (+ Table, + Query), Pop-up forms (+ Pop-up), Blocks palette with a Find a block… box. Sections fold and the Studio remembers which.
CentrePage tabs with + Page, and the canvas: a 12-column grid of block tiles, or the live Preview.
Right panelSettings of whatever is selected: a block, a pop-up, or (nothing selected) the Page, App, Look and Signed-in user settings plus the To check list.

Useful shortcuts: Ctrl+Z / Ctrl+Y undo and redo (up to 60 steps). With a tile focused, Delete removes it and Alt+← / → moves it. Drag tiles to reorder them or move them into and out of Tabs blocks.

3. Build your first app, step by step

This walkthrough builds Customers & Orders in nine steps: pick a customer from a list, see their details, their orders and a total, and add orders through a pop-up. It needs two tables:

  • customers (id key, name, city, status)
  • orders (order_id key, customer_id, amount, paid, created_at)
  1. Open the Studio. Note editor → Projects → App Studio on your project. Click the app name in the top bar and rename it Customers & Orders.
  2. Add the data. Data → + Table → choose the database → click customers. Repeat for orders. Click each source and check the Key column (id, order_id); fix it if the guess is wrong.
  3. Add a list to pick customers. Click List in the palette. In the right panel set:
  • Width: ⅓
  • List: Main text name, Second line city, Badge status
  • Toolbar: tick New button
  1. Show the picked customer. With the list selected, click Detail; it links to the list automatically. Set Width ⅓ and Fields shown name, city, status.
  2. Show the customer's orders. Click Table and set Block → Data to Orders. Then:
  • Link: Only rows matching the record picked in Customers, their column id = my column customer_id
  • Columns: amount (Currency), paid (Yes / No), created_at (Date & time)
  • Sort: created_at, newest first
  • Row actions: Edit in a form and Delete
  1. Add a total. Click Number: Data Orders, Calculate Sum of amount, Prefix K . Link it to the Customers list the same way (id → customer_id).
  2. Add a pop-up for new orders. Pop-up forms → + Pop-up, then:
  • Title New order for {{name}}, Data Orders, Mode Add a record, Button text Add order
  • Fill from the clicked record: its column id → my column customer_id
  • Form fields: amount (Required), paid, created_at
  • Select the Customers list → Row actions → + Action → Open a pop-up form → choose the pop-up, label Add order
  1. Try it in Preview. Pick a customer: the detail, orders and total follow. Hover the customer, click Add order, save, and the table and total update.
  2. Publish. Press Publish (this also sets Run as → App Studio app). Close the Studio and launch the app with the project's Command ID (from Copy cmd).

Faster: Templates → Records & sub-records builds steps 3–6 for you. Choose customers as the main table and orders as the related table, then add the pop-up from step 7.

4. Reference

Every block, setting and action in App Studio, grouped as they appear in the palette and the right panel.

Data sources

  • + Table: pick a database, filter, click a table. If listing is not allowed for you, type the table name and press Enter.
  • + Query: pick a saved query from the query builder.
  • SQLite stores (admins only) appear at the end of the database list; see SQLite sources below.
  • Source settings: Name, Key column, UID column (filled by the server on new records), Max rows (default 500, maximum 5000), Read-only, the column list, Reload columns, Remove.

Blocks in the palette

GroupBlocks
DataTable, Cards, Board, Calendar, Detail, Form, Timeline, Gallery
PickersList, Dropdown, Filter bar
Numbers & chartsNumber, Chart, Timer, Progress
Layout & contentTabs, Text, Image, Clock, Button, Rich text

Click a block to add it after the selected one (or into the open tab of a selected Tabs block), or drag it exactly where you want it. Width can be ¼, ⅓, ½, ⅔, ¾ or Full; blocks wrap when a row is full and become full width on narrow windows.

Settings shared by many blocks

SectionAppears onWhat it does
BlockAllTitle, Type (switching keeps compatible settings), Data, Width, Title bar, Card background
Show whenAllShows the block only when its rules hold; Hide on small screens hides it on phones
Colour rulesTable, Cards, Board, List, Calendar, Timeline, GalleryColumn + condition + value → Green, Red, Amber, Blue, Purple, Faded, Bold or Struck through, for the row or one column
LinkAll except Tabs, Clock, ButtonFilter link or record link (section 1)
Columns / FieldsTable, Cards, Board, Detail, FormChoose, order and label fields; format as Auto, Text, Number, Currency, Percent, Date, Date & time, Yes/No, Badge, Link or Picture
SortTable, Cards, Board, List, Timeline, GalleryDefault order; users can still click table headers
FiltersData blocks, record blocks with own data, Add formsColumn + condition + value; all must match; equals values also fill new records
ToolbarSelector blocks (Print also on Detail, Number, Chart, Progress, Rich text)Search, New, Import CSV, Export CSV, Print, Reload, rows per page; needs Title bar on
Row actionsSelector blocksEdit in a form · Delete · Set a field · Open a page · Open a pop-up form · Print the record; Show only when… hides the button per row
When an item is pickedSelectorsNothing else, Open a pop-up form, or Open a page
After savingForms, pop-ups, blocks with New / EditSteps run after a save (below)

Conditions available everywhere: equals, not equal, >, ≥, <, ≤, contains, starts with, is empty, is not empty, is yes, is no.

Data and picker blocks

BlockKey settingsBehaviour
TableColumns, Sort, Rows per page, Bulk & quick edit, Groups & totalsClick a row to pick it. Bulk adds tick boxes with Delete and Set-a-field buttons. Double-click a cell to quick-edit (Enter saves, Esc cancels). Groups fold under headings with counts, subtotals and a Total row.
CardsCard title, Subtitle, BadgeUp to 4 extra fields per card
BoardLanes from, Lane orderDrag a card to another lane to change that column (needs a key)
CalendarDate, End date, Event title, Colour by, Double-click addsMonth view, Monday first; double-click a day to add an event on that date
ListMain text, Second line, Badge, Tick box, Quick add, HeightAccess-style list box; tick saves 1 / 0; quick add is type + Enter
DropdownShow column, Placeholder, Pick first automaticallyPicks one record; waits for its own link if it has one
DetailFields shownPicked record, or first match of its own data and filters
FormMode (Add / Edit), Button text, field options, Sub-form, After savingAdd clears after saving; Edit shows the picked record or first match
TimelineDate, Title, Text, BadgeActivity feed grouped by day, newest first
GalleryPicture column, Caption, Tile sizePicture tiles from links; double-click to enlarge
Filter barBlocks it filters, filtersSearch text, Choice, Date range, Number range, Yes / No; Clear resets

Numbers, charts and content blocks

BlockKey settings
NumberCount, sum, average, minimum or maximum of a column; prefix, suffix, format
ChartBars, Line (over time), Pie or Donut; Group by; Dates by day / week / month / year; Show top N
ProgressA value against a Goal (a number, a token, or the sum of a goal column), as Bar or Ring
TimerA time-log table with Start, End, Minutes and Note; Stop saves one row; survives a reload
TabsHolds any blocks, including more Tabs; only the open tab loads its data
TextText with tokens; styles Big heading, Heading, Text, Small muted, Callout
ImagePicture link or picture column; Height, Shape, Fit, Caption
Clock12-hour, Seconds, Date, Size, Time zone (e.g. Africa/Lusaka)
ButtonOpen a page, open a pop-up form (with Record from a selector), or open a link
Rich textMarkdown with tokens; never runs HTML

Numbers and charts work on the loaded rows (up to the source's Max rows) after filters and links.

Pop-up forms

SettingMeaning
TitleCan use the clicked record, e.g. Edit {{name}}
Data, ModeAdd a record or Edit a record
Button text, WidthSave button label; dialog width 320–1200 px
Fill from the clicked recordIts column → my column. Add copies the value in; Edit finds the record where my column equals it
Form fields, Filters, Sub-form, After savingAs for Form blocks
Opened from / Try itLists everything that opens this pop-up; opens it right away for testing

Open a pop-up from a row action, When an item is picked, or a Button. Deleting a pop-up removes the actions that open it.

Form field options (▸ More options)

SettingMeaning
InputAutomatic, Text, Long text, Number, Date, Date & time, Time, Yes / No switch, Choice list, Email, Phone, Link, Colour, Picture link (URL)
ChoicesFor a choice list: low, normal, high or low=Low, high=High!
DefaultA value or token for new records; filters and links still win
Placeholder, Help textHint inside the box; small text under it
Min, Max, PatternChecked before saving (pattern = regular expression)
Show names fromA lookup: shows Acme instead of 1 and turns the form field into a dropdown of names; the key is saved
Show whenShows the field only when its rules hold, e.g. Reason only when status equals rejected; hidden fields are not saved

Pictures are always links (https://… or /uploads/…); App Studio has no file uploads.

After saving

StepDoes
Show a messagee.g. Order {{order_id}} saved
Open a pageWith the saved record as {{page.column}}
Add a record to…Another table, e.g. an activity log (who = {{me}})
Reload a blocke.g. a total on another tab

Steps run in the browser after the save succeeds. There are no emails or notifications after saving.

Sub-forms (lines inside a record)

On a form or pop-up, Sub-form → Lines from a second table (e.g. order lines in an order form). Set this record's key, the lines' column that points to it, a heading and the line columns.

  • In Add mode the record saves first, then its lines with the new key.
  • In Edit mode existing lines load; changed lines update, removed ones delete, new ones add.
  • Blank new lines are ignored. If lines fail after the record saved, you get a warning and the record stays.

Templates

Templates → pick one → choose your tables → check the guessed columns → Create pages. Templates reuse existing sources and never create tables.

TemplateTablesBuilds
To-do listtasksHeading, clock, To do / Done counts, priority donut, To do and Done tabs, edit form
CalendareventsCalendar, event detail, upcoming list, new-event form
Dashboardany tableCount, total, average, largest, pie, bars, latest records
ProfileusersPhoto, name, About and Edit profile tabs, filtered by {{me}}
Time managertasks + time logTask list, timer, minutes per task, log table, report page
Records & sub-recordsmain + related tableMain list, related table and count, details and edit tabs

Import, export and print

  • Import CSV (Table, Cards, List): comma or semicolon files up to 5000 rows and 8 MB. Match file columns to table columns, then Import; rows go in batches of 100 and the block's filters and link fill each row.
  • Export CSV: the rows after search and sort.
  • Print: prints the block as a clean table or record; Print the record prints one row. Use the browser's dialog to save as PDF.

SQLite sources

SQLite stores are the .sqlite files in Storage/Database. Only system root and administrators can use them, so build SQLite apps for admin users and use MySQL tables for everyone else.

  • Reads, filters and links work as on MySQL tables.
  • Writes need SQL_EDITOR_SQLITE_WRITE (on by default), a writable file and folder, and the user's create / update / delete right.
  • A table without a primary key uses rowid. created and updated columns are stamped automatically.
  • StoreDbTrait mirrors are rewritten from MySQL, so change the MySQL table instead.

5. Look, theme and the signed-in user

Apps follow the desktop theme automatically, in light and dark mode; set an accent colour only when an app needs its own brand colour. Click empty canvas to see these settings in the right panel.

Look

  • Accent colour: a #rrggbb colour for the app's buttons, highlights and charts. Leave it empty to use the theme's button colour.
  • Icon and Show app name on top for the app header.
  • App: currency code and default rows per page.

The runtime styles every block from AppShell tokens: surface and layer backgrounds, --text-primary / --text-muted, --window-border, input tokens, --selection-bg for picked rows, and --danger / --success for messages. Switching the desktop theme or dark mode restyles a running app with no change to its definition.

Block appearance

  • Title bar shows the title and toolbar. Text, Image, Clock, Button and Dropdown have it off by default.
  • Card background draws the bordered card. Text and Button are plain by default.
  • In Preview, ▯ switches to phone width; blocks marked Hide on small screens disappear there.

Signed-in user and roles

Set Signed-in user to the source that holds user details (a users table or saved query) and the column that holds the user key. The app loads that one record at start, then:

  • {{user.column}} works in text, defaults and filters;
  • rules can check the user, e.g. Show when Signed-in user's role equals admin.

Rules use one shape everywhere: what to look at → condition → value. You can look at the record picked in a block, the signed-in user, a page value, or this record / this form.

GoalRule
Order details only after an order is pickedRecord picked in Orders · (any column) · is picked
A block for admins onlySigned-in user's role equals admin
Approve only on pending rowsThis record's status equals pending (on the row action)
Reason field only when rejectingThis form's status equals rejected (on the field)

Hidden blocks do not load until they show. Rules shape the screen only; a user who lacks a permission is still stopped by the server.

6. Test, save, publish and run

Use Save draft while you work and Publish when users should get the new version; users always run the last published version.

Drafts, publishing and versions

ActionWhat happens
Save draftWrites studioDraft only. Users keep the published app; the Studio reopens the draft next time.
PublishWrites studio, sets version: 2, removes the draft and keeps the five previous published versions in studioHistory. Also sets Run as → App Studio app.
⟲ VersionsRestore an earlier version into the editor (then publish it), or Discard draft to go back to what is live.
\</> JSONView, copy or paste the whole definition; Apply replaces the app with what you pasted.

Everything is stored in the project's sp_app_project_config column; your existing App Configuration keys are kept alongside it.

Testing in Preview

Preview runs the app inside the Studio with real data, and you can keep editing in the right panel while it runs. Switch to ▯ phone width to check small screens. If ordinary users will use the app, also test with a non-admin account, since Preview uses your own permissions.

Running the published app

  • Launch it like any legacy app, through the project's Command ID (CoreBootApp with the projectUID).
  • CoreBootApp runs the Studio app when version is 2 and studio exists; otherwise it runs the legacy list app. App Config → Run as switches between the two at any time (the App Studio option appears after the first publish).
  • Window size comes from App Config → Window → Width / Height (default 1188 × 640).
  • Deep links open a given page with a value: new CoreBootApp(shell, ctx, { appID, projectUID, page: "Orders", params: { id: 7 } }) gives that page {{page.id}} = 7.

Checklist before you publish

  • [ ] Every data block has Data.
  • [ ] Sources that are edited have a Key column and are not Read-only.
  • [ ] Filter links have both columns set.
  • [ ] Calendars have a date column, boards a lane column, charts a group column, timers a start or minutes column.
  • [ ] Buttons, row actions and on-pick actions point to an existing page or pop-up.
  • [ ] Filter bars target at least one block; rules that check the user have Signed-in user set up.
  • [ ] Sub-forms have the column their lines point to.
  • [ ] Preview works with a normal (non-admin) account.
  • [ ] The ⚠ to check badge is gone, or you know why each item is fine.

7. Troubleshooting

Most problems come from a missing key column, a half-set link, or a draft that was never published.

SymptomLikely cause and fix
Pick a data source for this blockSet Data on the block.
Select a record in "…" never goes awayNothing is picked yet, or the link's columns are wrong; check Their column and my column.
Edit / Delete buttons are missingThe source has no Key column, or is Read-only.
New records can only be added to table sourcesSaved queries can't add records; use a table source.
A source shows no columnsClick Reload columns; check the table name and your access.
An error message under a blockThe server refused, usually a permission. Same rules as the rest of SepoDesk.
Numbers or charts look too smallOnly the first Max rows load; raise it on the source (maximum 5000).
The app still opens the old listApp Config → Run as → App Studio app, then save.
Users still see the old versionYou saved a draft; press Publish.
A block never showsIts Show when rules fail; check the picked block, column and user source.
{{user.x}} is emptySigned-in user is not set, or its key column doesn't match the user key.
A lookup shows the number, not the nameIn Show names from, the match column must hold the same values as the field.
Sub-form lines don't save on a new recordThe new record's key couldn't be found; give the table a key the server returns, or make saved values unique enough to read back.
A filter-bar filter does nothing on a blockThat block's data has no such column.
The SQL editor is available to administrators onlyThe block uses a SQLite source; only admins can load SQLite stores.
A SQLite source is read-onlyThe file or folder isn't writable, or SQL_EDITOR_SQLITE_WRITE=false.
The Studio shows a version message on opensp-app-runtime.js and sp-app-studio.js are different versions; replace both and clear the browser cache.

8. Developer notes

For extending App Studio itself. All files live in core/ and declare only classes at top level, so they are safe for the core bundle.

FileClassRole
sp-app-runtime.jsAppStudioKit, AppStudioDataClient, AppStudioRuntimeHelpers, block types and CSS; all server calls; renders and runs an app
sp-app-studio.jsAppStudioThe builder: templates, pop-up editor, undo / redo, drafts, versions
sp-core-boot-app.jsCoreBootAppRuns version 2 apps (with optional deep link), otherwise the legacy list
sp-app-editor.jsAppConfigEditorLegacy App Configuration; keeps studio; Run as
sp-note-editor.jsNoteEditorAdds the App Studio button and _openAppStudio()

Adding a block type

  1. Add it to AppStudioKit.BLOCK_TYPES (label, icon, span, group, plus data / selector / record flags) and its icon path to AppStudioKit.P.
  2. Add its settings and defaults in AppStudioKit.normalizeBlock.
  3. Render it in AppStudioRuntime.refreshBlock (non-data) or _paint (data), with CSS in RUNTIME_CSS using the --ar-* theme variables.
  4. In AppStudio, add its inspector section (_blockInspector), tile summary (_tileLines), defaults (addBlock), checks (issues()) and reference cleanup (_dropRefs()).
  5. If its rows can be coloured, add it to AppStudioKit.STYLED_TYPES and call _rowStyle(b, row) where rows are drawn.

When the definition shape changes, bump KIT_VERSION in both sp-app-runtime.js and sp-app-studio.js and deploy them together. Always pass a definition through AppStudioKit.normalizeDefinition() before use.

Known limits

  • Sorting, search, paging, groups, numbers and charts work on the loaded rows (up to Max rows); grouped tables show up to 2000 rows.
  • For saved queries only equals filters go to the server; is yes / is no always filter the loaded rows.
  • Show when, row-action rules and after-save steps run in the browser; they are not security.
  • No file uploads, emails or notifications; templates don't create tables.