---
title: Query Group
slug: query-group
createdAt: 2026-02-05T09:33:58.280Z
---

### Purpose

Returns the group code for the specified SIM.

The group returned is the **group code**, not the group name.
Available groups and group codes are distributor-specific and are provided in a separate document.

### Endpoint

```xml
POST https://api.m2miportal.com
Content-Type: application/xml
Accept: application/xml
```



### Request (XML)

```xml
<query-group version="1" api-id="123456">
  <authentication>
    <username>username</username>
    <password>password</password>
  </authentication>
  <iccid>1234567890123456789</iccid>
</query-group>
```

### Response (Success)

```xml
<query-group-response api-id="123456">
  <api-outcome>Success</api-outcome>
  <group>group-code</group>
</query-group-response>
```

:::hint{type="info"}
## Response (Failure)

If a request cannot be processed, the response will include:

- api-outcome indicating failure&#x20;
- An error description explaining the reason&#x20;

Failure responses may occur due to:

- Invalid authentication credentials&#x20;
- Invalid or unknown identifiers (for example ICCID or MSISDN)&#x20;
- Invalid or missing parameters&#x20;
- Values not permitted for the specified SIM type or account configuration&#x20;
- Insufficient permissions&#x20;

Integrating systems should validate input data before submission and implement appropriate error handling and logging.
:::

