> ## Documentation Index
> Fetch the complete documentation index at: https://docs.exode.biz/llms.txt
> Use this file to discover all available pages before exploring further.

# List groups

> Get a list of school groups with filtering and pagination

## Request headers

**Authorization** `string` *required*

The service user's API token in the `Bearer YOUR_TOKEN` format. The school owner issues the token in the admin panel:
**Manage → School → For developers → API keys** — see the ["Authentication"](https://docs.exode.biz/en/exode-api/setup.md#authentication) section for details.

**Seller-Id** `integer` *required*

The numeric ID of the seller — the account the school belongs to. Copy it on the **API keys** page, in
the **Integration data → Identifiers** card. The token's permissions are checked against this ID.

**School-Id** `integer` *required*

The numeric ID of the school, found in the same place as `Seller-Id`. The value must match the seller's school — otherwise
a `400` error with `cause: "ForbiddenSchoolMismatch"` is returned.

```
GET /saas/v2/group/list/raw
```

> [!WARNING]
>
> **Course visibility restrictions do not apply to the API.** A course has access modes
> for the school team ("All" / "Assigned") that hide a restricted course from managers
> in the interface. The API returns data for all school courses regardless of these modes:
> access is determined only by the service user's token and its permissions.

> [!NOTE]
>
> All filter parameters are optional. If you pass no filters, all school groups are returned,
> subject to pagination.

> [!NOTE]
>
> Pass array parameters by repeating the parameter in the query string: `groupIds=1&groupIds=2&groupIds=3`.

## Request parameters

### Pagination

**skip** `integer`

Number of records to skip. Default: `0`.

**page** `integer`

Page number (an alternative to `skip`). Starts at `1`.

**take** `integer`

Number of records per page. From `1` to `1000`. Default: `100`.

### Filtering

**groupIds** `integer[]`

Filter by group IDs.

**productIds** `integer[]`

Filter by IDs of the products the groups are linked to.

**courseIds** `integer[]`

Filter by course IDs.

**search** `string`

Search by group name. Maximum 50 characters.

## Response fields

**payload** `object`

Paginated list of groups (compact projection). For the full structure, see the
[`group`](https://docs.exode.biz/en/exode-api/objects/entities/group) reference.

**payload properties**

**items** `object[]`

Array of groups.

**Item properties**

**groupId** `integer`

Group ID.

**name** `string`

Group name.

**courseId** `integer | null`

ID of the linked course.

**courseName** `string | null`

Name of the linked course.

**membersCount** `integer`

Number of group members.

**page** `integer`

Current page.

**count** `integer`

Total number of records.

**pages** `integer`

Total number of pages.

**isFirst** `boolean`

Whether this is the first page.

**isLast** `boolean`

Whether this is the last page.

**next** `object`

Next page parameters (`skip`, `take`, `page`).

**prev** `object`

Previous page parameters (`skip`, `take`, `page`).

```bash cURL theme={null}
curl --location 'https://api.exode.biz/saas/v2/group/list/raw?take=20&courseIds=10' \
  --header 'Seller-Id: {{ sellerId }}' \
  --header 'School-Id: {{ schoolId }}' \
  --header 'Authorization: Bearer YOUR_TOKEN'
```

```javascript Node.js theme={null}
const axios = require('axios');

const listGroups = async () => {
  const { data } = await axios.get('https://api.exode.biz/saas/v2/group/list/raw', {
    params: { take: 20, courseIds: [10] },
    headers: {
      'Seller-Id': '{{ sellerId }}',
      'School-Id': '{{ schoolId }}',
      'Authorization': 'Bearer YOUR_TOKEN',
    },
  });

  console.log(data.payload.items);
};

listGroups();
```

```php PHP theme={null}
<?php

$url = 'https://api.exode.biz/saas/v2/group/list/raw?take=20&courseIds=10';
$headers = [
  'Seller-Id: {{ sellerId }}',
  'School-Id: {{ schoolId }}',
  'Authorization: Bearer YOUR_TOKEN'
];

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

echo curl_exec($ch);
curl_close($ch);
?>
```

```python Python theme={null}
import requests

url = 'https://api.exode.biz/saas/v2/group/list/raw'
headers = {
  'Seller-Id': '{{ sellerId }}',
  'School-Id': '{{ schoolId }}',
  'Authorization': 'Bearer YOUR_TOKEN'
}

response = requests.get(url, params={ 'take': 20, 'courseIds': [10] }, headers=headers)
print(response.json())
```

```bsl 1С theme={null}
Соединение = Новый HTTPСоединение("api.exode.biz", 443, , , , 30, Новый OpenSSLSecureConnection);

Запрос = Новый HTTPЗапрос("/saas/v2/group/list/raw?take=20&courseIds=10");
Запрос.Заголовки.Вставить("Seller-Id", "{{ sellerId }}");
Запрос.Заголовки.Вставить("School-Id", "{{ schoolId }}");
Запрос.Заголовки.Вставить("Authorization", "Bearer YOUR_TOKEN");

Ответ = Соединение.ВызватьHTTPМетод("GET", Запрос);

Если Ответ.КодСостояния = 200 Тогда
    ЧтениеJSON = Новый ЧтениеJSON;
    ЧтениеJSON.УстановитьСтроку(Ответ.ПолучитьТелоКакСтроку());
    Результат = ПрочитатьJSON(ЧтениеJSON);
    Сообщить("Group list received");
Иначе
    Сообщить("Error: HTTP " + Ответ.КодСостояния);
    Сообщить(Ответ.ПолучитьТелоКакСтроку());
КонецЕсли;
```

```json Success theme={null}
{
  "success": true,
  "code": 200,
  "payload": {
    "page": 1,
    "count": 1,
    "pages": 1,
    "isFirst": true,
    "isLast": true,
    "items": [
      {
        "groupId": 501,
        "name": "Cohort #1",
        "courseId": 10,
        "courseName": "Exam preparation",
        "membersCount": 42
      }
    ],
    "next": {
      "skip": 20,
      "take": 20,
      "page": 2
    },
    "prev": {
      "skip": 0,
      "take": 20,
      "page": 1
    }
  }
}
```

## Permission requirements

> [!TIP]
>
> Requires token authentication and the [**"School User Management"**](https://docs.exode.biz/en/exode-api/permissions.md) permission (`SchoolManageUsers`).

***

*Updated: 2026-09-25 14:33 UTC*


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.