Start or finish an auto-run
freeapply_manage_autorunStarts and finishes each auto-run applying session so FreeApply keeps applying on its own, waiting for due runs and releasing them without a scheduled task.
Instructions
Keeps FreeApply applying on its own from this session, with no scheduled task: start waits until something is due, finish ends a run (freeapply_get_status only shows the run state). Use: auto-run mode of freeapply-apply, which setup's last step enters: start with wait (takeover on the first call), finish after each run, then start again. Not in a session the user runs by hand. Behavior: start with wait holds the call up to 10 minutes while nothing is due (auto-run stopped by the user's Stop or a limit in Settings, the rest after a search found nothing new, the daily cap) and returns as soon as something is, within seconds of the user pressing Start. One session runs it at a time. A run checks in with each job-work tool call and freeapply_clear_to_submit (15 minutes without one counts as ended); freeapply_clear_to_submit with the run_id ends it at a hard stop. finish releases the run and starts the rest (autorun.every_hours), or none when the user asked for a restart with new settings; harmless on a run that already ended. Parameters: action start or finish. wait (start): hold as above; without it start answers at once. takeover (start with wait): only on the call right after the user asked for setup or to keep applying: it presses Start (clears a Stop, a reached limit and the rest) and makes this session the runner; the session it replaced gets replaced at its next start. run_id (finish): the run start returned. summary (finish): one line shown in the dashboard's run history. Returns: start {go: true, run_id, minutes (left before the time limit, null: none), max_applications, sites}; {go: false, replies_due: true}: do freeapply-replies, then start again; {go: false, needs_user: terms|setup}: ask the user (freeapply_open_dashboard), freeapply_get_status with wait, then start again; {go: false, wait_again: true}: start again; {go: false, replaced: true} or any other go false: end quietly. finish {finished, applied_this_run}, null for a run no longer active. Errors: finish without run_id; an action other than start or finish.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| wait | No | For start in auto-run mode: hold until something is due. | |
| action | Yes | start a run (with wait: when one is due); finish it. | |
| run_id | No | Required for finish. | |
| summary | No | For finish: e.g. "applied 4, needs you 2" (up to 500 characters). | |
| takeover | No | For start with wait: the call right after the user asked to start. |