Skip to content
V2 (Legacy) API ReferenceGet started
Getting Started

Quickstart

Send your first message in under 5 minutes.

This guide walks you through sending your first message with the Linq Partner API.

Before you begin, make sure you have:

  • A bearer token from your Linq representative
  • At least one phone number provisioned on your account
  • A recipient phone number in E.164 format (e.g., +15556667777)
Terminal window
npm install @linqapp/sdk

Create a chat and send a message in a single request:

Terminal window
curl -X POST https://api.linqapp.com/api/partner/v3/chats \
-H "Authorization: Bearer $LINQ_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"from": "+12223334444",
"to": ["+15556667777"],
"message": {
"parts": [
{ "type": "text", "value": "Hello from Linq!" }
]
}
}'

You’ll receive a response with the chat details and message status:

{
"id": "550e8400-e29b-41d4-a716-446655440000",
"is_group": false,
"last_message": {
"id": "6ba7b810-9dad-11d1-80b4-00c04fd430c8",
"parts": [
{ "type": "text", "value": "Hello from Linq!" }
],
"sent_at": "2026-02-05T19:52:17.219Z",
"service": "iMessage"
}
}

Once you have a chat ID, send additional messages to the same conversation:

Terminal window
curl -X POST https://api.linqapp.com/api/partner/v3/chats/{chat_id}/messages \
-H "Authorization: Bearer $LINQ_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"parts": [
{ "type": "text", "value": "Following up!" }
]
}'

To receive real-time notifications when messages are delivered, read, or received, create a webhook subscription:

Terminal window
curl -X POST https://api.linqapp.com/api/partner/v3/webhook-subscriptions \
-H "Authorization: Bearer $LINQ_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"target_url": "https://your-server.com/webhook?version=2026-02-03",
"subscribed_events": [
"message.sent",
"message.received",
"message.delivered",
"message.read",
"message.failed"
]
}'

Tip: If no version is specified, the subscription uses the latest available version at creation time. Pass ?version=YYYY-MM-DD explicitly to pin a specific payload format. See Webhooks → Versioning and Signature verification.