Sending connection requests
This endpoint allows you to send connection requests to specified people.
POST https://api.linkedapi.io/account/connections.sendRequest
Body
{
"requests": [
{
"person": "https://www.linkedin.com/in/person1",
"message": "Hi, I’d like to connect with you to discuss potential collaboration.",
"email": "example1@gmail.com"
},
{
"person": "https://www.linkedin.com/in/person2",
"message": "It would be great to add you to my network!"
},
{
"person": "https://www.linkedin.com/in/person3"
}
]
}
person
– LinkedIn URL of the person you want to send a connection request to.message
(optional) – note to include with the connection request.email
(optional) – email address required by some people for sending connection requests to them. If it is required and not provided, the connection request will fail.
Response
- If all connection requests are successful:
{
"status": "complete",
"completion": [
{
"person": "https://www.linkedin.com/in/person1",
"result": {
"success": true
}
},
{
"person": "https://www.linkedin.com/in/person2",
"result": {
"success": true
}
},
{
"person": "https://www.linkedin.com/in/person3",
"result": {
"success": true
}
}
]
}
- If some connection requests are unsuccessful:
{
"status": "complete",
"completion": [
{
"person": "https://www.linkedin.com/in/person1",
"result": {
"success": true
}
},
{
"person": "https://www.linkedin.com/in/person2",
"result": {
"success": false,
"error": {
"errorType": "emailRequired"
"message": "The person requires an email address to send a connection request."
}
}
},
{
"person": "https://www.linkedin.com/in/person3",
"result": {
"success": false,
"error": {
"errorType": "alreadyConnected"
"message": "Your LinkedIn account is already connected with this person."
}
}
}
]
}
errorType
– enum with the following possible values:personNotFound
– provided URL is not an existing LinkedIn person.alreadyPending
– connection request to this person has already been sent and is still pending.alreadyConnected
– your LinkedIn account is already connected with this person.emailRequired
– person requires an email address to send a connection request.requestNotAllowed
– LinkedIn has restricted sending a connection request to this person. This can happen for the following reasons:- The person has disabled connection requests in their privacy settings.
- You recently sent and withdrew a connection request to this person.
- You have reached LinkedIn's daily, weekly, or monthly limits for sending connection requests.
Throughout the documentation, for simplicity, only the request body and final response (when status is
complete
) are shown. Consider possible global errors and result handling options for proper implementation.