Skip to content

CLI Reference

Synopsis

unihra [--key KEY] [--limits] [--own URL] [--comp URL]... [OPTIONS]

Flags

FlagTypeDefaultDescription
--keystr$UNIHRA_API_KEYAPI key
--limitsflagoffPrint key balance and exit
--ownstrrequiredYour page URL
--compstr (repeatable)requiredCompetitor URL (pass multiple times)
--querystr (repeatable)Target search query (up to 5)
--langru|enruPage language
--cookiesstrAuth cookies for own page: "session=abc; token=xyz"
--savestrstdoutOutput file: .xlsx or .csv
--tripletsflagoffEnable Knowledge Graph mode (5 credits)
--verboseflagoffShow progress and result summary
--no-styleflagoffDisable Excel color coding and auto-widths
--retriesint0HTTP retry attempts on network/server errors

Exit Codes

CodeMeaning
0Success
1API or network error
0User interrupted (Ctrl+C)

Examples

bash
# Check balance
unihra --key sk-xxx --limits

# Minimal analysis — outputs JSON to stdout
unihra --own https://example.com --comp https://comp.com

# Full analysis with Excel report
unihra \
  --own https://example.com/product \
  --comp https://comp1.com/product \
  --comp https://comp2.com/product \
  --query "buy product" \
  --query "best product 2026" \
  --lang en \
  --save report.xlsx \
  --verbose

# Knowledge Graph
unihra --own https://example.com --comp https://comp.com --triplets --save kg.xlsx

# Pipe to jq
unihra --own https://example.com --comp https://comp.com | jq '.umbrella_analysis[:10]'