# German Energy Tax & Compliance Audit Engine (`audit-data-solutions/german-energy-compliance`) Actor

High-precision fiscal audit engine for German energy costs. Automated PLZ-mapping for 800+ grid operators, dynamic SMARD pricing, and GoBD-compliant audit trails.

- **URL**: https://apify.com/audit-data-solutions/german-energy-compliance.md
- **Developed by:** [Quantix](https://apify.com/audit-data-solutions) (community)
- **Categories:** Automation, Developer tools, Other
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 1 bookmarks
- **User rating**: No ratings yet

## Pricing

from $100.00 / 1,000 energy audit certificates

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## 🚀 Energy Audit & ESG Engine (EU/DE)

Professional tax logic for energy audits and ESG reporting in the EU. This API engine provides high-precision data for energy cost control and compliance, specifically optimized for the German market.

The engine is built for digital accounting in accordance with **ISO 14083**, **CSRD (Scope 2)**, and **GoBD** standards.

---

#### 📊 Live Audit Preview
**[Click here to view a live sample audit report (JSON)](https://api.apify.com/v2/datasets/fLaWEBEwl2qYFR1mQ/items?format=json&clean=true)**
*Example based on PLZ 10117 (Berlin) and 50,000 kWh consumption.*

---

### 🏗️ Key Features

*   **Regional Precision:** Automated calculations based on German grid operators (*Netzbetreiber*) via real-time ZIP-code (PLZ) mapping.
*   **15-Minute Interval Pricing:** Integration of official BNetzA (SMARD) data with 15-minute accuracy for maximum precision.
*   **Fiscal Audit Trail:** Every request generates a unique, hashed `Audit_ID` ensuring data immutability and compliance with GoBD guidelines.
*   **Full Tax Specification:** Comprehensive breakdown of energy taxes (§9b/§10 StromStG), concession fees, grid charges, and VAT (19%).
*   **Hybrid Logic:** Seamless switching between industrial (*Gewerbe*) and residential tax regulations.

### 📊 Compliance & Frameworks

*   **CSRD / ESRS:** Ready for indirect emission reporting (Scope 2).
*   **ISO 14083:** Standardized GHG emission calculations for energy and logistics.
*   **GoBD-compliant:** Designed for "audit-proof" (revisionssicher) digital accounting in Germany.
*   **Accountant-Ready:** Built for validating industrial tax refund applications and official energy audits. 

---

#### 🇩🇪 Deutsche Zusammenfassung (ESG & Steuer-Compliance)

Diese Engine bietet automatisierte Berechnungen für Energieaudits nach deutschen Standards. Ideal für Unternehmen, die CSRD-konforme Daten oder Unterstützung bei der Stromsteuererstattung benötigen.

<details>
<summary><b>Klicken Sie hier für die vollständige deutsche Beschreibung</b></summary>

##### Professionelle Steuerlogik für den deutschen Markt
Entwickelt für die digitale Buchhaltung gemäß **ISO 14083**, **CSRD (Scope 2)** und **GoBD**.

*   **Netzbetreiber-Mapping:** Automatisierte Ermittlung regionaler Gebühren über die Postleitzahl.
*   **Revisionssicherheit:** Erstellung einer gehashten `Audit_ID` für manipulationssichere Unterlagen.
*   **Steuer-Details:** Vollständige Aufschlüsselung von Stromsteuer (§9b/§10 StromStG), Konzessionsabgaben und Netzentgelten.
*   **Wirtschaftsprüfer-Ready:** Validierung von Anträgen auf Stromsteuererstattung und offizielle Energieaudits (DIN EN 16247-1).

Die Engine fungiert als "Übersetzer" zwischen komplexen Gesetzesdaten und sauberem JSON für ERP- und Buchhaltungssysteme.
</details>

---

### 🛠️ Integration & Parameters

*   `plz`: German ZIP code (5 digits).
*   `verbrauch_kwh`: Consumption for the audit period.
*   `is_industrial`: Boolean for industrial tax reduction rules.
*   `datum`: (Optional) ISO timestamp for historical audits.

---

***Disclaimer:** Data provided for audit and benchmarking purposes. Calculations should be verified against official utility invoices. Audit & Data Solutions assumes no liability for tax filings.*

# Actor input Schema

## `plz` (type: `string`):

De 5-cijferige Duitse postcode.
## `verbrauch_kwh` (type: `integer`):

Totaal verbruik voor de auditperiode.
## `is_industrial` (type: `boolean`):

Vink aan voor belastingvermindering conform §9b/10 StromStG.
## `datum` (type: `string`):

ISO-datum voor historische audits (bijv. 2024-04-22).

## Actor input object example

```json
{
  "plz": "10117",
  "verbrauch_kwh": 50000,
  "is_industrial": false
}
````

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "plz": "10117",
    "verbrauch_kwh": 50000
};

// Run the Actor and wait for it to finish
const run = await client.actor("audit-data-solutions/german-energy-compliance").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "plz": "10117",
    "verbrauch_kwh": 50000,
}

# Run the Actor and wait for it to finish
run = client.actor("audit-data-solutions/german-energy-compliance").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "plz": "10117",
  "verbrauch_kwh": 50000
}' |
apify call audit-data-solutions/german-energy-compliance --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=audit-data-solutions/german-energy-compliance",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "German Energy Tax & Compliance Audit Engine",
        "description": "High-precision fiscal audit engine for German energy costs. Automated PLZ-mapping for 800+ grid operators, dynamic SMARD pricing, and GoBD-compliant audit trails.",
        "version": "0.0",
        "x-build-id": "cmuZAZaOdvCQubuRN"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/audit-data-solutions~german-energy-compliance/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-audit-data-solutions-german-energy-compliance",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/audit-data-solutions~german-energy-compliance/runs": {
            "post": {
                "operationId": "runs-sync-audit-data-solutions-german-energy-compliance",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/audit-data-solutions~german-energy-compliance/run-sync": {
            "post": {
                "operationId": "run-sync-audit-data-solutions-german-energy-compliance",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "plz",
                    "verbrauch_kwh"
                ],
                "properties": {
                    "plz": {
                        "title": "Postleitzahl (PLZ)",
                        "type": "string",
                        "description": "De 5-cijferige Duitse postcode."
                    },
                    "verbrauch_kwh": {
                        "title": "Jaarverbruik (kWh)",
                        "type": "integer",
                        "description": "Totaal verbruik voor de auditperiode."
                    },
                    "is_industrial": {
                        "title": "Industrie / Gewerbe",
                        "type": "boolean",
                        "description": "Vink aan voor belastingvermindering conform §9b/10 StromStG.",
                        "default": false
                    },
                    "datum": {
                        "title": "Audit Datum (Optioneel)",
                        "type": "string",
                        "description": "ISO-datum voor historische audits (bijv. 2024-04-22)."
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
