cornersight-cli
v0.5.0
Published
JSON-first CLI for the Cornersight Public API.
Readme
cornersight-cli
JSON-first CLI for the Cornersight Public API.
Current version: v0.5.0 — published as cornersight-cli (unscoped). The older scoped
@cornersight/cli package is no longer maintained; install cornersight-cli.
Install
npm install -g cornersight-cli…or run without installing via npx cornersight-cli <command>. The installed binary is cornersight.
Usage
npx cornersight-cli enrich-profile --api-key cs_xxx --username demo-profile --save-tracked-profile
npx cornersight-cli enrich-profile --api-key cs_xxx --username demo-profile --no-wait
npx cornersight-cli job-status --api-key cs_xxx --job-id 00000000-0000-4000-8000-000000000001All output is valid JSON. Operational commands require --api-key; environment variables are not read.
Help
npx cornersight-cli --help
npx cornersight-cli enrich-profile --helpHelp output is JSON and does not require an API key.
Commands
All 41 commands are listed below (this table mirrors the command registry and is test-guarded, so it can't drift). Run npx cornersight-cli --help for the same list as JSON, or npx cornersight-cli <command> --help for a command's flags.
| Command | Method | Endpoint | Description |
| --- | --- | --- | --- |
| enrich-profile | POST | /api/v1/enrich/profile | Create a profile enrichment job. |
| enrich-company | POST | /api/v1/enrich/company | Create a company enrichment job. |
| get-webhook | GET | /api/v1/profile/{username}/webhook | Show a tracked profile's webhook configuration (URL and delivery flags). |
| set-webhook | PUT | /api/v1/profile/{username}/webhook | Configure a tracked profile's webhook (partial update: only the flags you pass change). |
| company-get-webhook | GET | /api/v1/company/{username}/webhook | Show a tracked company page's webhook configuration. |
| company-set-webhook | PUT | /api/v1/company/{username}/webhook | Configure a tracked company page's webhook (partial update). |
| sync-status | GET | /api/v1/profile/{username}/sync | Check a tracked profile's background capture sync: stage, progress counts, and whether it has finished. |
| company-sync-status | GET | /api/v1/company/{username}/sync | Check a tracked company page's background capture sync: stage, progress counts, and whether it has finished. |
| untrack-profile | DELETE | /api/v1/profile/{username} | Stop tracking a LinkedIn profile — deletes it and everything synced from it (destructive). |
| untrack-company | DELETE | /api/v1/company/{username} | Stop tracking a LinkedIn company page — deletes it and everything synced from it (destructive). |
| profile-posts | POST | /api/v1/profile/posts | Create a job that fetches posts for a tracked LinkedIn profile. |
| company-posts | POST | /api/v1/company/posts | Create a job that fetches posts for a tracked LinkedIn company page. |
| post-reactions | POST | /api/v1/post/reactions | Create a job that fetches reactions for a tracked LinkedIn post. |
| post-comments | POST | /api/v1/post/comments | Create a job that fetches comments for a tracked personal-profile LinkedIn post. |
| company-post-comments | POST | /api/v1/post/company-comments | Create a job that fetches comments for a tracked company-page LinkedIn post. |
| job-status | GET | /api/v1/jobs/{jobId}/status | Read the current status for a Public API job. |
| credits | GET | /api/v1/credits | Get the team's enriching credit balance (balance, used, limit, remaining, plan, nextReset). |
| credits-usage | GET | /api/v1/credits/usage | Get a dated + by-source breakdown of enriching credits charged (defaults to the current billing period). |
| leads-list | GET | /api/v1/leads | List/query captured leads for your tracked profiles (no post re-sweep needed). |
| engagers-list | GET | /api/v1/engagers | List your top engagers — captured leads aggregated to one row per person with an engagement count. The highest-intent signal (who engages most with your content). |
| campaigns-list | GET | /api/v1/campaigns | List the team's LinkedIn outreach campaigns with basic KPIs. |
| campaign-leads | GET | /api/v1/campaigns/{id}/leads | List a campaign's contacts with per-contact status and the reason any of them failed. |
| campaigns-add-leads | POST | /api/v1/campaigns/{id}/leads | Enroll a lead (by LinkedIn URL) into a campaign. |
| inbox-list | GET | /api/v1/inbox/messages | List recent LinkedIn inbox messages (most recent 50). |
| sources | GET | /api/v1/sources | List the LinkedIn people/company pages this team tracks as lead sources (each source's id is the profileId for leads-list). |
| inbox-contact | GET | /api/v1/inbox/contacts/{leadUuid} | Resolve a lead uuid to the contact behind it (name, LinkedIn handle + URL, headline, company, pipeline stage). |
| inbox-reply | POST | /api/v1/inbox/reply | Send a LinkedIn message/reply from a sender to a lead. |
| campaigns-create | POST | /api/v1/campaigns | Create a LinkedIn outreach campaign from a step definition (saved as a draft). |
| senders-list | GET | /api/v1/senders | List the team's LinkedIn senders with live connection status. |
| campaigns-activate | POST | /api/v1/campaigns/{id}/activate | Activate a campaign (start its LinkedIn flow). |
| campaigns-pause | POST | /api/v1/campaigns/{id}/pause | Pause a campaign (stop its LinkedIn flow; resume by re-activating). |
| campaigns-get | GET | /api/v1/campaigns/{id} | Get a single campaign's detail (steps, settings, live KPIs). |
| campaigns-update | PATCH | /api/v1/campaigns/{id} | Update a campaign — send only the fields you are changing (at least one). |
| campaigns-delete | DELETE | /api/v1/campaigns/{id} | Delete a campaign and tear down its LinkedIn flow. DESTRUCTIVE — there is no undo. |
| pipeline-stages-list | GET | /api/v1/pipeline-stages | List the team's CRM pipeline stages (lead object). |
| senders-get | GET | /api/v1/senders/{uuid} | Get a single sender's detail (status, schedule, limits, metrics). |
| senders-connect | POST | /api/v1/senders | Connect a new LinkedIn sender (billable — gated by your plan's seat limit). |
| senders-update-schedule | PUT | /api/v1/senders/{uuid}/schedule | Update a sender's working-hours schedule (timezone + weekly windows). |
| senders-update-limits | PUT | /api/v1/senders/{uuid}/limits | Update a sender's auto-task daily limits. |
| senders-pause | POST | /api/v1/senders/{uuid}/pause | Pause a sender (stop its managed browser). |
| senders-resume | POST | /api/v1/senders/{uuid}/resume | Resume a paused sender (start its managed browser). |
Credits
Enrichment charges ~1 credit per newly enriched lead; already-enriched, failed, and empty leads are not charged. Check your balance before a large run and reconcile spend afterwards.
# Balance: { balance, used, limit, remaining, plan, resetAt, nextReset }
npx cornersight-cli credits --api-key cs_xxx
# Usage breakdown (defaults to the current billing period): { from, to, totalCharged, bySource, byDate }
npx cornersight-cli credits-usage --api-key cs_xxx
npx cornersight-cli credits-usage --api-key cs_xxx --from 2026-07-01T00:00:00Z --to 2026-07-18T00:00:00ZEach enrich-profile/enrich-company job result also carries a creditsCharged field so you can reconcile per call.
Outreach automation
The CLI also drives LinkedIn outreach (campaigns, inbox, senders). GetSales is internal — you only use your cs_ key.
# Campaigns
npx cornersight-cli campaigns-list --api-key cs_xxx
npx cornersight-cli campaigns-get --api-key cs_xxx --campaign-id <id>
npx cornersight-cli campaigns-create --api-key cs_xxx --name "Q3" --tree '[{"type":"connection_request","config":{"note":"Hi"}}]'
npx cornersight-cli campaigns-activate --api-key cs_xxx --campaign-id <id>
npx cornersight-cli campaigns-pause --api-key cs_xxx --campaign-id <id>
npx cornersight-cli campaigns-add-leads --api-key cs_xxx --campaign-id <id> --linkedin-url https://linkedin.com/in/x
# Inbox
npx cornersight-cli inbox-list --api-key cs_xxx
npx cornersight-cli inbox-reply --api-key cs_xxx --sender-profile-uuid <u> --lead-uuid <u> --text "Thanks!"
# Senders
npx cornersight-cli senders-list --api-key cs_xxx
npx cornersight-cli senders-get --api-key cs_xxx --sender-uuid <u>
npx cornersight-cli senders-connect --api-key cs_xxx --first-name A --last-name B # billable, seat-gated
npx cornersight-cli senders-update-limits --api-key cs_xxx --sender-uuid <u> --daily-limits '{"linkedin_connection_request":20}'
npx cornersight-cli senders-pause --api-key cs_xxx --sender-uuid <u>
# Pipeline
npx cornersight-cli pipeline-stages-list --api-key cs_xxxRequests are rate limited per team (120 reads/min, 60 writes/min); 429 responses include Retry-After.
