st.acceptInvitation
This action accepts an incoming invitation from the LinkedIn invitation manager. It supports connection requests, company-follow invitations, and newsletter-subscription invitations.
In the SDK this is the acceptInvitation method. It takes the parameters below except label and then, which exist only in workflow JSON. It returns no data: a failed action comes back in errors, with one of the error types below.
In the CLI this is linkedin connection accept <type> <url> – the command is below, under Parameters.
Constraints
⏺️ Root Start: allowed when
invitationTypeand its matching target URL are provided.
⬆️ Parent Actions: N/A.
⬇️ Child Actions: N/A.
Parameters
{
"actionType": "st.acceptInvitation",
"label": "invitation1",
"invitationType": "connect",
"personUrl": "https://www.linkedin.com/in/person1"
}In AI assistants, the MCP server runs this action as the accept_invitation tool.
In the CLI this is linkedin connection accept:
linkedin connection accept <type> <url>label(optional) – custom label for tracking this action in workflow completion.invitationType(required) – one of:connect– requirespersonUrl.companyFollow– requirescompanyUrl.newsletterSubscribe– requiresnewsletterUrl.
personUrl– public or hashed LinkedIn person URL. Allowed only forconnect.companyUrl– LinkedIn company page URL. Allowed only forcompanyFollow.newsletterUrl– LinkedIn newsletter URL. Allowed only fornewsletterSubscribe.
Provide exactly one target URL: the one required by invitationType.
Result options
- Successful invitation acceptance:
{
"actionType": "st.acceptInvitation",
"label": "invitation1",
"success": true
}label– included only if specified in the action parameters.
- No matching invitation:
{
"actionType": "st.acceptInvitation",
"label": "invitation1",
"success": false,
"error": {
"type": "noPendingRequest",
"message": "There is no matching pending incoming invitation to accept."
}
}error.typeisnoPendingRequestwhen no invitation matches the supplied type and target URL.