> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.messageblue.ai/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.messageblue.ai/_mcp/server.

# Check whether a participant set would be an iMessage or text group

POST https://api.messageblue.ai/checkGroupIMessage
Content-Type: application/json

Opens Messages on a Mac agent, adds the participants to a new compose window (without sending), and reads whether the draft is iMessage or SMS/Text Message — same UI signal as checkIMessage. Does not create a group or send a message. A group is iMessage only when the compose UI shows iMessage for that participant set.

Reference: https://docs.messageblue.ai/api-reference/messages/check-group-i-message

## OpenAPI Specification

```yaml
openapi: 3.1.0
info:
  title: swagger
  version: 1.0.0
paths:
  /checkGroupIMessage:
    post:
      operationId: checkGroupIMessage
      summary: Check whether a participant set would be an iMessage or text group
      description: >-
        Opens Messages on a Mac agent, adds the participants to a new compose
        window (without sending), and reads whether the draft is iMessage or
        SMS/Text Message — same UI signal as checkIMessage. Does not create a
        group or send a message. A group is iMessage only when the compose UI
        shows iMessage for that participant set.
      tags:
        - messages
      parameters:
        - name: X-App-Id
          in: header
          description: >-
            Your MessageBlue App ID, sent in clear on every request. It is
            paired with request signing: each request is also signed with your
            App Secret (see the **Authentication** tag). The App Secret itself
            is NEVER transmitted — it is only the HMAC signing key.
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Check completed
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CheckGroupIMessageResponse'
        '400':
          description: Validation error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Unauthorized (HMAC)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '500':
          description: Server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '503':
          description: Agent offline
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '504':
          description: Agent or queue timeout
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CheckGroupIMessageRequest'
servers:
  - url: https://api.messageblue.ai
    description: Production
  - url: http://localhost:8080
    description: Local development
components:
  schemas:
    CheckGroupIMessageRequest:
      type: object
      properties:
        participants:
          type: array
          items:
            type: string
          description: >-
            At least two distinct phone numbers (E.164) or email handles to
            evaluate as a group.
        agent:
          type: string
          description: >-
            Optional agent iMessage number to run the check. Must be owned by
            the caller's account. If omitted, uses any online agent owned by the
            account.
        agentNumber:
          type: string
          description: Alias of agent (createGroupChat-style field name).
        force:
          type: boolean
          default: false
          description: >-
            If true, skip chat.db and use Messages buddy-check for every
            participant.
      required:
        - participants
      title: CheckGroupIMessageRequest
    CheckGroupIMessageResultService:
      type: string
      enum:
        - iMessage
        - SMS
        - mixed
        - unknown
      description: Aggregate group service. mixed means some iMessage and some SMS/text.
      title: CheckGroupIMessageResultService
    CheckGroupIMessageParticipantResultService:
      type: string
      enum:
        - iMessage
        - SMS
        - unknown
        - error
        - timeout
      title: CheckGroupIMessageParticipantResultService
    CheckGroupIMessageParticipantResult:
      type: object
      properties:
        handle:
          type: string
        isIMessage:
          type: boolean
        service:
          $ref: '#/components/schemas/CheckGroupIMessageParticipantResultService'
        source:
          type: string
          description: >-
            How this handle was resolved (e.g. handle_table, chat_guid,
            buddy_check).
      title: CheckGroupIMessageParticipantResult
    CheckGroupIMessageResult:
      type: object
      properties:
        agent:
          type: string
          description: Agent that performed the check.
        isIMessageGroup:
          type: boolean
          description: >-
            True only when every participant is iMessage-capable (same gate as
            createGroupChat).
        service:
          $ref: '#/components/schemas/CheckGroupIMessageResultService'
          description: >-
            Aggregate group service. mixed means some iMessage and some
            SMS/text.
        participants:
          type: array
          items:
            $ref: '#/components/schemas/CheckGroupIMessageParticipantResult'
      title: CheckGroupIMessageResult
    ResponseMeta:
      type: object
      properties:
        requestId:
          type: string
          format: uuid
        timestamp:
          type: string
          format: date-time
      required:
        - requestId
        - timestamp
      title: ResponseMeta
    CheckGroupIMessageResponse:
      type: object
      properties:
        ok:
          type: boolean
        data:
          $ref: '#/components/schemas/CheckGroupIMessageResult'
          description: Endpoint-specific payload wrapped in a standard success envelope.
        meta:
          $ref: '#/components/schemas/ResponseMeta'
      required:
        - ok
        - data
        - meta
      title: CheckGroupIMessageResponse
    FieldError:
      type: object
      properties:
        field:
          type: string
        issue:
          type: string
        message:
          type: string
      required:
        - field
        - issue
        - message
      title: FieldError
    ErrorResponseErrorDetails0:
      type: array
      items:
        $ref: '#/components/schemas/FieldError'
      title: ErrorResponseErrorDetails0
    ErrorResponseErrorDetails:
      oneOf:
        - $ref: '#/components/schemas/ErrorResponseErrorDetails0'
        - type: object
          additionalProperties:
            description: Any type
      description: Field validation errors (array) or domain-specific context (object).
      title: ErrorResponseErrorDetails
    ErrorResponseError:
      type: object
      properties:
        code:
          type: string
        message:
          type: string
        requestId:
          type: string
          format: uuid
        details:
          $ref: '#/components/schemas/ErrorResponseErrorDetails'
          description: Field validation errors (array) or domain-specific context (object).
      required:
        - code
        - message
        - requestId
      title: ErrorResponseError
    ErrorResponse:
      type: object
      properties:
        ok:
          type: boolean
        error:
          $ref: '#/components/schemas/ErrorResponseError'
      required:
        - ok
        - error
      title: ErrorResponse
  securitySchemes:
    appId:
      type: apiKey
      in: header
      name: X-App-Id
      description: >-
        Your MessageBlue App ID, sent in clear on every request. It is paired
        with request signing: each request is also signed with your App Secret
        (see the **Authentication** tag). The App Secret itself is NEVER
        transmitted — it is only the HMAC signing key.

```

