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

# Generation Mix

> Returns the Eskom generation mix (dispatchable + renewable) for the given time range. Supports hourly (1h) and daily (1d) intervals. Requires API key authentication.

## Overview

Returns the Eskom generation mix — the breakdown of South African power generation by fuel type — for a given time range. Covers both dispatchable generation (coal, nuclear, gas, hydro) and renewables (wind, solar PV, CSP).

This is a cleaner, generation-only view of the grid. Unlike [System State](https://docs.powersignals.co.za/api-reference/grid/system-state.md), it omits demand, imports/exports, and derived metrics, and instead adds a fuller renewable breakdown (CSP, other renewables, pumped storage).

### Use Cases

* Track renewable vs. dispatchable generation over time
* Monitor solar PV and wind output for forecasting models
* Quantify reliance on OCGT (diesel) peaking plants
* Build energy supply dashboards and reporting

### Intervals

| Interval | Description |
| - | - |
| `1h` | Raw hourly readings from Eskom |
| `1d` | Daily aggregation (MW columns averaged over the day) |

### Data Fields (Hourly)

Each record in the `data` array contains:

| Field | Unit | Description |
| - | - | - |
| `ts` | ISO-8601 | Timestamp (UTC) |
| `thermal_mw` | MW | Coal-fired generation |
| `nuclear_mw` | MW | Nuclear generation |
| `eskom_gas_mw` | MW | Eskom gas turbine output |
| `eskom_ocgt_mw` | MW | Open-cycle gas turbine output |
| `hydro_water_mw` | MW | Hydro generation |
| `pumped_water_gen_mw` | MW | Pumped storage generation |
| `wind_mw` | MW | Wind generation |
| `pv_mw` | MW | Solar PV generation |
| `csp_mw` | MW | Concentrated solar power |
| `other_re_mw` | MW | Other renewables |

### Data Fields (Daily)

With `interval=1d`, every MW column is averaged over the UTC day and prefixed with `avg_`:

| Field | Unit | Description |
| - | - | - |
| `date` | ISO-8601 | UTC calendar day |
| `avg_thermal_mw` | MW | Average coal-fired generation |
| `avg_nuclear_mw` | MW | Average nuclear generation |
| `avg_eskom_gas_mw` | MW | Average Eskom gas turbine output |
| `avg_eskom_ocgt_mw` | MW | Average OCGT output |
| `avg_hydro_water_mw` | MW | Average hydro generation |
| `avg_pumped_water_gen_mw` | MW | Average pumped storage generation |
| `avg_wind_mw` | MW | Average wind generation |
| `avg_pv_mw` | MW | Average solar PV generation |
| `avg_csp_mw` | MW | Average concentrated solar power |
| `avg_other_re_mw` | MW | Average other renewables |


## OpenAPI

````yaml get /api/v1/generation/mix
openapi: 3.0.3
info:
  title: Power Signals API
  version: 1.0.0
  description: >-
    Clean, normalized, developer-ready datasets for energy traders, quants, and
    analysts.
  contact:
    email: support@powersignals.co.za
  license:
    name: Proprietary
servers:
  - url: https://api.powersignals.co.za
    description: Production
security: []
tags:
  - name: Generation
    description: Generation mix by fuel type (dispatchable + renewable)
  - name: Grid
    description: South African grid system state data
  - name: Features
    description: Derived analytical signals (Grid Stress Index, etc.)
paths:
  /api/v1/generation/mix:
    get:
      tags:
        - Generation
      summary: Get generation mix
      description: >-
        Returns the Eskom generation mix (dispatchable + renewable) for the
        given time range. Supports hourly (1h) and daily (1d) intervals.
        Requires API key authentication.
      operationId: getGenerationMix
      parameters:
        - in: query
          name: end
          schema:
            type: string
          description: End datetime in ISO-8601 format (e.g. 2026-01-02T00:00:00Z).
          required: true
        - in: query
          name: interval
          schema:
            type: string
            enum:
              - 1d
              - 1h
          description: Data resolution. Defaults to 1h.
        - in: query
          name: start
          schema:
            type: string
          description: Start datetime in ISO-8601 format (e.g. 2026-01-01T00:00:00Z).
          required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GenerationMixResponse'
          description: ''
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
          description: ''
      security:
        - ApiKeyAuth: []
components:
  schemas:
    GenerationMixResponse:
      type: object
      properties:
        meta:
          $ref: '#/components/schemas/GenerationMixMeta'
        data:
          type: array
          items:
            type: object
            additionalProperties: {}
      required:
        - data
        - meta
    ErrorResponse:
      type: object
      properties:
        error:
          type: string
        detail:
          type: string
      required:
        - detail
        - error
    GenerationMixMeta:
      type: object
      properties:
        dataset:
          type: string
          default: generation.mix
        interval:
          $ref: '#/components/schemas/IntervalEnum'
        timezone:
          type: string
          default: UTC
        schema_version:
          type: string
          default: '1.0'
        derived:
          type: boolean
        start:
          type: string
        end:
          type: string
      required:
        - derived
        - end
        - interval
        - start
    IntervalEnum:
      enum:
        - 1h
        - 1d
      type: string
      description: |-
        * `1h` - 1h
        * `1d` - 1d
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-KEY
      description: API key obtained from the Power Signals dashboard.

````

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