---
title: "Get sector aggregated ratios"
method: GET
path: "/api/v1/sector/{cnae}/ratios"
tags: ["Sectors"]
---

# Get sector aggregated ratios

`GET /api/v1/sector/{cnae}/ratios`

Return Banco de Espana Central de Balances aggregate metrics by two-digit CNAE division and year from the immutable, hash-addressed sector_ratios_public_v1 bundle. Coverage is sector-aggregate only: it contains neither individual-company data nor a company score. The endpoint fails closed with 503, without a raw/request-path fallback, when activation, manifest, file hash or public-source catalog authority cannot be verified.

## Path parameters

- `cnae` string, required

## Headers

- `If-None-Match` string

## Response `200`

Sector ratios

- SectorRatiosResponse
  - `code` string, required
  - `ratios` SectorRatio[], required
    - `year` integer, required
    - `metric` 'margen_neto' | 'roa' | 'roe', required
    - `value` number, required
    - `unit` '%', required
    - `source` 'BdE Central de Balances', required

## Other responses

- `304` — Not modified; the verified projection generation and legal source authority are unchanged.
- `404` — Resource not found
- `429` — Rate limit exceeded
- `503` — The public read failed closed because its legal source catalog, subject classification, bounded projection, database helper or required artifact is unavailable. Clients must not infer an empty result.

---

[API](https://skmtc.net/openmercantil/apis/openmercantil-public-api.md) · [All operations](https://skmtc.net/openmercantil/apis/openmercantil-public-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/openmercantil/openmercantil-public-api/versions/996f96a11758/schema)