## Examples



**Request**

```json
{
  "participants": [
    "+14155551234",
    "+14155556789"
  ]
}
```

**Response**

```json
{
  "ok": true,
  "data": {
    "agent": "+14155550123",
    "isIMessageGroup": true,
    "service": "iMessage",
    "participants": [
      {
        "handle": "+14155551234",
        "isIMessage": true,
        "service": "iMessage",
        "source": "buddy_check"
      },
      {
        "handle": "+14155556789",
        "isIMessage": true,
        "service": "iMessage",
        "source": "buddy_check"
      }
    ]
  },
  "meta": {
    "requestId": "550e8400-e29b-41d4-a716-446655440000",
    "timestamp": "2026-07-10T06:00:00.000Z"
  }
}
```

**SDK Code**

```python
import requests

url = "https://api.messageblue.ai/checkGroupIMessage"

payload = { "participants": ["+14155551234", "+14155556789"] }
headers = {
    "X-App-Id": "<apiKey>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript
const url = 'https://api.messageblue.ai/checkGroupIMessage';
const options = {
  method: 'POST',
  headers: {'X-App-Id': '<apiKey>', 'Content-Type': 'application/json'},
  body: '{"participants":["+14155551234","+14155556789"]}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.messageblue.ai/checkGroupIMessage"

	payload := strings.NewReader("{\n  \"participants\": [\n    \"+14155551234\",\n    \"+14155556789\"\n  ]\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("X-App-Id", "<apiKey>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api.messageblue.ai/checkGroupIMessage")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["X-App-Id"] = '<apiKey>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"participants\": [\n    \"+14155551234\",\n    \"+14155556789\"\n  ]\n}"

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.messageblue.ai/checkGroupIMessage")
  .header("X-App-Id", "<apiKey>")
  .header("Content-Type", "application/json")
  .body("{\n  \"participants\": [\n    \"+14155551234\",\n    \"+14155556789\"\n  ]\n}")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.messageblue.ai/checkGroupIMessage', [
  'body' => '{
  "participants": [
    "+14155551234",
    "+14155556789"
  ]
}',
  'headers' => [
    'Content-Type' => 'application/json',
    'X-App-Id' => '<apiKey>',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api.messageblue.ai/checkGroupIMessage");
var request = new RestRequest(Method.POST);
request.AddHeader("X-App-Id", "<apiKey>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"participants\": [\n    \"+14155551234\",\n    \"+14155556789\"\n  ]\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "X-App-Id": "<apiKey>",
  "Content-Type": "application/json"
]
let parameters = ["participants": ["+14155551234", "+14155556789"]] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.messageblue.ai/checkGroupIMessage")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```