Sample Apps
The samples repository demonstrates managed users, scoped workspaces, token minting, and agent recovery. Use it as an integration starting point. Samples evolve with the API.
Before you begin
You need an enabled Agent Filesystem app. Follow Quickstart to create an Agent Filesystem application in the Developer Console. Each sample has a README with its setup steps.
FolderSync
FolderSync is a desktop app that keeps a project folder in sync with a managed user’s Dropbox. You sign in as a managed user, sync a project folder with Sync now, and then undo the changes FolderSync made in Dropbox. It demonstrates four workflows:
Backend token minting
A small token server stands in for your backend: it holds the app key and secret, keeps the secret out of the app, and mints the managed user’s token. FolderSync uses that token to mint each agent’s token, and mints new ones automatically before they expire.
Token-server output
Managed-user sign-in
A user types a name, and the token server creates a managed user for a new name or signs back in to the existing one. Any name works here, for the demo. In your product, your backend checks who your user is before it mints their managed user’s token.

Project workspaces
Each project gets an agent limited to its folder. FolderSync writes changes with the agent’s token, so Dropbox records them as the agent’s. FolderSync syncs when you click Sync now, not in the background. Undo is next to it.

Change history and undo
Choose a change from the agent’s history to undo. Dropbox undoes that change and every change after it, and keeps changes made outside FolderSync.
To run it, follow Run FolderSync in its README.