Use case · Internal tools

Internal apps, without a platform team.

Admin panels, approvals, settings, audit trails, scheduled jobs, and live dashboards are mostly documents and background work. NonoDB gives teams one database and one console instead of five services to glue together.

Admin panelsApprovalsAuditJobsLive dashboardsReporting

Internal tools are a database and a few loops

Most internal apps are CRUD screens plus approvals, an audit trail, a scheduled job, and a notification. The database should make those boring, not turn every tool into a platform project.

Model the request

Each tool has its own fields. Store them as documents instead of planning a migration for every form change.

Protect the transition

Approve from a pending state with one atomic operation, so a double click cannot approve twice.

Keep the audit trail

History shows who changed what, and the GUI lets support inspect it without a custom admin screen.

Run the background work

Claim a queued job atomically, run it, record the result, and retry safely.

Internal tools feature map

Internal needNonoDB featureWhat you get
Admin panelsJSON documents and indexesModel each internal tool without a schema migration.
Approval queuesCompound indexesFilter by status, assignee, priority, and age.
Safe approvalsAtomic find_and_modifyApprove only from a pending state; concurrent clicks cannot double-approve.
Audit and undoDocument historySee every revision and restore a bad configuration change.
Background jobsJobs collection + atomic claimWorkers claim queued jobs without two workers running the same one.
NotificationsTransactional outbox eventsSend chat, email, or webhook messages from committed changes.
Live dashboardsWatch and live subscriptionsPending work and status changes appear without polling.
SearchText and fuzzy indexesFind requests, customers, or records by title and approximate name.
ReportingSQL and aggregationCounts by status, team, or period without an export.
Access controlPrincipals, tokens, and certificatesScope internal tools to the right users and services.
Existing toolsMongoDB wire endpointConnect existing drivers and admin scripts inside the supported subset.
OperationsBackups, replication, GUIRestore, fail over, and support the tool from one system.

The data model

A request collection covers most workflows. Add jobs for durable work and audit_log for business-level history that should outlive a single record.

CollectionPurposeUseful fields
requestsApprovals, access requests, purchases.title, type, requester_id, assignee_id, status, priority_rank, payload, created_at, approved_at
jobsDurable background work.type, state, priority_rank, run_at, attempts, payload, started_at, finished_at
audit_logAppend-only business audit.actor_id, action, target, before, after, created_at
settingsPer-tenant configuration.tenant_id, key, value, updated_by, updated_at
_eventsOutbox for notifications and integrations.type, doc_id, payload, created_at

Core internal workflows

1. Build the request queue

Internal queues are filtered lists. Index the tenant, status, assignee, and age fields so the page stays fast as the backlog grows.

{"op":"create_indexes","coll":"requests","indexes":[
  {"fields":["tenant_id","status","created_at"]},
  {"fields":["tenant_id","assignee_id","status"]}
]}
{"op":"create_indexes","coll":"jobs","indexes":[
  {"fields":["tenant_id","state","priority_rank","run_at"]}
]}
{"op":"find","coll":"requests",
 "filter":{"tenant_id":"acme","status":"pending"},
 "sort":[["created_at",1]],
 "limit":50}

2. Approve exactly once

Use a conditional find_and_modify. If the request is no longer pending, nothing matches and the operation returns null instead of overwriting another decision.

{"op":"find_and_modify","coll":"requests",
 "filter":{"_id":"req_123","tenant_id":"acme","status":"pending"},
 "update":{"$set":{"status":"approved","approved_by":"u_9"},
           "$currentDate":{"approved_at":true}},
 "new":true}

3. Keep an audit trail

Enable history on records that need undo or compliance review. For business events that span several records, append an audit_log document in the same write batch as the change.

{"op":"set_collection_history","coll":"requests","max_versions":100}
{"op":"history","coll":"requests","id":"req_123",
 "limit":50,"include_docs":true}

4. Run durable background jobs

A worker claims the oldest eligible job atomically. The state transition from queued to running happens once, even with several workers.

{"op":"find_and_modify","coll":"jobs",
 "filter":{"tenant_id":"acme","state":"queued",
           "run_at":{"$lte":"2026-05-01T12:00:00Z"}},
 "sort":[["priority_rank",1],["run_at",1]],
 "update":{"$set":{"state":"running"},
           "$inc":{"attempts":1},
           "$currentDate":{"started_at":true}},
 "new":true}

Events, live views, and reporting

Enable events for the fields that should trigger a notification or an external integration. The event commits with the request, so a webhook never sees a change that was rolled back.

{"op":"set_collection_events","coll":"requests",
 "enabled":true,"fields":["status","assignee_id"]}
{"op":"watch","coll":"_events","types":["requests.update"],
 "filter":{"payload.after.status":"approved"},"after":"01J..."}

For an operations dashboard, a live subscription pushes new and changed requests over one connection. No polling loop and no extra broker.

{"op":"watch","coll":"requests","mode":"live",
 "filter":{"status":"pending"},"ops":["insert","update"],
 "heartbeat_ms":10000}

Use aggregation for the dashboard and SQL for ad-hoc reports. The same data serves both.

{"op":"aggregate","coll":"requests","pipeline":[
  {"$match":{"tenant_id":"acme"}},
  {"$group":{"_id":"$status","requests":{"$sum":1}}},
  {"$sort":{"requests":-1}}
]}
Jobs need a retry policy. Store attempts, a run_at time, and a terminal result. A job that exhausts its attempts should move to a failed state and raise an alert, not disappear silently.

Where another tool fits better

One database for the internal long tail.

Ship the admin tool, not the infrastructure.