# INSEE Melodi observations query

Observations of an INSEE Melodi dataset (population, census, income, employment, prices...) filtered by geography. Needs dataset.

Observations of an INSEE Melodi dataset (population, census, income, employment, prices...) filtered by geography (GEO codes such as 'COM-75056', 'DEP-69', 'REG-84'), time period and up to three other dimensions (e.g. SEX=F, AGE=Y_GE65). Each observation lists its dimension codes and measured value. Fetch a few rows first to see a dataset's dimension names.

- Tool ID: `insee/melodi-data`
- Provider: [INSEE](/providers/insee.md)
- Capability: [Knowledge & research](/tools/knowledge.md)
- Price: no charge per call
- Authentication: an authorised Agentik workspace is required for execution, including zero-price tools.

## Pricing contract

No charge per call. A workspace is still needed so your agent can call it.


```json
{
  "model": "per_call",
  "amountUsd": 0
}
```

## Complete input schema


```json
{
  "type": "object",
  "properties": {
    "dataset": {
      "type": "string",
      "pattern": "^D[SD]_[A-Z0-9_]{2,80}$",
      "description": "Melodi dataset id, e.g. 'DS_RP_POPULATION_PRINC'"
    },
    "geo": {
      "type": "array",
      "items": {
        "type": "string",
        "pattern": "^[A-Za-z0-9_-]{2,30}$"
      },
      "maxItems": 20,
      "description": "Geography codes, e.g. ['COM-75056', 'COM-69123'] (communes), 'DEP-75', 'REG-11'"
    },
    "time_period": {
      "type": "array",
      "items": {
        "type": "string",
        "pattern": "^[0-9]{4}[0-9A-Z-]{0,6}$"
      },
      "maxItems": 20,
      "description": "Periods, e.g. ['2022'] or ['2024-01']"
    },
    "dimension_1": {
      "type": "string",
      "pattern": "^[A-Z][A-Z0-9_]{0,40}$",
      "description": "Name of another dimension to filter, e.g. 'SEX'"
    },
    "value_1": {
      "type": "string",
      "pattern": "^[A-Za-z0-9_.-]{1,40}$",
      "description": "Code for dimension_1, e.g. 'F'"
    },
    "dimension_2": {
      "type": "string",
      "pattern": "^[A-Z][A-Z0-9_]{0,40}$",
      "description": "Name of a second dimension to filter, e.g. 'AGE'"
    },
    "value_2": {
      "type": "string",
      "pattern": "^[A-Za-z0-9_.-]{1,40}$",
      "description": "Code for dimension_2, e.g. 'Y_GE65'"
    },
    "dimension_3": {
      "type": "string",
      "pattern": "^[A-Z][A-Z0-9_]{0,40}$",
      "description": "Name of a third dimension to filter, e.g. 'RP_MEASURE'"
    },
    "value_3": {
      "type": "string",
      "pattern": "^[A-Za-z0-9_.-]{1,40}$",
      "description": "Code for dimension_3, e.g. 'POP'"
    },
    "max_results": {
      "type": "integer",
      "minimum": 1,
      "maximum": 500,
      "default": 50,
      "description": "Observations per page, e.g. 50"
    },
    "page": {
      "type": "integer",
      "minimum": 1,
      "maximum": 10000,
      "default": 1,
      "description": "Page number, e.g. 1"
    }
  },
  "required": [
    "dataset"
  ],
  "additionalProperties": false
}
```

## Published example

This is the provider tool’s published example. Replace example values with the user’s requested inputs, respecting the schema; do not execute an example merely to test a connection.


```json
{
  "tool_id": "insee/melodi-data",
  "input": {
    "dataset": "DS_POPULATIONS_REFERENCE",
    "geo": [
      "COM-75056",
      "COM-69123"
    ],
    "max_results": 10
  }
}
```

## Execute and retrieve

Inspect again before execution, explain the price and obtain the required authority. Use MCP run_tool or POST /v1/run with this tool ID, valid input and an idempotency key. Save the returned run ID and follow the actual state. If Agentik answers that the tool is temporarily unavailable, do not retry it blindly; use discovery to propose an alternative.

A partial or uncertain result can still have consumed provider resources. Consult [billing](/docs/billing.md), [idempotency](/docs/idempotency.md) and [asynchronous results](/docs/async.md).

Licence: Licence Ouverte 2.0 (Etalab).

Attribution: Source: Insee (Melodi), Licence Ouverte 2.0.

[Provider documentation](https://portail-api.insee.fr/catalog/api/a890b735-159c-4c91-90b7-35159c7c9126)

[REST inspection](https://api.agentik.cc/v1/tools/insee/melodi-data) · [OpenAPI](/openapi.json) · [Connection guide](/connect.md)

---

[HTML page](/providers/insee/melodi-data) · [Agent index](/llms.txt)
