---
type: api
title: Get machine learning information
description: Get defaults and limits used by machine learning.
url: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/elasticsearch/v9/operation/operation-ml-info
resource: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/elasticsearch/v9/operation/operation-ml-info
products:
  - Elasticsearch
---

# Get machine learning information

Availability: 6.3+

## Paths

- `GET` `/_ml/info`

- [Api key auth](/elastic/docs-builder/docs/4371/api/doc/elasticsearch/v9/authentication#apikeyauth)
- [Basic auth](/elastic/docs-builder/docs/4371/api/doc/elasticsearch/v9/authentication#basicauth)
- [Bearer auth](/elastic/docs-builder/docs/4371/api/doc/elasticsearch/v9/authentication#bearerauth)

## Description

Get defaults and limits used by machine learning.
This endpoint is designed to be used by a user interface that needs to fully
understand machine learning configurations where some options are not
specified, meaning that the defaults should be used. This endpoint may be
used to find out what those defaults are. It also provides information about
the maximum size of machine learning jobs that could run in the current
cluster configuration.

## Required authorization

* Cluster privileges: `monitor_ml`

## Response

`application/json`

- `defaults` ({} Defaults)
  - `anomaly_detectors` ({} AnomalyDetectors)
    - `categorization_analyzer` (CategorizationAnalyzer)
    - `categorization_examples_limit` (number)
    - `model_memory_limit` (string)
    - `model_snapshot_retention_days` (number)
    - `daily_model_snapshot_retention_after_days` (number)
  - `datafeeds` ({} Datafeeds)
    - `scroll_size` (number)
  - `model_platform_variant` (enum ModelPlatformVariant)
    Returns `linux-x86_64` when all ML nodes are x86, or when no ML nodes exist but the cluster is in Elastic Cloud.
Returns `platform_agnostic` otherwise.
    Values: `linux-x86_64`, `platform_agnostic`
- `limits` ({} Limits)
  - `max_single_ml_node_processors` (number)
  - `total_ml_processors` (number)
  - `max_model_memory_limit` (number | string ByteSize)
  - `effective_max_model_memory_limit` (number | string ByteSize)
  - `total_ml_memory` (number | string ByteSize)
- `upgrade_mode` (boolean)
- `native_code` ({} NativeCode)
  - `build_hash` (string)
  - `version` (string)
## Code Examples

#### Console

```console
GET _ml/info
```

#### JavaScript

```javascript
const response = await client.ml.info();
```

#### Python

```python
resp = client.ml.info()
```

#### curl

```curl
curl -X GET "$ELASTICSEARCH_URL/_ml/info" \
  -H "Authorization: ApiKey $ELASTIC_API_KEY"
```

#### Java

```java
client.ml().info();
```

#### C#

```c#
var response = await client.MachineLearning.InfoAsync();
```

#### PHP

```php
$resp = $client->ml()->info();
```

#### Ruby

```ruby
response = client.ml.info
```

