{"id":26269812,"url":"https://github.com/m4rc0sx/esiosapy","last_synced_at":"2026-02-27T01:07:34.194Z","repository":{"id":253579723,"uuid":"741967621","full_name":"M4RC0Sx/esiosapy","owner":"M4RC0Sx","description":"Unofficial ESIOS API Python library. Up to date and fully equipped.","archived":false,"fork":false,"pushed_at":"2026-02-23T22:26:13.000Z","size":282,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-02-24T04:28:58.265Z","etag":null,"topics":["electrcidad","energia","energy-markets","esios","esios-api","mercados-electricos","python","ree"],"latest_commit_sha":null,"homepage":"https://m4rc0sx.github.io/esiosapy/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/M4RC0Sx.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-01-11T13:40:03.000Z","updated_at":"2026-02-14T11:24:54.000Z","dependencies_parsed_at":"2025-04-30T22:00:30.977Z","dependency_job_id":"e34c0e8e-3477-430d-bf61-c150865b39b7","html_url":"https://github.com/M4RC0Sx/esiosapy","commit_stats":null,"previous_names":["m4rc0sx/esiosapy"],"tags_count":16,"template":false,"template_full_name":null,"purl":"pkg:github/M4RC0Sx/esiosapy","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/M4RC0Sx%2Fesiosapy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/M4RC0Sx%2Fesiosapy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/M4RC0Sx%2Fesiosapy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/M4RC0Sx%2Fesiosapy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/M4RC0Sx","download_url":"https://codeload.github.com/M4RC0Sx/esiosapy/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/M4RC0Sx%2Fesiosapy/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29879956,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-26T23:51:21.483Z","status":"ssl_error","status_checked_at":"2026-02-26T23:50:46.793Z","response_time":89,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["electrcidad","energia","energy-markets","esios","esios-api","mercados-electricos","python","ree"],"created_at":"2025-03-14T05:16:07.529Z","updated_at":"2026-02-27T01:07:34.186Z","avatar_url":"https://github.com/M4RC0Sx.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# esiosapy\n\n\u003cp align=\"center\"\u003e\n    \u003cem\u003eUnofficial ESIOS API Python library. Up to date and fully equipped.\u003c/em\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n\u003ca href=\"https://github.com/M4RC0Sx/esiosapy/actions/workflows/test.yml/badge.svg?branch=develop\" target=\"_blank\"\u003e\n    \u003cimg src=\"https://github.com/M4RC0Sx/esiosapy/actions/workflows/test.yml/badge.svg?branch=develop\" alt=\"Test\"\u003e\n\u003c/a\u003e\n\u003ca href=\"https://github.com/M4RC0Sx/esiosapy/actions/workflows/release.yml/badge.svg\" target=\"_blank\"\u003e\n    \u003cimg src=\"https://github.com/M4RC0Sx/esiosapy/actions/workflows/release.yml/badge.svg\" alt=\"Release\"\u003e\n\u003c/a\u003e\n\u003ca href=\"https://pypi.org/project/esiosapy\" target=\"_blank\"\u003e\n    \u003cimg src=\"https://img.shields.io/pypi/v/esiosapy?color=%2334D058\u0026label=pypi%20package\" alt=\"Package version\"\u003e\n\u003c/a\u003e\n\u003ca href=\"https://pypi.org/project/esiosapy\" target=\"_blank\"\u003e\n    \u003cimg src=\"https://img.shields.io/pypi/pyversions/esiosapy.svg?color=%2334D058\" alt=\"Supported Python versions\"\u003e\n\u003c/a\u003e\n\u003ca href=\"https://coveralls.io/github/M4RC0Sx/esiosapy?branch=develop\" target=\"_blank\"\u003e\n    \u003cimg src=\"https://coveralls.io/repos/github/M4RC0Sx/esiosapy/badge.svg?branch=develop\" alt=\"Coverage\"\u003e\n\u003c/a\u003e\n\u003c/p\u003e\n\n---\n\n**Documentation**: [https://m4rc0sx.github.io/esiosapy/](https://m4rc0sx.github.io/esiosapy/)\n\n---\n\nesiosapy allows you to communicate with the [ESIOS/REE API](https://api.esios.ree.es/) in a comfortable and abstract way, so that everything is handled by objects and you will not need to write any raw request.\n\n## Features\n\n- **Simple API**: Easy-to-use client for accessing ESIOS data\n- **Sync \u0026 Async**: Both synchronous and asynchronous clients\n- **Type Hints**: Full type annotations with strict mypy support\n- **Retry Logic**: Automatic retry with exponential backoff for network errors\n- **CLI**: Command-line interface for quick data exploration\n- **Logging**: Built-in logging for debugging\n- **Configurable Timeouts**: Customizable request timeouts\n\n## Installation\n\nesiosapy is available on PyPI and supports Python \u003e=3.10:\n\n```bash\npip install esiosapy\n```\n\n### Optional dependencies\n\n```bash\n# Async support (httpx)\npip install esiosapy[async]\n\n# HTML description prettifying (beautifulsoup4)\npip install esiosapy[beautifulsoup]\n\n# All optional dependencies\npip install esiosapy[all]\n```\n\n## Quick start\n\nYou need a personal token to use the ESIOS API. You can request one at [https://api.esios.ree.es/](https://api.esios.ree.es/).\n\n### Indicators\n\n```python\nfrom esiosapy import ESIOSAPYClient\nfrom esiosapy.models.indicator.time_trunc import TimeTrunc\n\nclient = ESIOSAPYClient(token=\"your_esios_api_token\")\n\n# Get all indicators\nindicators = client.indicators.list_all()\n\n# Search indicators by name\nsolar = client.indicators.search(\"solar\")\n\n# Get data for an indicator\nindicator = indicators[0]\ndata = indicator.get_data(\"2021-01-01\", \"2021-01-02\", time_trunc=TimeTrunc.HOUR)\n```\n\n### Archives\n\n```python\nfrom esiosapy import ESIOSAPYClient\nfrom esiosapy.models.archive.archive_date_type import ArchiveDateType\n\nclient = ESIOSAPYClient(token=\"your_esios_api_token\")\n\n# Search files by date range\narchives = client.archives.list_by_date_range(\n    \"2021-01-01T00:00:00.000+01:00\",\n    \"2021-01-02T00:00:00.000+01:00\",\n    date_type=ArchiveDateType.PUBLICATION,\n)\n\n# Download, unzip, and clean up\narchives[0].download_file(unzip=True, remove_zip=True)\n```\n\n### Async usage\n\n```python\nimport asyncio\nfrom esiosapy import AsyncESIOSAPYClient\n\nasync def main():\n    async with AsyncESIOSAPYClient(token=\"your_esios_api_token\") as client:\n        indicators = await client.indicators.list_all()\n\nasyncio.run(main())\n```\n\n### Context manager\n\nBoth sync and async clients support context managers for automatic resource cleanup:\n\n```python\nwith ESIOSAPYClient(token=\"your_esios_api_token\") as client:\n    indicators = client.indicators.list_all()\n```\n\n### CLI\n\n```bash\n# List all indicators\nesiosapy --token YOUR_TOKEN indicators\n\n# List all archives\nesiosapy --token YOUR_TOKEN archives\n\n# Set custom timeout\nesiosapy --token YOUR_TOKEN --timeout 60 indicators\n```\n\n## Dependencies\n\nesiosapy depends on [Pydantic](https://docs.pydantic.dev/), [requests](https://requests.readthedocs.io/), and [tenacity](https://tenacity.readthedocs.io/).\n\n## Contributing\n\nAll contributions are welcome! Please read the [contributing guide](CONTRIBUTING.md) for details on how to get started.\n\n## License\n\nThis project is licensed under the GPL-3.0-or-later license. See the [LICENSE](LICENSE) file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fm4rc0sx%2Fesiosapy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fm4rc0sx%2Fesiosapy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fm4rc0sx%2Fesiosapy/lists"}