Skip to content

Connect Linq to Claude: Handle RCS Messaging & Media Attachments

Learn how to connect Linq to Claude using a managed MCP server. Automate iMessage, RCS, media attachments, and complex messaging workflows without writing custom integration code.

Uday Gajavalli Uday Gajavalli · · 9 min read
Connect Linq to Claude: Handle RCS Messaging & Media Attachments

If you are building autonomous support agents or automated sales outreach, connecting Linq to Claude allows your AI to native manage iMessage, RCS, and SMS conversations. To execute this, you need a Model Context Protocol (MCP) server that acts as a secure translation layer between Claude's tool-calling capabilities and Linq's messaging APIs. You can either spend weeks building and maintaining this infrastructure yourself, or use a managed integration platform like Truto to dynamically generate an authenticated MCP server URL. If your team uses ChatGPT, check out our guide on connecting Linq to ChatGPT or explore our broader architectural overview on connecting Linq to AI Agents.

Giving a Large Language Model (LLM) read and write access to a multichannel messaging platform is an engineering challenge. You have to handle multi-step media uploads, protocol-specific capability checks (iMessage vs. RCS), and strict data structures for rich app cards. Every time the API changes, you have to update your server code, redeploy, and test. This guide breaks down exactly how to use Truto to generate a secure, managed MCP server for Linq, connect it natively to Claude, and execute complex messaging workflows using natural language.

The Engineering Reality of the Linq API

A custom MCP server is a self-hosted integration layer. While the open MCP standard provides a predictable way for models to discover tools, implementing it against Linq's specific messaging architecture requires handling several edge cases.

If you decide to build a custom MCP server for Linq, you own the entire lifecycle. Here are the specific challenges you will face with this API:

Protocol-Specific Capability Routing Unlike generic SMS APIs where you simply POST a message to a number, Linq handles rich communication protocols like iMessage and RCS. Before an agent can send an iMessage, it often needs to verify if the recipient's number actually supports it. If you expose a raw messaging endpoint to Claude, it might attempt to send rich media to an SMS-only line, resulting in degraded delivery. A well-designed MCP implementation must expose capability check endpoints (/v3/capability/imessage and /v3/capability/rcs) so the agent can conditionally route its logic based on the recipient's device support.

Multi-Step Media Attachment Pipelines You cannot simply attach a file buffer to a Linq message payload. Linq requires a multi-step orchestration for media. First, you must pre-upload the file to obtain a presigned URL and a permanent attachment_id. Next, you must execute the HTTP PUT to the presigned URL. Finally, you attach the attachment_id to the actual message payload. Furthermore, Linq strictly limits file sizes to 100MB and outright rejects specific formats like WebP, SVG, and FLAC. Managing this pipeline natively inside an LLM's context window is brittle.

Strict Rate Limits and Normalization Messaging APIs are heavily rate-limited to prevent spam. When an AI agent attempts to bulk-create chats or rapidly pull message threads, Linq will inevitably return HTTP 429 Too Many Requests errors. Truto does not silently retry, throttle, or absorb these rate limits. Instead, when Linq returns a 429, Truto passes that error directly to the caller while normalizing the upstream rate limit information into standardized IETF headers (ratelimit-limit, ratelimit-remaining, ratelimit-reset). The caller (your agent framework) is responsible for reading these headers and executing its own backoff strategy.

How to Generate a Linq MCP Server with Truto

Truto dynamically generates MCP servers based on the connected integration's OpenAPI resources and documentation. Instead of writing custom JSON-RPC handlers for every Linq endpoint, Truto compiles the schemas into a single, secure endpoint.

You can create a Linq MCP server using either the Truto UI or programmatically via the API.

Method 1: Via the Truto UI

For ad-hoc agent testing or internal tools, generating a server via the dashboard takes seconds:

  1. Navigate to the Integrated Accounts page in your Truto dashboard and select your connected Linq account.
  2. Click the MCP Servers tab.
  3. Click Create MCP Server.
  4. Select your desired configuration (e.g., restrict to read methods or specific tags).
  5. Copy the generated MCP server URL (e.g., https://api.truto.one/mcp/a1b2c3d4...).

Method 2: Via the Truto API

For production deployments where you need to provision MCP servers dynamically for your customers, use the API. This creates a secure, hashed token record and returns a ready-to-use JSON-RPC 2.0 endpoint.

curl -X POST https://api.truto.one/integrated-account/{integrated_account_id}/mcp \
  -H "Authorization: Bearer YOUR_TRUTO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Linq Support Agent",
    "config": {
      "methods": ["read", "write", "custom"]
    },
    "expires_at": "2026-12-31T23:59:59Z"
  }'

