LeadShark API

Pro

Programmatic access to LinkedIn enrichment, automations, and more.

Last updated: Feb 1, 2026

Overview

The LeadShark API provides programmatic access to LinkedIn enrichment, automation management, bookmarking, and scheduled posting. Available on all paid plans (Pro, Pro+, Apex).

Base URLhttps://apex.leadshark.io

Authentication

Include your API key in the request header.

Headerx-api-key— Your API key

Getting Your API Key

  1. Log in to your LeadShark account (any paid plan)
  2. Go to Settings → API Access
  3. Generate your API key

Rate Limits

250

req/hr

Hourly

1,000

req/day

Daily

100

req/min

Burst

Exceeding limits returns 429 Too Many Requests. Use exponential backoff.

Enrichment API

Enrich LinkedIn profiles and companies with detailed data.

Automations API

Create and manage LinkedIn post engagement automations.

Template Variables

{{firstName}}John
{{fullName}}John Doe
{{linkedinUsername}}john-doe
{{firstNameMention}}@John

Bookmarks API

Save and organize LinkedIn profiles with tags and notes.

Scheduled Posts API

Schedule LinkedIn posts with optional pre-configured automations that activate when the post goes live.

Scheduling Constraints

Minimum: 15 minutes from now
Maximum: 90 days in advance

Pre-Automation Object

When the scheduled post publishes, an automation is automatically created with these settings:

FieldTypeRequiredDescription
namestringrequired*Automation name
dm_templatestringrequired*Primary DM template (max 2000 chars)
keywordsstring[]optionalTrigger keywords (max 20)
dm_templatesstring[]optionalMultiple DM templates (rotated)
comment_reply_templatestring[]optionalReply templates for comments
non_first_degree_reply_templatestring[]optionalReply for non-connections
auto_connectbooleanoptionalSend connection requests (default: false)
enable_follow_upbooleanoptionalEnable follow-up DMs (default: false)
follow_up_delay_minutesnumberoptionalDelay before follow-up (default: 60)
follow_up_only_if_no_responsebooleanoptionalOnly follow up if no reply (default: true)
follow_up_templatestringoptionalFollow-up message template
template_idstringoptionalUse existing template (makes name/dm_template optional)

* Required unless template_id is provided

File Attachments

Use multipart/form-data to upload files with your post:

Images: JPG, PNG, GIF — 5MB each
PDF: 1 file only — 50MB
Video: MP4 only — 50MB

Note: PDF and video cannot be combined with other files. Only one PDF or video per post.

Error Codes

VALIDATION_ERRORInvalid content, time, or automation config
TIME_CONFLICTAnother post scheduled at this time (15-min window)
SCHEDULING_TOO_SOONCannot edit post within 15 minutes of publish time
POST_ALREADY_PUBLISHEDCannot modify published or failed posts

Post Stats API

Retrieve analytics for your LinkedIn posts.

Error Codes

400Bad RequestInvalid parameters or malformed body
401UnauthorizedMissing or invalid API key
404Not FoundResource does not exist
429Too Many RequestsRate limit exceeded
500Server ErrorUnexpected error, try again

Need Help?

Contact our team for API support.

Contact