Skip to content
V2 (Legacy) API ReferenceGet started

Add a participant to a chat

client.chats.participants.add(stringchatID, ParticipantAddParams { handle } body, RequestOptionsoptions?): ParticipantAddResponse { message, status, trace_id }
POST/v3/chats/{chatId}/participants

Add a new participant to an existing group chat.

Requirements:

  • Group chats only (3+ existing participants)
  • New participant must support the same messaging service as the group
  • Cross-service additions not allowed (e.g., can’t add RCS-only user to iMessage group)
  • For cross-service scenarios, create a new chat instead
ParametersExpand Collapse
chatID: string
formatuuid
body: ParticipantAddParams { handle }
handle: string

Phone number (E.164 format) or email address of the participant to add

ReturnsExpand Collapse
ParticipantAddResponse { message, status, trace_id }
message?: string
status?: string
trace_id?: string

Add a participant to a chat

import LinqAPIV3 from '@linqapp/sdk';

const client = new LinqAPIV3({
  apiKey: process.env['LINQ_API_V3_API_KEY'], // This is the default and can be omitted
});

const response = await client.chats.participants.add('550e8400-e29b-41d4-a716-446655440000', {
  handle: '+12052499136',
});

console.log(response.trace_id);
{
  "message": "Participant addition queued",
  "status": "accepted",
  "trace_id": "trace_id"
}
{
  "error": {
    "status": 400,
    "code": 1002,
    "message": "Phone number must be in E.164 format"
  },
  "success": false
}
{
  "error": {
    "status": 401,
    "code": 2004,
    "message": "Unauthorized - missing or invalid authentication token"
  },
  "success": false
}
{
  "error": {
    "status": 404,
    "code": 2001,
    "message": "Resource not found"
  },
  "success": false
}
{
  "error": {
    "status": 500,
    "code": 3006,
    "message": "Internal server error"
  },
  "success": false
}
Returns Examples
{
  "message": "Participant addition queued",
  "status": "accepted",
  "trace_id": "trace_id"
}
{
  "error": {
    "status": 400,
    "code": 1002,
    "message": "Phone number must be in E.164 format"
  },
  "success": false
}
{
  "error": {
    "status": 401,
    "code": 2004,
    "message": "Unauthorized - missing or invalid authentication token"
  },
  "success": false
}
{
  "error": {
    "status": 404,
    "code": 2001,
    "message": "Resource not found"
  },
  "success": false
}
{
  "error": {
    "status": 500,
    "code": 3006,
    "message": "Internal server error"
  },
  "success": false
}