eptr2 1.3.9.dev5__tar.gz → 1.4.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- eptr2-1.3.9.dev5/README.md → eptr2-1.4.1/PKG-INFO +78 -10
- eptr2-1.3.9.dev5/PKG-INFO → eptr2-1.4.1/README.md +33 -44
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/pyproject.toml +22 -4
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/agentic/schema.py +6 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/eptr2_api_schema.json +172 -47
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/plugin.json +1 -1
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/skills/eptr2-api-discovery/endpoint-categories.md +1 -1
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/skills/eptr2-convenience-wrappers/SKILL.md +2 -0
- eptr2-1.4.1/src/eptr2/assets/skills/eptr2-imbalance-costs/SKILL.md +39 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/skills/eptr2-imbalance-costs/formulas.md +4 -0
- eptr2-1.4.1/src/eptr2/assets/skills/eptr2-market-operations/SKILL.md +49 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/__init__.py +4 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/consumption.py +42 -4
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/dam.py +4 -4
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/idm.py +2 -2
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/ng_sgp.py +12 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/renewables.py +38 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/reporting.py +12 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/retroactive.py +4 -4
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/composite/__init__.py +1 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/composite/dabi_idm.py +50 -8
- eptr2-1.4.1/src/eptr2/composite/idm_log.py +307 -0
- eptr2-1.4.1/src/eptr2/composite/org_activity.py +293 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/composite/periodic_orgs.py +16 -4
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/composite/plant_costs.py +53 -10
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/composite/price_and_cost.py +19 -6
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/main.py +26 -2
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/mapping/help.py +54 -6
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/mapping/parameters.py +11 -6
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/mapping/path.py +20 -3
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/mapping/processing.py +9 -2
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/mcp/README.md +1 -1
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/mcp/server.py +14 -5
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/processing/postprocess/items.py +12 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/util/costs.py +1492 -313
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/util/time.py +4 -4
- eptr2-1.3.9.dev5/src/eptr2/assets/skills/eptr2-imbalance-costs/SKILL.md +0 -24
- eptr2-1.3.9.dev5/src/eptr2/assets/skills/eptr2-market-operations/SKILL.md +0 -32
- eptr2-1.3.9.dev5/src/eptr2/composite/idm_log.py +0 -124
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/.claude/worktrees/wonderful-knuth-6c1f12/LICENSE +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/.claude/worktrees/wonderful-knuth-6c1f12/README.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/.claude/worktrees/wonderful-knuth-6c1f12/docs/assets/README.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/.claude/worktrees/wonderful-knuth-6c1f12/examples/README.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/.claude/worktrees/wonderful-knuth-6c1f12/pyproject.toml +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/.claude/worktrees/wonderful-knuth-6c1f12/src/eptr2/mcp/README.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/.claude/worktrees/wonderful-knuth-6c1f12/tutorials/README.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/.claude/worktrees/wonderful-knuth-6c1f12/tutorials/pyproject.toml +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/.gitignore +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/LICENSE +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/docs/assets/README.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/examples/README.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/__init__.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/__main__.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/agentic/__init__.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/agentic/discovery.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/agentic/skills.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/agentic/validation.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/__init__.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/mcp.json +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/skills/eptr2-api-discovery/SKILL.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/skills/eptr2-api-discovery/scripts/list_endpoints.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/skills/eptr2-consumption-data/SKILL.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/skills/eptr2-consumption-data/examples.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/skills/eptr2-generation-tracking/SKILL.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/skills/eptr2-generation-tracking/examples.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/skills/eptr2-imbalance-costs/examples.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/skills/eptr2-market-operations/examples.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/skills/eptr2-price-analysis/SKILL.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/skills/eptr2-price-analysis/api-reference.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/assets/skills/eptr2-price-analysis/examples.md +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/ancillary.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/bilateral.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/bpm.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/dams.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/general.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/generation.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/imbalance.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/mms.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/ng_general.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/ng_transmission.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/ng_vgp.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/transmission.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/vep.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/calls/yek_g.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/cli.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/composite/ancillary.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/composite/bpm.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/composite/consumption.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/composite/ids.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/composite/mms.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/composite/production.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/mapping/__init__.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/mapping/checks.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/mcp/__init__.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/processing/__init__.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/processing/postprocess/__init__.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/processing/preprocess/__init__.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/processing/preprocess/calls.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/processing/preprocess/params.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/util/__init__.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/util/certificate.py +0 -0
- {eptr2-1.3.9.dev5 → eptr2-1.4.1}/src/eptr2/util/evaluation.py +0 -0
|
@@ -1,3 +1,48 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: eptr2
|
|
3
|
+
Version: 1.4.1
|
|
4
|
+
Summary: EPIAS Transparency Platform v2.0 Python client by Robokami / Tideseed
|
|
5
|
+
Project-URL: Homepage, https://github.com/Tideseed/eptr2
|
|
6
|
+
Project-URL: Documentation, https://tideseed.github.io/eptr2/
|
|
7
|
+
Project-URL: Repository, https://github.com/Tideseed/eptr2.git
|
|
8
|
+
Project-URL: Issues, https://github.com/Tideseed/eptr2/issues
|
|
9
|
+
Project-URL: Changelog, https://github.com/Tideseed/eptr2/blob/main/CHANGELOG.md
|
|
10
|
+
Author-email: Tideseed <info@tideseed.com>
|
|
11
|
+
License: Apache License 2.0
|
|
12
|
+
License-File: LICENSE
|
|
13
|
+
Requires-Python: >=3.11
|
|
14
|
+
Requires-Dist: pytz>=2024.1
|
|
15
|
+
Requires-Dist: urllib3>=2.8.0
|
|
16
|
+
Provides-Extra: allextras
|
|
17
|
+
Requires-Dist: anyio>=4.14.2; extra == 'allextras'
|
|
18
|
+
Requires-Dist: certifi>=2026.10.19; extra == 'allextras'
|
|
19
|
+
Requires-Dist: fastmcp>=3.4.10; extra == 'allextras'
|
|
20
|
+
Requires-Dist: mcp>=1.30.0; extra == 'allextras'
|
|
21
|
+
Requires-Dist: openpyxl>=3.1.5; extra == 'allextras'
|
|
22
|
+
Requires-Dist: opentelemetry-api>=1.45.1; extra == 'allextras'
|
|
23
|
+
Requires-Dist: pandas>=2.1.3; extra == 'allextras'
|
|
24
|
+
Requires-Dist: pyjwt>=2.15.0; extra == 'allextras'
|
|
25
|
+
Requires-Dist: xlsxwriter>=3.2.9; extra == 'allextras'
|
|
26
|
+
Provides-Extra: dataframe
|
|
27
|
+
Requires-Dist: pandas>=2.1.3; extra == 'dataframe'
|
|
28
|
+
Provides-Extra: dev
|
|
29
|
+
Requires-Dist: pytest>=9.0.3; extra == 'dev'
|
|
30
|
+
Provides-Extra: docs
|
|
31
|
+
Requires-Dist: certifi>=2026.10.19; extra == 'docs'
|
|
32
|
+
Requires-Dist: mkdocs-autorefs>=0.5.0; extra == 'docs'
|
|
33
|
+
Requires-Dist: mkdocs-material>=9.5.0; extra == 'docs'
|
|
34
|
+
Requires-Dist: mkdocstrings[python]>=0.24.0; extra == 'docs'
|
|
35
|
+
Provides-Extra: mcp
|
|
36
|
+
Requires-Dist: anyio>=4.14.2; extra == 'mcp'
|
|
37
|
+
Requires-Dist: certifi>=2026.10.19; extra == 'mcp'
|
|
38
|
+
Requires-Dist: fastmcp>=3.4.10; extra == 'mcp'
|
|
39
|
+
Requires-Dist: mcp>=1.30.0; extra == 'mcp'
|
|
40
|
+
Requires-Dist: opentelemetry-api>=1.45.1; extra == 'mcp'
|
|
41
|
+
Requires-Dist: pandas>=2.1.3; extra == 'mcp'
|
|
42
|
+
Requires-Dist: pyjwt>=2.15.0; extra == 'mcp'
|
|
43
|
+
Requires-Dist: xlsxwriter>=3.2.9; extra == 'mcp'
|
|
44
|
+
Description-Content-Type: text/markdown
|
|
45
|
+
|
|
1
46
|
[](https://pypi.org/project/eptr2/)
|
|
2
47
|
[](https://pypi.org/project/eptr2/)
|
|
3
48
|
[](https://pypi.org/project/eptr2/)
|
|
@@ -7,7 +52,7 @@
|
|
|
7
52
|
|
|
8
53
|
# eptr2
|
|
9
54
|
|
|
10
|
-
`eptr2` (**EP**IAS **Tr**ansparency **2**.0) is a Python client for the [EPIAS Transparency Platform v2.0](https://seffaflik.epias.com.tr/home) API, covering **
|
|
55
|
+
`eptr2` (**EP**IAS **Tr**ansparency **2**.0) is a Python client for the [EPIAS Transparency Platform v2.0](https://seffaflik.epias.com.tr/home) API, covering **236 services** of the Turkish electricity and natural gas markets — prices (PTF/SMF), consumption, generation, production plans, market operations and imbalance costs.
|
|
11
56
|
|
|
12
57
|
It is an unofficial package by [Robokami](https://robokami.com) / [Tideseed](https://tideseed.com), Apache License 2.0.
|
|
13
58
|
|
|
@@ -62,7 +107,7 @@ eptr2 call mcp --start-date 2026-07-01 --end-date 2026-07-01 --format csv
|
|
|
62
107
|
|
|
63
108
|
## Usage
|
|
64
109
|
|
|
65
|
-
### One call pattern for all
|
|
110
|
+
### One call pattern for all 236 services
|
|
66
111
|
|
|
67
112
|
Every service is reached with the same `call` method and an endpoint key:
|
|
68
113
|
|
|
@@ -81,7 +126,7 @@ Turkish aliases work too: `ptf` → `mcp`, `smf` → `smp`.
|
|
|
81
126
|
You do **not** need credentials to explore the API:
|
|
82
127
|
|
|
83
128
|
```bash
|
|
84
|
-
eptr2 list # all
|
|
129
|
+
eptr2 list # all 236 keys grouped by category
|
|
85
130
|
eptr2 search dengesizlik # keyword search, Turkish or English
|
|
86
131
|
eptr2 describe mcp # parameters, method, path, description
|
|
87
132
|
```
|
|
@@ -114,6 +159,7 @@ from eptr2.composite import (
|
|
|
114
159
|
get_bpm_range, # balancing market (YAL/YAT) with SMP
|
|
115
160
|
get_kgup_bulk_range, # bulk production PLANS (by UEVCB id)
|
|
116
161
|
get_rt_gen_bulk_range, # bulk REALIZED generation (by powerplant id)
|
|
162
|
+
get_org_estimated_activity, # company DA/IDM activity, net positions (+ estimated PnL)
|
|
117
163
|
)
|
|
118
164
|
|
|
119
165
|
df = get_hourly_price_and_cost_data(
|
|
@@ -125,7 +171,20 @@ Note the argument order: dates first, the client as the `eptr` keyword.
|
|
|
125
171
|
|
|
126
172
|
### Imbalance and KÜPST cost calculations
|
|
127
173
|
|
|
128
|
-
|
|
174
|
+
The main functions resolve every regulation parameter (floor/ceiling, V, B, margins, KÜPST tolerance and multiplier by plant category) from each hour, and fetch MCP, SMP and system direction from EPİAŞ unless you pass prices:
|
|
175
|
+
|
|
176
|
+
```python
|
|
177
|
+
from eptr2.util.costs import calculate_imbalance_prices, calculate_imbalance_costs
|
|
178
|
+
|
|
179
|
+
## Hourly prices, unit costs and all parameters used. Published imbalance prices are
|
|
180
|
+
## used where available (imb_price_source); offline, pass prices=... to calculate them
|
|
181
|
+
prices = calculate_imbalance_prices("2026-10-01", "2026-10-07", eptr=eptr)
|
|
182
|
+
|
|
183
|
+
## Costs of actual vs forecast; category in any convention ("wind", "Rüzgar", "GES", "BESS", ...)
|
|
184
|
+
costs = calculate_imbalance_costs(data=df, category="Rüzgar", eptr=eptr) # df: date, actual, forecast
|
|
185
|
+
```
|
|
186
|
+
|
|
187
|
+
The single-hour helpers are pure functions — no API call, no credentials. The regulation period (pre-2026 / 2026) and the price floor/ceiling are derived from the contract code:
|
|
129
188
|
|
|
130
189
|
```python
|
|
131
190
|
from eptr2.util.costs import calculate_unit_price_and_costs_by_contract
|
|
@@ -177,7 +236,7 @@ Paste the printed snippet into your client's MCP configuration, fill in your cre
|
|
|
177
236
|
Point the agent at **[AGENTS.md](AGENTS.md)**, the canonical agent guide (VS Code and Claude Code read it automatically inside this repo). Away from the repo, the agent can learn the whole API on its own, without credentials:
|
|
178
237
|
|
|
179
238
|
```bash
|
|
180
|
-
eptr2 schema --stdout # machine-readable description of all
|
|
239
|
+
eptr2 schema --stdout # machine-readable description of all 236 endpoints
|
|
181
240
|
eptr2 describe rt-gen # exact parameters for one endpoint
|
|
182
241
|
eptr2 search üretim # find endpoints by keyword
|
|
183
242
|
```
|
|
@@ -209,7 +268,7 @@ eptr2 call mcp --start-date 2026-07-01 --end-date 2026-07-01 --format json | jq
|
|
|
209
268
|
|
|
210
269
|
| Topic | Documentation |
|
|
211
270
|
|-------|---------------|
|
|
212
|
-
| All
|
|
271
|
+
| All 236 API calls, categories and parameters | [Available API Calls](https://tideseed.github.io/eptr2/user-guide/api-calls/) |
|
|
213
272
|
| Typed `get_*` wrapper functions (`eptr2.calls`) | [Convenience Wrappers](https://tideseed.github.io/eptr2/user-guide/convenience-wrappers/) |
|
|
214
273
|
| Aliases, bulk calls, DataFrames | [Basic Usage](https://tideseed.github.io/eptr2/user-guide/basic-usage/) · [DataFrames](https://tideseed.github.io/eptr2/user-guide/dataframes/) |
|
|
215
274
|
| Composite functions | [Composite Functions](https://tideseed.github.io/eptr2/user-guide/composite-functions/) |
|
|
@@ -230,7 +289,7 @@ Pin a released version with `eptr2==1.3.8` if you need to stay off dev builds.
|
|
|
230
289
|
|
|
231
290
|
## Türkçe
|
|
232
291
|
|
|
233
|
-
`eptr2` (**EP**İAŞ **Tr**ansparency **2**.0), [EPİAŞ Şeffaflık Platformu 2.0](https://seffaflik.epias.com.tr/home) API'si üzerine geliştirilmiş bir Python paketidir. Türkiye elektrik ve doğal gaz piyasalarına ait **
|
|
292
|
+
`eptr2` (**EP**İAŞ **Tr**ansparency **2**.0), [EPİAŞ Şeffaflık Platformu 2.0](https://seffaflik.epias.com.tr/home) API'si üzerine geliştirilmiş bir Python paketidir. Türkiye elektrik ve doğal gaz piyasalarına ait **236 veri servisine** tek bir yapıyla erişim sağlar: PTF/SMF fiyatları, tüketim, üretim, üretim planları (KGÜP/KUDÜP), piyasa işlemleri (GÖP, GİP, DGP, İA) ve dengesizlik maliyetleri.
|
|
234
293
|
|
|
235
294
|
[Robokami](https://robokami.com) / [Tideseed](https://tideseed.com) tarafından geliştirilen resmi olmayan bir pakettir. Apache License 2.0 ile lisanslanmıştır; ticari kullanım dahil geniş ölçüde serbesttir.
|
|
236
295
|
|
|
@@ -282,7 +341,7 @@ eptr.call("mcp-smp-imb", start_date="2026-07-01", end_date="2026-07-01") # Deng
|
|
|
282
341
|
Hangi servisin ne olduğunu **kimlik bilgisi gerekmeden** keşfedebilirsiniz:
|
|
283
342
|
|
|
284
343
|
```bash
|
|
285
|
-
eptr2 list #
|
|
344
|
+
eptr2 list # 236 servisin tamamı, kategorilere göre
|
|
286
345
|
eptr2 search dengesizlik # Türkçe veya İngilizce anahtar kelime araması
|
|
287
346
|
eptr2 describe uevm # parametreler, yöntem, açıklama
|
|
288
347
|
```
|
|
@@ -300,7 +359,16 @@ df = get_hourly_price_and_cost_data(
|
|
|
300
359
|
|
|
301
360
|
### Dengesizlik ve KÜPST maliyetleri
|
|
302
361
|
|
|
303
|
-
|
|
362
|
+
Ana fonksiyonlar her saat için tüm mevzuat parametrelerini (taban-tavan fiyat, V, B, marjlar, santral kategorisine göre KÜPST toleransı ve katsayısı) otomatik belirler; fiyat verilmezse PTF, SMF ve sistem yönünü EPİAŞ'tan çeker:
|
|
363
|
+
|
|
364
|
+
```python
|
|
365
|
+
from eptr2.util.costs import calculate_imbalance_prices, calculate_imbalance_costs
|
|
366
|
+
|
|
367
|
+
prices = calculate_imbalance_prices("2026-10-01", "2026-10-07", eptr=eptr)
|
|
368
|
+
costs = calculate_imbalance_costs(data=df, category="Rüzgar", eptr=eptr) # df: date, actual, forecast
|
|
369
|
+
```
|
|
370
|
+
|
|
371
|
+
Tek saatlik yardımcı fonksiyonlar API çağrısı gerektirmeyen saf hesaplama fonksiyonlarıdır. Mevzuat dönemi (2026 öncesi / 2026) ve taban-tavan fiyatlar sözleşme kodundan otomatik belirlenir:
|
|
304
372
|
|
|
305
373
|
```python
|
|
306
374
|
from eptr2.util.costs import calculate_unit_price_and_costs_by_contract
|
|
@@ -321,7 +389,7 @@ calculate_unit_price_and_costs_by_contract(
|
|
|
321
389
|
- **MCP sunucusu** — VS Code, Claude, Cursor gibi istemcilere 18 araç kazandırır. Yapılandırma çıktısı için: `eptr2 mcp-config --client vscode`
|
|
322
390
|
- **Ajan becerileri (skills)** — fiyat analizi, tüketim, üretim, dengesizlik maliyetleri, piyasa işlemleri ve API keşfi için 7 hazır beceri: `eptr2 install-skills`
|
|
323
391
|
- **[AGENTS.md](AGENTS.md)** — kod yazan ajanlar için başvuru rehberi
|
|
324
|
-
- **Makine tarafından okunabilir şema** —
|
|
392
|
+
- **Makine tarafından okunabilir şema** — 236 servisin tamamı parametreleriyle: `eptr2 schema --stdout`
|
|
325
393
|
|
|
326
394
|
Böylece bir yapay zeka asistanına doğrudan "geçen ayın PTF ortalamasını hesapla" ya da "rüzgar santralim için dengesizlik maliyetini çıkar" diyebilir, ajanın sizin için doğru çağrıları yazmasını sağlayabilirsiniz.
|
|
327
395
|
|
|
@@ -1,37 +1,3 @@
|
|
|
1
|
-
Metadata-Version: 2.5
|
|
2
|
-
Name: eptr2
|
|
3
|
-
Version: 1.3.9.dev5
|
|
4
|
-
Summary: EPIAS Transparency Platform v2.0 Python client by Robokami / Tideseed
|
|
5
|
-
Project-URL: Homepage, https://github.com/Tideseed/eptr2
|
|
6
|
-
Project-URL: Documentation, https://tideseed.github.io/eptr2/
|
|
7
|
-
Project-URL: Repository, https://github.com/Tideseed/eptr2.git
|
|
8
|
-
Project-URL: Issues, https://github.com/Tideseed/eptr2/issues
|
|
9
|
-
Project-URL: Changelog, https://github.com/Tideseed/eptr2/blob/main/CHANGELOG.md
|
|
10
|
-
Author-email: Tideseed <info@tideseed.com>
|
|
11
|
-
License: Apache License 2.0
|
|
12
|
-
License-File: LICENSE
|
|
13
|
-
Requires-Python: >=3.11
|
|
14
|
-
Requires-Dist: pytz>=2024.1
|
|
15
|
-
Requires-Dist: urllib3>=2.7.0
|
|
16
|
-
Provides-Extra: allextras
|
|
17
|
-
Requires-Dist: fastmcp>=3.3.1; extra == 'allextras'
|
|
18
|
-
Requires-Dist: openpyxl>=3.1.5; extra == 'allextras'
|
|
19
|
-
Requires-Dist: pandas>=2.1.3; extra == 'allextras'
|
|
20
|
-
Requires-Dist: xlsxwriter>=3.2.9; extra == 'allextras'
|
|
21
|
-
Provides-Extra: dataframe
|
|
22
|
-
Requires-Dist: pandas>=2.1.3; extra == 'dataframe'
|
|
23
|
-
Provides-Extra: dev
|
|
24
|
-
Requires-Dist: pytest>=9.0.3; extra == 'dev'
|
|
25
|
-
Provides-Extra: docs
|
|
26
|
-
Requires-Dist: mkdocs-autorefs>=0.5.0; extra == 'docs'
|
|
27
|
-
Requires-Dist: mkdocs-material>=9.5.0; extra == 'docs'
|
|
28
|
-
Requires-Dist: mkdocstrings[python]>=0.24.0; extra == 'docs'
|
|
29
|
-
Provides-Extra: mcp
|
|
30
|
-
Requires-Dist: fastmcp>=3.3.1; extra == 'mcp'
|
|
31
|
-
Requires-Dist: pandas>=2.1.3; extra == 'mcp'
|
|
32
|
-
Requires-Dist: xlsxwriter>=3.2.9; extra == 'mcp'
|
|
33
|
-
Description-Content-Type: text/markdown
|
|
34
|
-
|
|
35
1
|
[](https://pypi.org/project/eptr2/)
|
|
36
2
|
[](https://pypi.org/project/eptr2/)
|
|
37
3
|
[](https://pypi.org/project/eptr2/)
|
|
@@ -41,7 +7,7 @@ Description-Content-Type: text/markdown
|
|
|
41
7
|
|
|
42
8
|
# eptr2
|
|
43
9
|
|
|
44
|
-
`eptr2` (**EP**IAS **Tr**ansparency **2**.0) is a Python client for the [EPIAS Transparency Platform v2.0](https://seffaflik.epias.com.tr/home) API, covering **
|
|
10
|
+
`eptr2` (**EP**IAS **Tr**ansparency **2**.0) is a Python client for the [EPIAS Transparency Platform v2.0](https://seffaflik.epias.com.tr/home) API, covering **236 services** of the Turkish electricity and natural gas markets — prices (PTF/SMF), consumption, generation, production plans, market operations and imbalance costs.
|
|
45
11
|
|
|
46
12
|
It is an unofficial package by [Robokami](https://robokami.com) / [Tideseed](https://tideseed.com), Apache License 2.0.
|
|
47
13
|
|
|
@@ -96,7 +62,7 @@ eptr2 call mcp --start-date 2026-07-01 --end-date 2026-07-01 --format csv
|
|
|
96
62
|
|
|
97
63
|
## Usage
|
|
98
64
|
|
|
99
|
-
### One call pattern for all
|
|
65
|
+
### One call pattern for all 236 services
|
|
100
66
|
|
|
101
67
|
Every service is reached with the same `call` method and an endpoint key:
|
|
102
68
|
|
|
@@ -115,7 +81,7 @@ Turkish aliases work too: `ptf` → `mcp`, `smf` → `smp`.
|
|
|
115
81
|
You do **not** need credentials to explore the API:
|
|
116
82
|
|
|
117
83
|
```bash
|
|
118
|
-
eptr2 list # all
|
|
84
|
+
eptr2 list # all 236 keys grouped by category
|
|
119
85
|
eptr2 search dengesizlik # keyword search, Turkish or English
|
|
120
86
|
eptr2 describe mcp # parameters, method, path, description
|
|
121
87
|
```
|
|
@@ -148,6 +114,7 @@ from eptr2.composite import (
|
|
|
148
114
|
get_bpm_range, # balancing market (YAL/YAT) with SMP
|
|
149
115
|
get_kgup_bulk_range, # bulk production PLANS (by UEVCB id)
|
|
150
116
|
get_rt_gen_bulk_range, # bulk REALIZED generation (by powerplant id)
|
|
117
|
+
get_org_estimated_activity, # company DA/IDM activity, net positions (+ estimated PnL)
|
|
151
118
|
)
|
|
152
119
|
|
|
153
120
|
df = get_hourly_price_and_cost_data(
|
|
@@ -159,7 +126,20 @@ Note the argument order: dates first, the client as the `eptr` keyword.
|
|
|
159
126
|
|
|
160
127
|
### Imbalance and KÜPST cost calculations
|
|
161
128
|
|
|
162
|
-
|
|
129
|
+
The main functions resolve every regulation parameter (floor/ceiling, V, B, margins, KÜPST tolerance and multiplier by plant category) from each hour, and fetch MCP, SMP and system direction from EPİAŞ unless you pass prices:
|
|
130
|
+
|
|
131
|
+
```python
|
|
132
|
+
from eptr2.util.costs import calculate_imbalance_prices, calculate_imbalance_costs
|
|
133
|
+
|
|
134
|
+
## Hourly prices, unit costs and all parameters used. Published imbalance prices are
|
|
135
|
+
## used where available (imb_price_source); offline, pass prices=... to calculate them
|
|
136
|
+
prices = calculate_imbalance_prices("2026-10-01", "2026-10-07", eptr=eptr)
|
|
137
|
+
|
|
138
|
+
## Costs of actual vs forecast; category in any convention ("wind", "Rüzgar", "GES", "BESS", ...)
|
|
139
|
+
costs = calculate_imbalance_costs(data=df, category="Rüzgar", eptr=eptr) # df: date, actual, forecast
|
|
140
|
+
```
|
|
141
|
+
|
|
142
|
+
The single-hour helpers are pure functions — no API call, no credentials. The regulation period (pre-2026 / 2026) and the price floor/ceiling are derived from the contract code:
|
|
163
143
|
|
|
164
144
|
```python
|
|
165
145
|
from eptr2.util.costs import calculate_unit_price_and_costs_by_contract
|
|
@@ -211,7 +191,7 @@ Paste the printed snippet into your client's MCP configuration, fill in your cre
|
|
|
211
191
|
Point the agent at **[AGENTS.md](AGENTS.md)**, the canonical agent guide (VS Code and Claude Code read it automatically inside this repo). Away from the repo, the agent can learn the whole API on its own, without credentials:
|
|
212
192
|
|
|
213
193
|
```bash
|
|
214
|
-
eptr2 schema --stdout # machine-readable description of all
|
|
194
|
+
eptr2 schema --stdout # machine-readable description of all 236 endpoints
|
|
215
195
|
eptr2 describe rt-gen # exact parameters for one endpoint
|
|
216
196
|
eptr2 search üretim # find endpoints by keyword
|
|
217
197
|
```
|
|
@@ -243,7 +223,7 @@ eptr2 call mcp --start-date 2026-07-01 --end-date 2026-07-01 --format json | jq
|
|
|
243
223
|
|
|
244
224
|
| Topic | Documentation |
|
|
245
225
|
|-------|---------------|
|
|
246
|
-
| All
|
|
226
|
+
| All 236 API calls, categories and parameters | [Available API Calls](https://tideseed.github.io/eptr2/user-guide/api-calls/) |
|
|
247
227
|
| Typed `get_*` wrapper functions (`eptr2.calls`) | [Convenience Wrappers](https://tideseed.github.io/eptr2/user-guide/convenience-wrappers/) |
|
|
248
228
|
| Aliases, bulk calls, DataFrames | [Basic Usage](https://tideseed.github.io/eptr2/user-guide/basic-usage/) · [DataFrames](https://tideseed.github.io/eptr2/user-guide/dataframes/) |
|
|
249
229
|
| Composite functions | [Composite Functions](https://tideseed.github.io/eptr2/user-guide/composite-functions/) |
|
|
@@ -264,7 +244,7 @@ Pin a released version with `eptr2==1.3.8` if you need to stay off dev builds.
|
|
|
264
244
|
|
|
265
245
|
## Türkçe
|
|
266
246
|
|
|
267
|
-
`eptr2` (**EP**İAŞ **Tr**ansparency **2**.0), [EPİAŞ Şeffaflık Platformu 2.0](https://seffaflik.epias.com.tr/home) API'si üzerine geliştirilmiş bir Python paketidir. Türkiye elektrik ve doğal gaz piyasalarına ait **
|
|
247
|
+
`eptr2` (**EP**İAŞ **Tr**ansparency **2**.0), [EPİAŞ Şeffaflık Platformu 2.0](https://seffaflik.epias.com.tr/home) API'si üzerine geliştirilmiş bir Python paketidir. Türkiye elektrik ve doğal gaz piyasalarına ait **236 veri servisine** tek bir yapıyla erişim sağlar: PTF/SMF fiyatları, tüketim, üretim, üretim planları (KGÜP/KUDÜP), piyasa işlemleri (GÖP, GİP, DGP, İA) ve dengesizlik maliyetleri.
|
|
268
248
|
|
|
269
249
|
[Robokami](https://robokami.com) / [Tideseed](https://tideseed.com) tarafından geliştirilen resmi olmayan bir pakettir. Apache License 2.0 ile lisanslanmıştır; ticari kullanım dahil geniş ölçüde serbesttir.
|
|
270
250
|
|
|
@@ -316,7 +296,7 @@ eptr.call("mcp-smp-imb", start_date="2026-07-01", end_date="2026-07-01") # Deng
|
|
|
316
296
|
Hangi servisin ne olduğunu **kimlik bilgisi gerekmeden** keşfedebilirsiniz:
|
|
317
297
|
|
|
318
298
|
```bash
|
|
319
|
-
eptr2 list #
|
|
299
|
+
eptr2 list # 236 servisin tamamı, kategorilere göre
|
|
320
300
|
eptr2 search dengesizlik # Türkçe veya İngilizce anahtar kelime araması
|
|
321
301
|
eptr2 describe uevm # parametreler, yöntem, açıklama
|
|
322
302
|
```
|
|
@@ -334,7 +314,16 @@ df = get_hourly_price_and_cost_data(
|
|
|
334
314
|
|
|
335
315
|
### Dengesizlik ve KÜPST maliyetleri
|
|
336
316
|
|
|
337
|
-
|
|
317
|
+
Ana fonksiyonlar her saat için tüm mevzuat parametrelerini (taban-tavan fiyat, V, B, marjlar, santral kategorisine göre KÜPST toleransı ve katsayısı) otomatik belirler; fiyat verilmezse PTF, SMF ve sistem yönünü EPİAŞ'tan çeker:
|
|
318
|
+
|
|
319
|
+
```python
|
|
320
|
+
from eptr2.util.costs import calculate_imbalance_prices, calculate_imbalance_costs
|
|
321
|
+
|
|
322
|
+
prices = calculate_imbalance_prices("2026-10-01", "2026-10-07", eptr=eptr)
|
|
323
|
+
costs = calculate_imbalance_costs(data=df, category="Rüzgar", eptr=eptr) # df: date, actual, forecast
|
|
324
|
+
```
|
|
325
|
+
|
|
326
|
+
Tek saatlik yardımcı fonksiyonlar API çağrısı gerektirmeyen saf hesaplama fonksiyonlarıdır. Mevzuat dönemi (2026 öncesi / 2026) ve taban-tavan fiyatlar sözleşme kodundan otomatik belirlenir:
|
|
338
327
|
|
|
339
328
|
```python
|
|
340
329
|
from eptr2.util.costs import calculate_unit_price_and_costs_by_contract
|
|
@@ -355,7 +344,7 @@ calculate_unit_price_and_costs_by_contract(
|
|
|
355
344
|
- **MCP sunucusu** — VS Code, Claude, Cursor gibi istemcilere 18 araç kazandırır. Yapılandırma çıktısı için: `eptr2 mcp-config --client vscode`
|
|
356
345
|
- **Ajan becerileri (skills)** — fiyat analizi, tüketim, üretim, dengesizlik maliyetleri, piyasa işlemleri ve API keşfi için 7 hazır beceri: `eptr2 install-skills`
|
|
357
346
|
- **[AGENTS.md](AGENTS.md)** — kod yazan ajanlar için başvuru rehberi
|
|
358
|
-
- **Makine tarafından okunabilir şema** —
|
|
347
|
+
- **Makine tarafından okunabilir şema** — 236 servisin tamamı parametreleriyle: `eptr2 schema --stdout`
|
|
359
348
|
|
|
360
349
|
Böylece bir yapay zeka asistanına doğrudan "geçen ayın PTF ortalamasını hesapla" ya da "rüzgar santralim için dengesizlik maliyetini çıkar" diyebilir, ajanın sizin için doğru çağrıları yazmasını sağlayabilirsiniz.
|
|
361
350
|
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "eptr2"
|
|
3
|
-
version = "1.
|
|
3
|
+
version = "1.4.1"
|
|
4
4
|
description = "EPIAS Transparency Platform v2.0 Python client by Robokami / Tideseed"
|
|
5
5
|
authors = [{ name = "Tideseed", email = "info@tideseed.com" }]
|
|
6
6
|
license = { text = "Apache License 2.0" }
|
|
7
7
|
readme = "README.md"
|
|
8
8
|
requires-python = ">=3.11"
|
|
9
|
-
dependencies = ["urllib3>=2.
|
|
9
|
+
dependencies = ["urllib3>=2.8.0", "pytz>=2024.1"]
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
[project.urls]
|
|
@@ -19,17 +19,34 @@ Changelog = "https://github.com/Tideseed/eptr2/blob/main/CHANGELOG.md"
|
|
|
19
19
|
|
|
20
20
|
[project.optional-dependencies]
|
|
21
21
|
dataframe = ["pandas>=2.1.3"]
|
|
22
|
-
mcp = [
|
|
22
|
+
mcp = [
|
|
23
|
+
"fastmcp>=3.4.10",
|
|
24
|
+
"pandas>=2.1.3",
|
|
25
|
+
"xlsxwriter>=3.2.9",
|
|
26
|
+
## Security floors for dependencies of fastmcp (see changelog, Security)
|
|
27
|
+
"certifi>=2026.10.19",
|
|
28
|
+
"mcp>=1.30.0",
|
|
29
|
+
"pyjwt>=2.15.0",
|
|
30
|
+
"anyio>=4.14.2",
|
|
31
|
+
"opentelemetry-api>=1.45.1",
|
|
32
|
+
]
|
|
23
33
|
allextras = [
|
|
24
34
|
"pandas>=2.1.3",
|
|
25
35
|
"xlsxwriter>=3.2.9",
|
|
26
36
|
"openpyxl>=3.1.5",
|
|
27
|
-
"fastmcp>=3.
|
|
37
|
+
"fastmcp>=3.4.10",
|
|
38
|
+
## Security floors for dependencies of fastmcp (see changelog, Security)
|
|
39
|
+
"certifi>=2026.10.19",
|
|
40
|
+
"mcp>=1.30.0",
|
|
41
|
+
"pyjwt>=2.15.0",
|
|
42
|
+
"anyio>=4.14.2",
|
|
43
|
+
"opentelemetry-api>=1.45.1",
|
|
28
44
|
]
|
|
29
45
|
docs = [
|
|
30
46
|
"mkdocs-material>=9.5.0",
|
|
31
47
|
"mkdocstrings[python]>=0.24.0",
|
|
32
48
|
"mkdocs-autorefs>=0.5.0",
|
|
49
|
+
"certifi>=2026.10.19",
|
|
33
50
|
]
|
|
34
51
|
dev = ["pytest>=9.0.3"]
|
|
35
52
|
|
|
@@ -56,5 +73,6 @@ docs = [
|
|
|
56
73
|
"mkdocs-autorefs>=1.4.3",
|
|
57
74
|
"mkdocs-material>=9.7.1",
|
|
58
75
|
"mkdocstrings[python]>=1.0.0",
|
|
76
|
+
"certifi>=2026.10.19",
|
|
59
77
|
]
|
|
60
78
|
dev = ["pytest>=7.4.0", "python-dotenv>=1.1.1"]
|
|
@@ -17,8 +17,14 @@ SCHEMA_FORMAT_VERSION = "2.0"
|
|
|
17
17
|
# explicitly so internal/deprecated helpers (temp_*, *_pre_2026, *_2026
|
|
18
18
|
# period variants) stay out of the agent-facing schema.
|
|
19
19
|
COST_UTILITY_NAMES = [
|
|
20
|
+
"calculate_imbalance_prices",
|
|
21
|
+
"calculate_imbalance_costs",
|
|
20
22
|
"get_kupst_tolerance",
|
|
21
23
|
"get_kupst_tolerance_by_contract",
|
|
24
|
+
"get_kupst_params_by_contract",
|
|
25
|
+
"get_regulation_params",
|
|
26
|
+
"normalize_kupst_category",
|
|
27
|
+
"is_kupst_maintenance_penalty_applicable",
|
|
22
28
|
"calculate_unit_kupst_cost",
|
|
23
29
|
"calculate_unit_kupst_cost_by_contract",
|
|
24
30
|
"calculate_kupst_cost",
|