Productivity & personal

Build a journal app with AI

A native journal build brief covering saved data, purposeful screens and a repeatable real-input acceptance journey.

Apirex TeamUpdated AndroidiOS
On this page
  1. Screens
  2. Data model
  3. Native features for the journal app
  4. Android notes (Kotlin and Jetpack Compose)
  5. iPhone notes (Swift and SwiftUI)
  6. Copy-paste prompt
  7. Acceptance test
  8. Frequently asked questions
4screens
3data tables
192word prompt
2platforms: Android, iOS

This journal build brief is for people keeping a reflective record that should stay private and easy to revisit. Its first version should prove one concrete loop: save an entry for a chosen date and recover its exact text through the calendar. Keep dated entries, optional moods, calendar navigation and writing prompts connected to the same saved records before adding more ambitious integrations.

Screens

  • Today’s entry: Compose a dated reflection with optional mood
  • Calendar: Open saved entries by their effective journal date
  • Mood statistics: Summarize user-selected mood labels without diagnosis
  • Prompts: Choose optional writing starters without overwriting drafts

Data model

TableKey fieldsPurpose
entriesid (uuid), entry_on (date), body (text), updated_at (timestamptz)Private reflections indexed by their chosen calendar date
moodsid (uuid), entry_id (uuid), label (text), recorded_at (timestamptz)Optional self-reported labels rather than clinical measurements
promptsid (uuid), text (text), enabled (boolean)Owner-reviewed writing starters that contain no entry content

Choose local-only journal storage unless the owner deliberately requests account synchronization. A backend version needs server-side row-level security for every entry and mood, with prompts separated from private reflections. Never infer that a public prompt makes its answers public. Define deletion and recovery before collecting sensitive writing, and avoid placing entry bodies in analytics events, notification previews or routine error logs.

Native features for the journal app

Require the chosen unlock policy before drawing entry text; an authentication gate is not a claim that the database has additional encryption. Keep the effective journal date separate from save timestamps, so travelling does not move yesterday’s reflection.

FeatureAndroid (Kotlin)iPhone (SwiftUI)Notes
Private writing vaultRoom behind BiometricPromptSwiftData behind LocalAuthenticationRequire the chosen unlock policy before drawing entry text; an authentication gate is not a claim that the database has additional encryption.
Dated draftsSavedStateHandle and transactional draft writesScene-aware editor state and private document storageKeep the effective journal date separate from save timestamps, so travelling does not move yesterday’s reflection.
Discreet writing nudgeNotificationManager with neutral preview textUserNotifications without an entry excerptOffer an opt-in evening prompt that reveals neither mood nor the first sentence of a private reflection.

Android notes (Kotlin and Jetpack Compose)

Build the dated editor with a Material 3 TextField and keep its draft in a ViewModel keyed by entry ID. Commit text and the selected mood together in Room, while leaving a missing mood genuinely empty rather than substituting a neutral label.

  • Use Navigation Compose routes for the calendar date and entry identifier, not the reflection body. Render calendar results with stable entry keys, and hold the selected date in SavedStateHandle so opening a writing prompt does not reset the editor to today.
  • Place BiometricPrompt ahead of private content and cover the editor when the activity backgrounds. Keep lock preferences in DataStore; do not put entry text there. Cancelled authentication should return to a blank locked surface, not a briefly visible paragraph.
  • On an Android phone, write a reflection dated yesterday, dismiss the keyboard, and switch away. Return after the relock interval, cancel authentication, then unlock successfully. Compare punctuation and mood with the saved entry; inspect the recent-apps preview for accidental text exposure.

iPhone notes (Swift and SwiftUI)

Use a NavigationStack whose path identifies the selected journal day. Bind the SwiftUI TextEditor to an editable draft rather than saving every navigation change as a new reflection; SwiftData should retain one intended entry record for that day.

  • Observe scenePhase to conceal the writing view before the app becomes inactive. LocalAuthentication may succeed, fail or be cancelled, and each path needs an explicit visible state. Explain the device-credential fallback instead of suggesting biometric hardware is always available.
  • Present mood choices in a sheet with detents and a clear no-mood option. A writing starter should enter the draft only after confirmation when text already exists; dismissing either sheet must leave the previous reflection untouched.
  • On an iPhone, choose a past calendar date, type several paragraphs with VoiceOver enabled, and lock the screen mid-edit. Unlock, authenticate and revisit the same date. Change the device time zone and verify the entry remains attached to its original calendar square.

Copy-paste prompt

Build this yourself 190 words · Android
Build a journal app for Android using native screens and a deliberately small first release. The core scope is dated entries, optional moods, calendar navigation and writing prompts. Include these destinations: Today’s entry, Calendar, Mood statistics, Prompts. Use these persisted entities: entries, moods, prompts; retain stable identifiers and explicit relationships rather than maintaining independent screen totals.
Ask me these owner decisions before implementing ambiguous behavior: whether more than one entry is allowed per day, how backdating works, and when device authentication should be requested. Do not invent a policy or add an unrequested external integration. Start local-only unless I explicitly choose account storage; if I choose a backend, enforce ownership on the server with row-level security.
Show loading, empty and recoverable error states, plus permission-denied handling wherever a native capability requests access. Keep incomplete input recoverable and distinguish it from saved data. For acceptance, save an entry for a chosen date and recover its exact text through the calendar. Also exercise the invalid-input or denied-permission path and reopen the app to inspect the persisted result. Explain any remaining device-only checks rather than equating a successful build with a passing journey.

Opens Apirex with this prompt in the box. Pick the Android · Kotlin tab before you send.

Acceptance test

  1. Write an entry for yesterday containing Saw a heron by the river and leave mood unselected.
  2. Open Calendar and verify yesterday is marked while today remains a separate date.
  3. Return to the saved date, add a mood, and verify the body was not replaced.
  4. Reopen the app and inspect the exact reflection and selected calendar date.
  5. Cancel device authentication or simulate a failed save; confirm private content stays hidden or the draft remains explicitly unsaved.

Open a backdated reflection and change only its mood. Verify the original journal date and body remain unchanged, then remove the mood and confirm the reflection still appears in Calendar. If multiple entries per day are allowed, calendar navigation must show an entry chooser instead of silently opening whichever record happens to be returned first.

A blank day should offer writing, while an unreadable saved entry should show a retrieval error without presenting an empty editable page that could overwrite it. Keep mood summaries unavailable when their source query fails. Ask whether deleted reflections have a recovery window, and apply the same retention decision to optional mood records and drafts rather than leaving sensitive remnants behind after the visible entry disappears.

Frequently asked questions

Does a journal lock encrypt every stored entry?

An authentication screen is not, by itself, a complete encryption design. Define device protection, export behavior and any additional storage requirements before describing the journal as protected.

Can mood statistics identify depression?

No diagnostic interpretation belongs in this brief. Present self-reported mood counts as a reflection aid, not as medical advice, risk assessment or a guaranteed wellbeing benefit.

How should entry deletion work?

Require a deliberate confirmation and define whether deletion is immediate or recoverable. If account storage is later connected, the policy must cover remote copies and attachments as well as the local entry.

Build this blueprint

The blueprint prompt, ready for your platform. Edit anything before you send it.

AndroidKotlin · Jetpack ComposeReal source on your computer

Opens Apirex with this prompt. Pick the Android · Kotlin tab before you send. The Free plan includes 5 Rex Credits a day.