Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 12 additions & 20 deletions docs/collector/collector-getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,33 +17,25 @@ Before starting, make sure you have:

## Step 1: Install Formulus

### Option A: From Google Play Store (Android)
### Option A: F-Droid (Android)

1. Open **Google Play Store** on your Android phone
2. Search for **"Formulus"**
3. Tap **Install**
4. Wait for installation to complete (usually 1-2 minutes)
1. Open the [Formulus page on F-Droid](https://f-droid.org/en/packages/org.opendataensemble.formulus/)
2. Install the F-Droid client if prompted
3. Tap **Install** and wait for the download to complete

### Option B: From App Store (iOS)
### Option B: App Store (iPhone and iPad)

1. Open **App Store** on your iPhone
2. Search for **"Formulus"**
3. Tap **Get**
4. Authenticate with Face ID, Touch ID, or Apple ID
5. Wait for installation to complete
1. Open the [Formulus App Store page](https://apps.apple.com/dk/app/formulus/id6798318215)
2. Tap **Get**
3. Authenticate with Face ID, Touch ID, or Apple ID
4. Wait for installation to complete

### Option C: Direct Installation (Android)
### Option C: Obtainium or direct APK (Android)

If your project manager provided an APK file:

1. Download the APK file to your phone
2. Open your file manager and locate the APK
3. Tap the file to install
4. If prompted, allow installation from "Unknown Sources"
5. Tap **Install**
Use [Obtainium](https://github.com/ImranR98/Obtainium) with `https://github.com/OpenDataEnsemble/ode` for updates from GitHub Releases, or download the APK directly from [Downloads](/downloads).

:::note
If you don't have Google Play Store access or need a specific version, contact your project manager for a direct download link.
The [Downloads](/downloads) page has the current Android APK and all desktop/CLI downloads.
:::

## Step 2: Open Formulus & Connect to Your Project
Expand Down
1 change: 1 addition & 0 deletions docs/development/architecture.md
Original file line number Diff line number Diff line change
Expand Up @@ -223,6 +223,7 @@ See [Security reference](/docs/reference/security) for deployment checklist and

- **Local Database**: Fast queries using WatermelonDB
- **Incremental Sync**: Only sync changes since last sync
- **Adaptive pages**: Formulus starts at 32 pull / 4 push, grows toward 500 / 100, floor 1
- **Lazy Loading**: Load attachments on demand
- **Caching**: Cache app bundles and form specifications

Expand Down
12 changes: 8 additions & 4 deletions docs/development/building-testing.md
Original file line number Diff line number Diff line change
Expand Up @@ -234,10 +234,14 @@ The project uses GitHub Actions for continuous integration:
### Workflows

**Synkronus Docker Build:**
- Triggers on push to `main` or PRs affecting `synkronus/`
- Builds Docker image
- Publishes to GitHub Container Registry
- Tags: `latest`, `v{version}`, `{branch-name}`
- Builds on relevant pushes to `main` or `dev`, pull requests, published GitHub Releases, and manual dispatches
- Publishes multi-platform images to GitHub Container Registry (pull requests build without publishing)
- Stable releases publish `v{version}`, major/minor pointers, and `latest`
- Pre-releases publish `v{version}-{pre}` and `latest-pre-release`
- Branch pushes publish `main` or `dev` plus an immutable `sha-{short}` tag
- Manual dispatches publish only `sha-{short}`; feature-branch images are not published automatically

See the [Deployment guide](/docs/guides/deployment) for the image-tag channels and recommended uses.

**Frontend Quality Checks:**
- Runs on all PRs
Expand Down
12 changes: 6 additions & 6 deletions docs/development/installing-formulus-dev.md
Original file line number Diff line number Diff line change
Expand Up @@ -161,19 +161,19 @@ adb install app-debug.apk

```bash
# Browse the release and download the arm64-v8a APK for most phones:
# https://github.com/OpenDataEnsemble/ode/releases/tag/v1.3.0
# Asset names look like: formulus-v1.3.0-35-arm64-v8a-release-YYYYMMDD.apk
adb install /path/to/formulus-v1.3.0-*-arm64-v8a-release-*.apk
# https://github.com/OpenDataEnsemble/ode/releases/tag/v1.3.2
# Asset names look like: formulus-v1.3.2-64-universal-release-YYYYMMDD.apk
adb install /path/to/formulus-v1.3.2-*-universal-release-*.apk
```

</TabItem>
<TabItem value="windows" label="Windows">

```powershell
# Browse the release and download the arm64-v8a APK for most phones:
# https://github.com/OpenDataEnsemble/ode/releases/tag/v1.3.0
# Asset names look like: formulus-v1.3.0-35-arm64-v8a-release-YYYYMMDD.apk
adb install "C:\path\to\formulus-v1.3.0-*-arm64-v8a-release-*.apk"
# https://github.com/OpenDataEnsemble/ode/releases/tag/v1.3.2
# Asset names look like: formulus-v1.3.2-64-universal-release-YYYYMMDD.apk
adb install "C:\path\to\formulus-v1.3.2-*-universal-release-*.apk"
```

</TabItem>
Expand Down
2 changes: 1 addition & 1 deletion docs/getting-started/architecture-overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ sidebar_position: 1

ODE (Open Data Ensemble) is a comprehensive platform for mobile data collection and synchronization. This guide explains the core architecture and components.

> **Current ODE release:** [v1.3.0](https://github.com/OpenDataEnsemble/ode/releases/tag/v1.3.0)
> **Current ODE release:** [v1.3.2](https://github.com/OpenDataEnsemble/ode/releases/tag/v1.3.2) · [Downloads](/downloads)

## Core Components

Expand Down
2 changes: 1 addition & 1 deletion docs/getting-started/faq.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ sidebar_position: 5

Common questions about ODE installation, usage, and development.

> **Current ODE release:** [v1.3.0](https://github.com/OpenDataEnsemble/ode/releases/tag/v1.3.0) (Synkronus container, Formulus APK, Desktop, Portal)
> **Current ODE release:** [v1.3.2](https://github.com/OpenDataEnsemble/ode/releases/tag/v1.3.2) (Synkronus container, Formulus, Desktop, CLI, Portal) · [Downloads](/downloads)

## General Questions

Expand Down
7 changes: 4 additions & 3 deletions docs/getting-started/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,16 @@ To run ODE you need two things: a **server** (Synkronus) that stores and syncs d
| Component | What it is | Guide |
|-----------|------------|--------|
| **Server (Synkronus)** | Backend that hosts the API, portal, and database. Runs on a Linux server or VPS. | [Install Synkronus](installation/installing-synkronus) |
| **Client (Formulus)** | Mobile app for Android that field workers use to fill forms and sync data. | [Install Formulus](installation/installing-formulus) |
| **Client (Formulus)** | Mobile app for Android and iOS that field workers use to fill forms and sync data. | [Install Formulus](installation/installing-formulus) |

Install the server first so that the client has something to connect to. Then install Formulus (or your client app) on each device and point it at your Synkronus server.

## For IT / infrastructure teams

Hosting Synkronus for a study? See **[Server Architecture for IT](/docs/guides/server-architecture-for-it)** for a one-page overview: container layout, TLS, backups, and how custom apps (app bundles) relate to the server. Current platform release: **v1.3.0**.
Hosting Synkronus for a study? See **[Server Architecture for IT](/docs/guides/server-architecture-for-it)** for a one-page overview: container layout, TLS, backups, and how custom apps (app bundles) relate to the server. Current platform release: **v1.3.2**.

## Next steps

- **[Install Synkronus](installation/installing-synkronus)** — Set up the server on a Linux machine or VPS.
- **[Install Formulus](installation/installing-formulus)** — Put the Formulus app on Android devices and connect it to your server.
- **[Downloads](/downloads)** — Get Formulus, ODE Desktop, or the Synkronus CLI for your platform.
- **[Install Formulus](installation/installing-formulus)** — Put the Formulus app on Android or iOS devices and connect it to your server.
32 changes: 20 additions & 12 deletions docs/getting-started/installation/installing-formulus.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,16 @@ sidebar_position: 2

# Installing Formulus App

Complete guide for installing the Formulus mobile application on Android devices.
Complete guide for installing the Formulus mobile application on Android and iOS devices. For the current links, see [Downloads](/downloads).

## Overview

Formulus is available for Android devices through multiple installation methods. Choose the method that best fits your needs:
Formulus is available for Android and iOS. Choose the method that best fits your device:

- **Obtainium** (Recommended) - Installs Formulus from GitHub releases with automatic updates. Install Obtainium via F-Droid or direct download.
- **F-Droid** - Install Formulus directly from [F-Droid](https://f-droid.org/packages/org.opendataensemble.formulus/)
- **Direct APK** - Download and install the APK file directly from [GitHub releases](https://github.com/OpenDataEnsemble/ode/releases) (current: **v1.3.0**)
- **F-Droid** (recommended for Android) - Install Formulus directly from [F-Droid](https://f-droid.org/en/packages/org.opendataensemble.formulus/)
- **Obtainium** (Android) - Installs Formulus from GitHub releases with automatic updates.
- **Direct APK** (Android) - Download the current APK from [Downloads](/downloads) or [GitHub releases](https://github.com/OpenDataEnsemble/ode/releases).
- **App Store** (iPhone/iPad) - Install Formulus from the [Apple App Store](https://apps.apple.com/dk/app/formulus/id6798318215).
- **Development Build** - For developers who want to build from source

## System Requirements
Expand All @@ -22,6 +23,7 @@ Before installing, ensure your device meets these requirements:
| Requirement | Minimum |
|-------------|---------|
| **Android Version** | Android 7.0 (API level 24) or higher |
| **iOS Version** | iOS 15.1 or higher |
| **Storage Space** | 50 MB free space |
| **Internet Connection** | Required for initial setup and synchronization |
| **Permissions** | Camera, Storage, Location (for form features) |
Expand Down Expand Up @@ -86,7 +88,7 @@ You have two options to install Obtainium:

![Obtainium Add App Screen](/img/installation/obtainium-add-app.png)

**Stable release:** Install **v1.3.0** (or the latest [GitHub release](https://github.com/OpenDataEnsemble/ode/releases)). Pre-release toggles are only needed for alpha/beta testing.
**Stable release:** Install **v1.3.2** (or the latest [GitHub release](https://github.com/OpenDataEnsemble/ode/releases)). Pre-release toggles are only needed for alpha/beta testing.

#### Step 3: Install Formulus

Expand All @@ -97,7 +99,7 @@ You have two options to install Obtainium:
- App name: **ode**
- Developer: **OpenDataEnsemble**
- Package: `org.opendataensemble.formulus`
- Latest version: **v1.3.0** (or current [release](https://github.com/OpenDataEnsemble/ode/releases))
- Latest version: **v1.3.2** (or current [release](https://github.com/OpenDataEnsemble/ode/releases))
- Status: **Not installed**
5. **Tap the "Install" button** at the bottom of the screen
6. **Confirm installation** when prompted:
Expand Down Expand Up @@ -127,7 +129,7 @@ Obtainium will automatically check for updates:
5. **Confirm the update** when prompted
6. **App data is preserved** during update

### Method 2: F-Droid
### Method 2: F-Droid (recommended for Android)

Install Formulus directly from F-Droid (no Obtainium required):

Expand All @@ -136,13 +138,13 @@ Install Formulus directly from F-Droid (no Obtainium required):
3. Tap **Install** and wait for the download to complete
4. Updates are available through F-Droid when a new version is published

### Method 3: Direct APK Installation
### Method 3: Direct APK Installation (Android)

If Obtainium is not available or you prefer direct installation:

#### Step 1: Download the APK

1. **Download the latest APK** from the [releases page](https://github.com/OpenDataEnsemble/ode/releases)
1. **Download the latest APK** from [Downloads](/downloads) or the [releases page](https://github.com/OpenDataEnsemble/ode/releases)
2. **Save the file** to your device's Downloads folder

#### Step 2: Enable Unknown Sources
Expand All @@ -165,7 +167,13 @@ If Obtainium is not available or you prefer direct installation:
6. **Wait for installation** to complete
7. **Tap "Open"** to launch the app

### Method 4: Development Build
### Method 4: App Store (iPhone and iPad)

1. Open the [Formulus App Store page](https://apps.apple.com/dk/app/formulus/id6798318215) on your iPhone or iPad.
2. Tap **Get**, then authenticate with Face ID, Touch ID, or your Apple ID.
3. Wait for Formulus to install, then open it from your home screen.

### Method 5: Development Build

For developers who want to build and install from source, see the [Development Installation Guide](/docs/development/formulus-development).

Expand Down Expand Up @@ -273,7 +281,7 @@ To verify that Formulus is installed correctly:

### Via Direct APK

1. **Download the latest APK** from the [releases page](https://github.com/OpenDataEnsemble/ode/releases)
1. **Download the latest APK** from [Downloads](/downloads) or the [releases page](https://github.com/OpenDataEnsemble/ode/releases)
2. **Install over existing installation** (no need to uninstall)
3. **App data is preserved** during update

Expand Down
8 changes: 4 additions & 4 deletions docs/getting-started/installation/installing-ode-desktop.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ sidebar_position: 3

Complete guide for installing **ODE Desktop** on Windows, macOS, and Linux.

:::info ODE v1.1.0
:::info ODE v1.3.2

ODE Desktop is part of the **ODE v1.1.0** release. Pre-built installers are published on [GitHub Releases](https://github.com/OpenDataEnsemble/ode/releases).
ODE Desktop is part of the **ODE v1.3.2** release. Use the [Downloads](/downloads) page for direct, platform-matched installers or browse [GitHub Releases](https://github.com/OpenDataEnsemble/ode/releases).

:::

Expand Down Expand Up @@ -36,8 +36,8 @@ Choose the installation method that fits your role:

## Method 1: GitHub Releases (recommended)

1. Open [OpenDataEnsemble/ode releases](https://github.com/OpenDataEnsemble/ode/releases).
2. Select the **v1.1.0** release (or the latest stable tag).
1. Open [Downloads](/downloads) to download the installer matched to your platform, or open [OpenDataEnsemble/ode releases](https://github.com/OpenDataEnsemble/ode/releases).
2. Select the **v1.3.2** release (or the latest stable tag).
3. Download the artifact for your platform:

| Platform | Typical artifact |
Expand Down
2 changes: 2 additions & 0 deletions docs/guides/building-custom-apps-v2.md
Original file line number Diff line number Diff line change
Expand Up @@ -584,6 +584,8 @@ The Formulus API:

## API reference

The bridge also exposes synchronous `api.getProfileId()` and `api.getLocalStorageRef()` for profile-aware custom-app state. Use the storage reference instead of raw `localStorage` under the shared `file://` origin; see [profile-aware browser storage](./custom-applications.md#profile-aware-browser-storage) for examples and limitations.

### getObservations(formName)

```javascript
Expand Down
16 changes: 16 additions & 0 deletions docs/guides/custom-applications.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,22 @@ Custom applications are **web applications** (HTML, CSS, and JavaScript) that ru
The **ODE repository** (Formulus, Formplayer, Synkronus Portal, design packages) uses **pnpm** — see [Development Setup](/docs/development/setup#package-manager-pnpm). **Your** custom app project can use **npm**, **pnpm**, or **yarn**; the examples below use common **npm** script names from the [custom_app](https://github.com/OpenDataEnsemble/custom_app) template.
::: You may author them with **any** stack—plain static files, **Vite**, **React**, **Vue**, **Svelte**, or another bundler—**as long as the build output** can be packaged as described in the [app bundle format](/docs/reference/app-bundle-format) (entry HTML, assets, and `forms/` layout). They provide specialized workflows, custom navigation, integration with the ODE form system, and interfaces tailored to your use case.

## Profile-aware browser storage

Formulus hosts each custom app for the active **profile**. Users add and switch profiles in the in-app **Profiles** screen; the host remounts the WebView when switching. The host scopes observations, attachments, bundle files, and Formplayer drafts to the active profile. Custom apps should use the synchronous profile-aware browser storage reference after the bridge is ready:

```javascript
const api = await getFormulus();
const profileId = api.getProfileId(); // stable for this WebView; not the display name
const storage = api.getLocalStorageRef();
storage.setItem('lastTab', 'home');
const lastTab = storage.getItem('lastTab');
storage.removeItem('lastTab');
// storage.clear() removes only this profile's custom-app keys.
```

The reference uses physical keys `ode:{profileId}:app:{key}`. Both helpers are synchronous, and storage errors propagate. Do **not** use raw `localStorage` for profile-specific state: custom apps and dependencies loaded under a shared `file://` origin may read or write raw storage outside the namespace. This is organizational/storage namespacing, **not a sandbox or confidentiality boundary**; deleting a profile cannot guarantee removal of unrelated third-party raw keys. Depending on WebView file-access settings and device behavior, code in a custom app or form extension may also read other profiles' data or attachments via file access. A connected Synkronus server can distribute app bundles containing code; not every server necessarily does so. Connect only to trusted servers and install only trusted bundles. Do not store secrets in browser storage. See the [Formulus bridge reference](../reference/formulus.md#getprofileid-and-getlocalstorageref).

## Scaffolding

ODE does **not** require a special installer: start from a **standard** project scaffold (for example **`npm create vite@latest`** with React, Svelte, or Solid templates) and then align the **folder layout** with the app bundle spec. Copy-paste commands, a **Vite `outDir` example**, and a post-scaffold checklist are maintained in the **[custom_app](https://github.com/OpenDataEnsemble/custom_app)** repository README on GitHub (AI and author context for the Formulus API and forms live in that repo as well).
Expand Down
6 changes: 6 additions & 0 deletions docs/guides/custom-extensions.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,12 @@ The extension system enables you to:
- **Reusable Components** - Package extensions for distribution to other implementations
- **Automatic Distribution** - Deploy via app bundles; users get updates automatically

## Profile-aware extensions

Custom renderers and validators run in a Formplayer WebView for the **active host profile**. Formulus owns the profile's observation database, attachments, app bundle cache, and Formplayer draft storage. Switch profiles from the Formulus **Profiles** screen; switching remounts the WebView rather than changing its profile in place.

For extension-owned browser preferences, use the synchronous bridge helpers `formulus.getProfileId()` and `formulus.getLocalStorageRef()` (after the bridge is ready). The latter supports `getItem`, `setItem`, `removeItem`, and `clear` for keys in `ode:{profileId}:app:{key}`; `clear` affects only this profile's app namespace. Avoid raw `localStorage`: a shared `file://` origin may expose raw keys to other profiles or third-party code. Profiles provide organizational/storage namespacing, **not a sandbox or confidentiality boundary**, nor a guarantee that third-party raw keys will be erased on profile deletion. Depending on WebView file-access settings and device behavior, code in a form extension or custom app may read other profiles' data or attachments via file access. A connected Synkronus server can supply bundles with such code, though connecting does not mean every server executes arbitrary code. Connect only to trusted servers and install only trusted app bundles; do not store secrets in browser storage. See [Formulus JavaScript interface](../reference/formulus.md#getprofileid-and-getlocalstorageref) and [custom-app storage guidance](./custom-applications.md#profile-aware-browser-storage).

## Sub-observations (`format: sub-observation`)

:::tip Built-in Formplayer control
Expand Down
Loading
Loading