What Mobster reads
Mobster checks what a file is from its first bytes, not its name: it refuses a program renamed
policy.pdf. A file is at most 25 MB, a conversation holds at most 100 MB of files, and Mobster keeps at most 1 GB in all. It refuses a PDF locked with a password, with a sentence that says how to get a copy without one.
Before a task starts, the agent sees each file’s name, type and size and as much of its text as fits in 12,000 characters, shared between the files. It reads more with READ_ATTACHMENT (“policy.pdf page 3”, or the next 6,000 characters of a long text file), as its own step.
In Mobster for Mac
- Attach. Press + in the composer, or drop or paste files onto it (“Drop to attach” shows while you drag). Each file shows as a chip with what Mobster read: PDF, 2 pages, 412 KB. A file Mobster can’t read says why on its chip. Up to 10 files go with a task. A file you add in a conversation stays with that conversation; one you add outside a conversation goes with whichever task you start next.
- Remove. The × on a chip. Mobster deletes a file no task used yet from this Mac at once.
- Open. Click a chip, or a file in a conversation, to see it under the chips or the message: an image, a PDF’s first page or the start of a text file. Click it again, or press
esc, to put it away. - Put on iPhone. The opened file lists the apps on your iPhone that keep files you can see in Files (Pages, Numbers, Keynote, Documents and others), Photos for a picture, and, for a text file, the clipboard (its whole text, up to 64 KB). Choose one and press Put on iPhone. Your click is the go-ahead for that copy. Mobster keeps a file with the same name that is already there, and gives the new one a new name (“policy 2.pdf”).
- Drop on the phone. Drop a photo on the phone beside the conversation and Mobster adds it to Photos on your iPhone: “Added to Photos on Test iPhone”.
Results into a file
To keep every result of a workflow in one file, connect Folder in Settings › Connectors and choose it in Send to. Mobster adds each result to the end of a CSV or JSON Lines file in a folder in your home folder, and Mobster never replaces what is already there (A folder on your Mac).Use files in a task
When a task needs a file on the phone (to attach it in an app, say), the agent usesPUT_FILE with the file’s name and a destination: an app’s bundle ID, photos for a picture (any app’s photo picker can then attach it), or clipboard for a text file. Mobster asks first, with the exact file, app and phone: Put “policy.pdf” in Pages on Test iPhone? Only after you approve does it copy, then it checks that the file arrived. The app has to be one you allowed: its first use asks, as in any task. With nobody to ask (Full access, or a script), the copy never runs.
A task an agent outside Mobster started never puts files in an app you turned off for those agents in Settings › Safety.
The run’s events say what happened, without the files’ text: attachment_read {id, name, pages?, page?} when the agent reads a file, and file_put {name, bytes, destination, status} after a copy (status is copied or failed).
mobster phone file
Files move between this Mac and the folder of an iPhone app that shares files, over the cable. Nothing else on the phone is reachable: not other apps’ data. The camera roll has its own commands, mobster phone photos add and pull (What it can do).
putcopies a file of up to 100 MB. A name that’s taken gets a new one (“policy 2.pdf”) unless you pass--replace.--namegives it another name on the phone. Mobster copies from a private local snapshot, so a change to the original during approval does not change what is sent.getsaves into the current folder, or the folder or file-onames. A file already there is kept, and the copy gets a new name.--containerreaches the Documents folder inside a development build of yours (signed for debugging), for an app that doesn’t share files.--devicepicks the iPhone (its id, UDID or name frommobster devices), and--jsonprints one JSON object.- Exit codes: 0 done, 1 it failed, 2 usage, 3 no iPhone on a cable, or the iPhone tools are missing.
brew install libimobiledevice.
Over Wi-Fi. Mobster reaches an app’s folder only over the cable. A phone on Wi-Fi answers “Files move only over the cable for now. Plug the iPhone into this Mac, then try again.” (needs_cable). Photos and videos move without a cable: Photos and videos.
MCP
mobster mcp --allow-files adds three tools for your own agent. Without the flag, the server doesn’t list them, and your agent can’t call them.
--allow-device limits them like every other tool. They never reach the camera roll: send_media and pull_media (MCP) do, with --allow-files and --allow-photos.
Where files are kept
Beside your task history: in Mobster for Mac,~/Library/Application Support/app.mobster.desktop/state/attachments/, one folder per file holding the original, its thumbnail and the text Mobster read. The folders are readable only by you (0700), the files too (0600).
- A file in a conversation stays until you delete the conversation.
- A file a task used, outside a conversation, goes when that task leaves your history.
- Mobster deletes a file nothing used within a day.
HTTP API
Under/api/attachments and /api/phone/files, with the same token as the rest of the API (the HTTP API). Each error is a sentence with a code.
An
Idempotency-Key reserves the resolved device ID, attachment and destination on disk before copying. A completed copy returns its saved success for 10 minutes; reusing the key with another payload, or with a default device or alias that now resolves to another phone, returns 409 idempotency_conflict. A copy still in progress or with an unknown outcome returns 409 copy_outcome_unknown, and Mobster never sends it again, including after a restart. Check the destination on your iPhone before you start another copy. Unresolved copies never expire; a full journal refuses new keyed copies with 503 copy_journal_full.
Set up the device in Mobster before you copy through this API or Mobster for Mac. Mobster uses the configured runner address to take the same device lease as a task. A device without that address returns 409 no_device before it reserves or sends a copy. Local validation and a busy device do not consume your copy key. mobster phone file put uses the USB file service directly and does not need a runner.
An attachment is {id, name, mime, bytes, kind: image|pdf|text|csv, label, pages?, rows?, columns?, width?, height?, textAvailable, origin: upload|phone, thumbUrl, contentUrl, createdAt, threadId, runIds} (times in milliseconds). The phone’s routes answer 409 needs_cable (on Wi-Fi), no_file_sharing (that app has no folder in Files), no_device or locked, 404 not_found, and 503 tools (the iPhone tools are missing).
A task with files. POST /api/runs takes attachmentIds: up to 10 attachment ids. The run keeps them, and a task in a conversation adds its files to that conversation.
Events. The bus topic attachments (GET /api/events?topics=attachments) carries attachment_created {id, threadId}, attachment_deleted {id} and attachments_used {ids, runId, threadId}. A file brought back into a conversation (threadId) is posted to it as a thread item of kind file_saved: {attachment, app, device}.
Photos and videos
Send photos and videos from this Mac to any of your iPhones, and bring the newest ones back. Mobster picks the route that reaches the phone: the cable, Wi-Fi, AirDrop or iPhone Mirroring. iCloud Photos is there when you choose it. The route determines what Mobster can check: a matching SHA-256, a library count or a file size. Some routes only report that the file was sent.add prints what moved and how it was checked:
Routes
auto, the default, tries the routes in that order and skips icloud. A copy to this Mac moves to the next route after any failure, since it changes nothing on the phone. A send to the iPhone moves on only when a route refused before sending anything: the phone isn’t on a cable, AirDrop doesn’t see it, Mirroring isn’t set up for it. Once a route sent a file, Mobster never sends it again another way. If the outcome is unknown (AirDrop stopped answering, the library didn’t grow), the transfer ends unknown and says “Look in Photos before you send it again.”
Each file ends one of these ways:
Mac to iPhone
A transfer through the helper app holds the phone’s device lock through upload and verification. If another task owns the phone, the transfer stops before sending and does not switch to AirDrop or another route. Importing media into a named simulator holds its device lock whilesimctl addmedia runs. A lost import answer ends as unknown; check Photos before sending again.
Photos and videos go into an album, Mobster unless you name another with --album NAME (--album '' for none). Mobster makes the album if it isn’t there. JPEG, HEIC, PNG, GIF, WebP, MOV and MP4 go, up to 4 GB each and 50 at a time. Mobster reads what a file is from its first bytes, not its name.
- Over the cable or Wi-Fi. Mobster takes a private local snapshot before preflight and approval, so a change to the original does not change the sent file. The helper app on the phone saves each file with PhotoKit, as any app that adds to Photos does. The file goes in pieces of 8 MB, and the phone checks the whole file’s SHA-256 against this Mac’s before Photos sees it. A file that changed on the way never reaches Photos. The first time, iOS asks on the phone whether Mobster may use Photos: Limit Access is enough. An older helper app takes one file of up to 100 MB, with no album: on the Devices page, choose your iPhone’s ⋯ › Set up again…, then Reinstall the helper.
- AirDrop. Mobster opens AirDrop’s panel on this Mac and presses the one device named exactly as your iPhone is (Settings › General › About › Name). If two devices nearby share that name, or yours doesn’t show within 30 seconds, it presses Cancel and sends nothing. An iPhone signed in to the same Apple Account as this Mac takes the files at once. Another iPhone asks you to Accept. With the helper app running on that iPhone and the phone unlocked, Mobster taps Accept on that AirDrop alert and nothing else. It needs Accessibility for Mobster (System Settings › Privacy & Security › Accessibility).
- iPhone Mirroring. Mobster opens Photos on the phone through Spotlight and drops the files on the Mirroring window. iPhone Mirroring doesn’t say which iPhone it shows, so this route runs only for the phone you name in
MOBSTER_MIRRORS(its name or UDID) inagent.env. The phone stays locked while it’s mirrored. - iCloud Photos. With iCloud Photos on for this Mac and the iPhone, Mobster imports the files into this Mac’s Photos library, and iCloud carries them to the phone. Mobster uses it only when you choose
--via icloud. Photos opens in the background, and macOS asks once whether Mobster may control it.
iPhone to Mac
mobster phone photos pull copies the newest photos, screenshots and screen recordings, newest first: -n takes 1 to 20, --since takes 10m, 2h, 1d or an ISO time, and -o names the folder. --jpeg converts HEIC photos to JPEG over the cable.
cablereads the camera roll’s files as they are. With iCloud Photos’ Optimize iPhone Storage on, only what is on the phone comes back.wifiasks the helper app for the newest items in the library. It reads each original in pieces. An original kept only in iCloud is downloaded by the phone first. Under Limit Access, the helper app sees only items Mobster adds and items you select for it. Pull everything else over the cable.tunnelreaches the camera roll through the tunnel macOS keeps to an iPhone paired for development, over the cable or the local network, with no root and no Xcode. Mobster runs pymobiledevice3 for it, as a separate program you install yourself:pipx install pymobiledevice3. Mobster doesn’t ship it. Each call opens the tunnel again, which takes about 7 seconds. Mobster tries a listing a second time when the tunnel wasn’t up yet.icloudexports the newest originals from this Mac’s Photos library.
Several phones
Each transfer names one phone:--device (its name, id or UDID) or --profile (the phone a profile is on, in Settings › Profiles). Transfers to different phones run at the same time. Two to the same phone run one after the other.
MCP
send_media takes path, paths (up to 49 more), album and via. pull_media takes count (1 to 20), since, jpeg and via. Both need their flags, --allow-files and --allow-photos (MCP).
POST /api/transfers starts a transfer from Mobster for Mac and GET /api/transfers/{id} follows it, file by file (Content queue).