Truto validates that tools exist, provisions the endpoint, and returns the URL. The URL contains a cryptographic token that securely maps to the specific Linq account.

How to Connect the MCP Server to Claude

Once you have your Truto MCP server URL, connecting it to Claude is a straightforward process. Because the URL is self-contained and handles all authentication with Linq under the hood, you do not need to manage OAuth tokens in your client.

Method A: Via the Claude UI

If you are using the desktop or web interface for Claude, you can connect the remote MCP server directly in the settings.

  1. Open Claude and navigate to Settings -> Integrations (or Connectors depending on your version).
  2. Click Add MCP Server (or Add custom connector).
  3. Paste the Truto MCP URL.
  4. Click Add.

(Note: If your team uses ChatGPT, the process is similar: go to Settings -> Apps -> Advanced settings -> enable Developer mode -> Add under Custom connectors).

Claude will immediately call the initialize and tools/list protocol methods, pulling in the Linq schemas.

Method B: Via Manual Config File (Claude Desktop)

For developers running Claude Desktop locally, you can configure the MCP server using the claude_desktop_config.json file. Because Truto provides a standard SSE/HTTP endpoint, you use the official MCP SSE transport layer to connect.

{
  "mcpServers": {
    "linq_messaging": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-sse",
        "https://api.truto.one/mcp/YOUR_TRUTO_TOKEN"
      ]
    }
  }
} Blue
}

Restart Claude Desktop. The model now has full read and write access to the specific Linq account based on your tool configuration.

Hero Tools for Linq

Truto dynamically generates tools for the Linq integration. Here are six of the highest-leverage tools available for messaging automation.

create_a_linq_capability_check_imessage

Before initiating an Apple Business Chat or iMessage thread, it is critical to verify that the recipient's phone number actually supports the protocol. This tool takes a phone number and returns a boolean availability status. Agents should use this for routing logic to decide whether to send a rich iMessage or fall back to standard SMS.

"Check if +14155552671 supports iMessage. If they do, prep a rich message format; otherwise, prep a plain text SMS format."

create_a_linq_chat

This tool creates a new Linq chat with specified participants and requires an initial outbound message. Note that Linq enforces a strict rule here: the first outbound message in a newly created chat cannot contain a link or URL. The LLM must be instructed to send a clean introductory message before following up with links.

"Create a new chat with +14155552671 from our main line +14155550000. Send a brief welcome message introducing yourself as the support assistant. Do not include any links in this first message."

create_a_linq_chat_share_contact_card

Trust is critical in B2B messaging. This tool shares the authenticated Linq account's contact card (Name and Photo Sharing) directly into an existing chat. This is highly effective during the onboarding phase of a conversation to ensure the brand name appears on the user's device instead of an unknown number.

"Share our contact card to chat ID 'chat_12345' so the customer sees our brand logo and name on their phone."

create_a_linq_attachment

Handling media in Linq is a multi-step process. This tool executes the first phase: pre-uploading a file definition to obtain a presigned URL and a permanent attachment_id. The agent provides the filename, content type, and byte size. Once the ID is generated, the agent can use it in subsequent message creation tools.

"We need to send the onboarding PDF. Pre-register an attachment named 'onboarding_guide.pdf' with a size of 1500000 bytes and content type 'application/pdf'. Return the attachment_id."

create_a_linq_message

This is the core tool for sending messages into an existing chat. It accepts the chat ID and a complex message object that can include text parts, attachment references, and rich app cards. This is used for all follow-up communications once a chat is established.

"Send a follow-up message to chat ID 'chat_12345' asking if they received the document. Include the attachment_id 'att_9876' in the message parts."

list_all_linq_message_threads

Context is everything for an LLM. Given a specific message ID, this tool retrieves the entire conversation thread in chronological order, including the originator and all replies. The agent uses this to reconstruct the timeline and understand the user's intent before drafting a response.

"Fetch the full message thread for message ID 'msg_445566'. Summarize the customer's issue based on their last three replies."

To view the complete schema details and the rest of the available operations - including bulk operations, voicememo dispatch, and webhook management - visit the Linq integration page.

Workflows in Action

Exposing individual endpoints is only the first step. The true power of an MCP server lies in how Claude strings these tools together to execute multi-step workflows. Here are two concrete examples of how an AI agent operates against the Linq API.

Workflow 1: High-Touch Customer Onboarding

When a high-value customer signs up, a sales ops agent can automate a personalized, rich-media outreach sequence.

