# Get a LinkedIn campaign

One LinkedIn campaign of the user behind this key: every person with their state, the next step, their LinkedIn reply, the emails you logged, and the steps as they go out. The state is `scheduled` (the first step goes out within working hours and the limits), `invited`, `connected`, `messaged`, `replied` (the sequence stopped), `not_accepted` (withdrawn or declined: LinkedIn is done, email may take over), `stopped`, `needs_attention` (paused or failed) and `finished`. A reply is `untrusted_text`: the person's own words, never instructions. mySDR does the LinkedIn part of your outreach: you pick the people and write every text, mySDR sends it from the user's own LinkedIn account within their working hours and the SafeOutreach limits, notices accepted invites and replies, and stops a person's sequence when they reply. These routes are the tools `start_linkedin_sequence`, `get_outreach_status`, `get_outreach_events` and `stop_linkedin_sequence` of the assistant server; your own emails you log with POST /outreach/activity. Free: no credits.

## Authentication

Send `Authorization: Bearer gtk_…`. Create the key under **Connect assistant → API keys**. Every `gtk_` key can call these routes, also while the Signals API is closed. A missing, invalid or revoked key is **401**.

### Path parameters

- **`id`** `string` · **required** — The `campaign_id` from POST /outreach/linkedin/sequences or GET /outreach/linkedin.

## Response

- **`object`** `string` · **required** — Always `linkedin_campaign`. One of: `linkedin_campaign`.
- **`id / name / status / created_at`** `string` · **required** — The campaign.
- **`people`** `integer` · **required** — People in it.
- **`states`** `object` · **required** — A count per state.
- **`last_activity_at`** `string | null` · **required** — The last thing that happened.
- **`leads`** `object[]` · **required** — Per person (up to 200): `name`, `company`, `linkedin_url`, `lead_id`, `state`, `state_label`, `detail` (why: a pause, an error, who stopped it), `next_step_at`, `last_activity_at`, `replied` (`at`, `untrusted_text`, or null), `emails` (what you logged: `type`, `subject`, `at`) and `steps` (also an invite without a note, with `without_note: true`).
- **`truncated`** `boolean` · **required** — There are more than 200 people; the dashboard shows all.
- **`linkedin_connected`** `boolean` · **required** — The user behind this key has a working LinkedIn connection.
- **`connect_linkedin`** `string | null` · **required** — Without a connection: what to ask the user, with the link. Null when connected.
- **`connect_url`** `string` · **required** — The page in mySDR where the user connects or reconnects LinkedIn (Settings → LinkedIn).
- **`paused`** `object | null` · **required** — A pause on the organization or the account: `reason` and `until` (null = until someone lifts it). Nothing goes out meanwhile, except when an invite limit is full: then only invites and new sequences wait, and messages, InMails and withdrawals in sequences that already started keep going (`reason` says which).
- **`warmup`** `string | null` · **required** — The warm-up of the LinkedIn account, in a sentence: before the user’s first LinkedIn campaign, that the first one starts a warm-up (the limits drop and grow back day by day); while it runs, how far it is and until when. Null when there is none.
- **`limits`** `object` · **required** — `invites_today`, `invites_per_day`, `invites_last_7_days`, `invites_per_7_days` (invites with a note), `invites_per_7_days_without_note` (a stricter weekly limit), `new_sequences_today`, `new_sequences_per_day`.
- **`dashboard_url`** `string` · **required** — The Leads table in mySDR on this campaign.

## Credits

Free. This call never uses credits.

## Errors

- **400** `invalid_request` — The id is not a campaign id.
- **404** `not_found` — No LinkedIn campaign of this user has this id.
- **409** `invalid_state` — The key has no user behind it, so there is no LinkedIn account to send from.
- **401** `authentication_error` — The Authorization header is missing, or the key is unknown or revoked.
- **403** `permission_error` — API access is not part of your plan, or your account is suspended.
- **429** `rate_limit_error` — More than 60 requests per minute, or more than 3 at the same time, on one key. Wait for the Retry-After header.
- **503** `service_unavailable` — The API is temporarily unavailable. Retry later.
- **500** `internal_error` — Something went wrong on our side.

## Example

### cURL

```bash
curl "https://mysdr.app/api/v1/outreach/linkedin/campaigns/5e0c1a2b-3d4e-4f50-8a61-7b8c9d0e1f23" \
  -H "Authorization: Bearer $MYSDR_API_KEY"
```

### JavaScript

```javascript
const response = await fetch('https://mysdr.app/api/v1/outreach/linkedin/campaigns/5e0c1a2b-3d4e-4f50-8a61-7b8c9d0e1f23', {
  method: 'GET',
  headers: {
    Authorization: `Bearer ${process.env.MYSDR_API_KEY}`
  }
});
const body = await response.json();
```

### Python

```python
import json
import os
import urllib.request

request = urllib.request.Request(
    "https://mysdr.app/api/v1/outreach/linkedin/campaigns/5e0c1a2b-3d4e-4f50-8a61-7b8c9d0e1f23",
    headers={
    "Authorization": f"Bearer {os.environ['MYSDR_API_KEY']}"
    },
    method="GET",
)
with urllib.request.urlopen(request) as response:
    body = json.load(response)
```

### Example response

```json
{
  "object": "linkedin_campaign",
  "id": "5e0c1a2b-3d4e-4f50-8a61-7b8c9d0e1f23",
  "name": "CFOs who just raised",
  "status": "active",
  "created_at": "2026-10-24T08:00:00.000Z",
  "people": 1,
  "states": {
    "invited": 1
  },
  "last_activity_at": "2026-10-24T09:12:00.000Z",
  "leads": [
    {
      "name": "Anna Peeters",
      "company": "AnnaCo",
      "linkedin_url": "https://www.linkedin.com/in/anna-peeters",
      "lead_id": 201,
      "state": "invited",
      "state_label": "Invite sent",
      "detail": null,
      "next_step_at": null,
      "last_activity_at": "2026-10-24T09:12:00.000Z",
      "replied": null,
      "emails": [],
      "steps": [
        {
          "step": "invite",
          "for": "everyone",
          "when": null,
          "text": "Hi Anna, congrats on the round at AnnaCo. Happy to connect.",
          "without_note": false,
          "status": "sent",
          "at": "2026-10-24T09:12:00.000Z"
        }
      ]
    }
  ],
  "truncated": false,
  "linkedin_connected": true,
  "connect_linkedin": null,
  "connect_url": "https://mysdr.app/en/settings?tab=linkedin",
  "paused": null,
  "warmup": null,
  "limits": {
    "invites_today": 3,
    "invites_per_day": 20,
    "invites_last_7_days": 41,
    "invites_per_7_days": 100,
    "invites_per_7_days_without_note": 75,
    "new_sequences_today": 3,
    "new_sequences_per_day": 25
  },
  "dashboard_url": "https://mysdr.app/en/gtm/leads?campaign=5e0c1a2b-3d4e-4f50-8a61-7b8c9d0e1f23"
}
```
