Explanation:
Purpose:
Run a tool, a play, a play file, or a few lines of code. One command for
all of them.
When:
After describe, once you know the inputs. For paid work, add --dry-run
first to check the input and see the price.
Input:
The id from search, and one JSON object: --input '{...}' or
--input-file input.json. A play that reads a CSV takes its path:
--input '{"csv":"leads.csv"}'. -e '<code>' runs code as a play body.
<play>@latest runs the newest revision; deepline/<id> runs Deepline's
version when your org has one with the same name. --example <name> starts
from a named example input the play declares (describe lists them);
--input fields replace the example's.
Examples:
deepline run hunter_email_verifier --input '{"email":"a@b.com"}'
deepline run person-to-email-batch --input '{"csv":"leads.csv"}' --dry-run
deepline run person-to-email-batch --input '{"csv":"leads.csv"}' --csv-out emails.csv
deepline run my.play.ts --input-file input.json --json-out result.json
deepline run -e 'return { doubled: input.n * 2 };' --input '{"n":21}'
Output:
A receipt: what ran, its status and cost, where the data was saved, and
the first values. A tool call's credentialSource says which provider key it
ran on (or, with --dry-run, would run on): managed is Deepline's key, user
is your own connected key. --receipt-out <path> writes the JSON receipt only
to that new file, even with --json. File errors go to stderr. Use --json-out - or
--csv-out - to pipe result data to stdout.
--fields picks values and CSV columns. Exit code 0 completed, 1 failed or
still running, 2 nothing ran.
A failed tool call's receipt error matches deepline tools execute:
error.retry says whether sending the same call again can succeed, and
error.upstreamResponse holds a connected provider's status and body.
Cost:
What the tool or play charges. --max-credits caps a play run's posted
charges; parallel calls in flight can end it somewhat over (plays run
--help). Running an interrupted call again replays it without paying twice.
Next:
Read the saved file. deepline runs get <id> shows the run again.