Get sent connection invitations
Retrieves sent connection invitations from LinkedIn. Returns a list of pending invitations with profile information, timestamps, and invitation IDs. Supports pagination via startIndex parameter.
/invitations/sentCode Examples
curl -X GET 'https://api.connectsafely.ai/linkedin/invitations/sent' \ -H 'Authorization: Bearer <your_api_key>'Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
accountId | query | No | string | LinkedIn account ID to use. If not provided, uses the default account. |
startIndex | query | No | number | Pagination start index (0-indexed). Use to fetch additional pages of invitations. |
Request Body
No request body.
Responses
| Status | Description |
|---|---|
| 200 | Sent invitations retrieved successfully |
| 401 | Unauthorized - invalid or missing authentication |
| 404 | No active LinkedIn account found |
| 500 | Server error while fetching invitations |
200 Response Parameters
| Name | Type | Description |
|---|---|---|
success | boolean | |
invitations | array | |
count | number | Number of invitations returned |
startIndex | number | Current pagination start index |
accountId | string | LinkedIn account ID used for the request |
200 Example
{
"success": true,
"invitations": [
{
"id": "7897046780350316544",
"invitationId": "7897046780350316544",
"invitationUrn": "urn:li:invitation:7897046780350316544",
"memberId": "ACoAADPy0YkBl72yFV0nJCqXd2F9OBxiI7Tvhg4",
"memberUrn": "urn:li:fsd_profile:ACoAADPy0YkBl72yFV0nJCqXd2F9OBxiI7Tvhg4",
"invitationType": "SENT",
"sentAt": "2 days ago",
"profile": {
"firstName": "John",
"lastName": "Doe",
"headline": "CEO | Entrepreneur | Tech Founder",
"profileUrl": "https://www.linkedin.com/in/johndoe",
"publicIdentifier": "johndoe"
}
}
],
"count": 10,
"startIndex": 0,
"accountId": "696ce9e780e0483585e4e553"
}401 Response Parameters
| Name | Type | Description |
|---|---|---|
error | string |
401 Example
{
"error": "example_value"
}404 Response Parameters
| Name | Type | Description |
|---|---|---|
error | string |
404 Example
{
"error": "example_value"
}500 Response Parameters
| Name | Type | Description |
|---|---|---|
error | string |
500 Example
{
"error": "example_value"
}Get connections list
Retrieves the list of LinkedIn connections for the authenticated user. Returns connection details including name, headline, vanity name, and connected date. Supports pagination via startIndex and limit parameters.
Get received invitations
Retrieves received invitations from LinkedIn including connection requests, organization follow invites, and newsletter subscriptions. Returns invitation details with category classification (CONNECTION, ORGANIZATION, NEWSLETTER, EVENT, MEMBER_FOLLOW). Supports pagination via startIndex parameter.
