Skip to main content
You connect an account and want its LinkedIn inbox inside your product. Two approaches work. Pick the one that matches how your product stores data — both use the same real-time webhooks for new messages.

1. On-demand with a cache

Nothing to import. You read LinkedIn when a user looks at something, and the webhook keeps what you cached up to date.
  1. Inbox screen — list_inbox, paginated with cursor. To refresh it, pass since (your last refresh, in ms): you only get the conversations that moved.
  2. Opening a conversation — get_conversation with count (e.g. 25). When the user scrolls up, call it again with the returned next_cursor to load older messages.
  3. New messages — a webhook subscribed to messages, with message_type: "all" to also get what the account sends. Append each message event to the conversation you cached, keyed by metadata.conversation_urn.

2. Full sync into your storage

You keep every message in your database. Import the history once, then let real time take over — everything arrives through the same webhook, in the same format.
  1. Create the webhook (events: all or message_received, message_type: "all").
  2. Call POST /v2/accounts/{account_id}/sync right after connecting the account. LinkupAPI reads the inbox in the background and posts every message to your webhook, conversation by conversation.
  3. Real time continues on the same webhook as soon as the account is connected. Messages delivered by real time are never sent again by the sync.
A sync POST carries up to 25 messages of one conversation under events. Each item is exactly the event object of a real-time message webhook, so one parser handles both:
Sync webhook (several messages)
Real-time webhook (one message)
One line normalizes both:
Synced messages can be months old. If you run automations on incoming messages (auto-replies, sequences stopping on a reply), skip the ones carrying sync_id or catch_up: true.

Both approaches: nothing is lost

If the real-time connection of an account is interrupted (network, proxy, reconnection), LinkupAPI catches up the messages of the gap automatically and delivers them to your webhook as normal message events with a top-level catch_up: true.