"A new VIP client just registered with phone number +14155558888. Check if they support iMessage. If they do, create a new chat, send a welcome greeting without links, and immediately share our contact card."

Step-by-step execution:

  1. The agent calls create_a_linq_capability_check_imessage to verify the phone number.
  2. Receiving a true response, the agent calls create_a_linq_chat with the customer's number and a plain-text introductory greeting.
  3. The agent receives the chat_id from the response.
  4. The agent calls create_a_linq_chat_share_contact_card using the new chat_id to push the brand's identity to the user's device.
sequenceDiagram
  participant Claude as Claude Desktop
  participant Truto as Truto MCP
  participant Linq as Linq API
  
  Claude->>Truto: Call create_a_linq_capability_check_imessage
  Truto->>Linq: POST /v3/capability/imessage
  Linq-->>Truto: { "available": true }
  Truto-->>Claude: Returns availability
  Claude->>Truto: Call create_a_linq_chat
  Truto->>Linq: POST /v3/chats
  Linq-->>Truto: Chat object returned
  Truto-->>Claude: Returns chat_id
  Claude->>Truto: Call create_a_linq_chat_share_contact_card
  Truto->>Linq: POST /v3/chats/{chat_id}/share_contact_card
  Linq-->>Truto: 204 No Content
  Truto-->>Claude: Success

Workflow 2: Contextual Support Escalation

A support agent needs to understand an ongoing conversation and provide a technical manual based on the customer's last complaint.

"The customer in chat ID 'chat_9911' is asking for the API documentation PDF. Fetch the thread to confirm their specific issue, then prepare the attachment 'api_v2_docs.pdf' (2MB) and send it to them with a brief explanation."

Step-by-step execution:

  1. The agent calls list_all_linq_chat_messages for the specific chat ID to read the context.
  2. The agent synthesizes a response based on the conversation history.
  3. The agent calls create_a_linq_attachment providing the filename, size (2000000 bytes), and MIME type (application/pdf).
  4. Linq returns the attachment_id.
  5. The agent calls create_a_linq_chat_message using the chat_id and constructing a message part that references the new attachment_id.

Security and Access Control

Giving an AI model write access to your primary messaging channels carries inherent risk. Truto provides several configuration layers on the MCP token to restrict what Claude can do:

  • Method Filtering: You can configure the server to only allow read operations (e.g., fetching threads) and block all write operations (like sending messages or sharing cards).
  • Tag Filtering: Limit the server to only expose tools associated with specific functional areas, ensuring an agent built for reporting cannot access messaging endpoints.
  • Require API Token Auth: By default, the MCP URL is the only authentication required. Setting require_api_token_auth: true forces the client to also provide a valid Truto API token in the headers, adding a secondary identity check.
  • Expiration: You can set an expires_at timestamp when creating the MCP server. Once the timestamp passes, the server automatically self-destructs, which is ideal for temporary contractor access or limited-time testing.

Moving Past Manual Integration Debt

Building a Linq MCP server from scratch requires deep knowledge of their specific payload schemas, attachment pipelines, and protocol edge cases. By the time you finish mapping the endpoints, handling capability checks, and managing standard HTTP errors, you have built a custom middleware layer that demands constant maintenance.

Truto abstracts this away entirely. By deriving tool definitions directly from documentation and live OpenAPI specifications, Truto provides a robust, self-healing interface between Claude and Linq. If Linq introduces a new rich media card format tomorrow, the Truto MCP server dynamically reflects that capability without requiring you to deploy a single line of code.

FAQ

Does Truto handle Linq API rate limits automatically?
No. Truto passes HTTP 429 Too Many Requests errors directly back to the caller and normalizes the rate limit information into standard IETF headers (ratelimit-limit, ratelimit-remaining, ratelimit-reset). Your AI agent or application must handle its own retry and backoff logic.
Can I restrict the Claude agent to only read Linq messages?
Yes. When generating the MCP server via Truto, you can apply method filtering (e.g., config: { methods: ["read"] }) to ensure the LLM can only fetch threads and cannot send outbound messages.
How does the MCP server handle Linq media attachments?
Linq requires a multi-step process for media. The MCP server exposes tools like create_a_linq_attachment to generate a presigned URL and attachment_id. The agent uses this ID in subsequent tool calls to attach the file to a message.
How do I connect the Truto MCP URL to Claude Desktop?
You can add the MCP URL directly in Claude's UI under Settings -> Integrations -> Add MCP Server, or configure it manually in your claude_desktop_config.json using the @modelcontextprotocol/server-sse package.

More from our Blog