Send a message (messaging wrapper)
Send a LinkedIn message using the messaging endpoint. Wrapper around the core messaging functionality with a cleaner interface. Supports regular messages and InMail.
/messaging/sendSend a message (messaging wrapper)
Send a LinkedIn message using the messaging endpoint. Wrapper around the core messaging functionality with a cleaner interface. Supports regular messages and InMail.
Code Examples
curl -X POST 'https://api.connectsafely.ai/linkedin/messaging/send' \ -H 'Authorization: Bearer <your_api_key>' \ -H 'Content-Type: application/json' \ -d '{"message":"Hello! I would like to connect with you."}'Parameters
No parameters.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
accountId | string | No | LinkedIn account ID to use. If not provided, uses the default account. |
recipientProfileId | string | No | Recipient LinkedIn profile public ID |
recipientProfileUrn | string | No | Recipient LinkedIn profile URN |
message | string | Yes | Message content to send |
subject | string | No | Subject line (required for InMail) |
messageType | string | No | Message type |
Example
{
"message": "Hello! I would like to connect with you."
}Responses
| Status | Description |
|---|---|
| 200 | Message sent successfully |
Send typing indicator
Send a typing indicator to a LinkedIn conversation. Shows the recipient that you are typing a message. Useful for creating a more natural conversation experience before sending a message.
Send message with typing indicator
Send a LinkedIn message after showing a typing indicator first. Creates a more natural conversation experience by simulating human-like behavior. Requires conversationUrn for existing conversations.
