Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.lonescale.com/llms.txt

Use this file to discover all available pages before exploring further.

Retrieve the status and result of an async job started by lonescale enrich or lonescale source.

Synopsis

lonescale result <job-id> [--poll] [--interval <seconds>] [--timeout <seconds>]

Examples

# One-shot status check
lonescale result abc-123

# Poll every 5 seconds until the job finishes, max 3 minutes
lonescale result abc-123 --poll --interval 5 --timeout 180

# Capture only the final JSON for further processing
lonescale result abc-123 --poll --output json > results.json

Options

OptionDescription
<job-id>Required. The job ID returned by enrich or source.
--pollKeep polling until the job finishes (or until --timeout expires).
--interval <seconds>Seconds between polls (default 3).
--timeout <seconds>Max wait time before giving up (default 120).
Plus all global options.

Exit codes

CodeMeaning
0Job finished successfully (or status was returned without --poll).
1Job failed, timed out, or the CLI couldn’t reach the API. Inspect stderr for details.
This means you can chain lonescale result safely in shell scripts:
JOB_ID=$(lonescale enrich --type email --contacts c.json --output minimal)
if lonescale result "$JOB_ID" --poll --output json > results.json; then
  echo "Enrichment ready in results.json"
else
  echo "Job failed — check the logs"
fi