# Reference example

> A portable Worker with app-owned sessions, D1 notes and private R2 files.

- Canonical page: https://docs.userland.fun/examples/
- Docs index for agents: https://docs.userland.fun/llms.txt
- Machine-readable catalog: https://docs.userland.fun/examples/catalog.json

> **For agents:** Discover current capabilities, preserve exact operation identities, and follow the native workflow.

The selected `native-notes` reference is a normal Worker with static UI, D1 migrations, app-owned sign-in and per-user private R2 attachments. It has no Userland runtime SDK dependency.

Copy the complete directory from the [public repository](https://github.com/dwrtz/userland-public/tree/main/examples/native-notes), including `worker.js`, `wrangler.jsonc`, migrations, static assets, `README.md` and `AGENT.md`. The `apply.json` file contains typed generated-secret requirements, not secret values.

Adapt the app's behavior and tests, then apply the source to an owned preview through the native operations. Follow the returned build, migration and verification state. Public publication must be within the user's requested scope.

## Catalog

The [machine-readable catalog](/examples/catalog.json) records the selected source path, capabilities and difficulty. It does not promise a live demo, legacy plan, or existing demo address. Older examples are unadvertised historical material, not native templates.

The reference can also run in an ordinary Cloudflare account by mapping its logical D1/R2 resources and setting its session secret. That source portability does not advertise a Userland bring-your-own-account product. Read [From example](/quickstarts/from-example/) and [Worker configuration](/reference/resource-manifest/).

## Example Catalog

### Native notes and private files

App-owned sign-in, notes and private attachments on a plain Worker with native D1 and R2 bindings.

- Slug: `native-notes`
- Path: `examples/native-notes`
- Difficulty: intermediate
- Capabilities: worker, static, app_auth, d1, r2, secrets
