# ![logo Tehzor](https://tehzor.com/images/components/Header/logo.svg)
![PyPI - Version](https://img.shields.io/pypi/v/tehzor)
## Обертка над API системы Техзор на python (async/await)
Официальная документация [https://api.tehzor.ru/docs](https://api.tehzor.ru/docs)
## Установка
```bash
pip install -U tehzor
```
## Примеры
Обновления параметров квартир (площадь, плащадь БТИ, тип отделки ...). Предварительно необходимо знать id квартир и id типа отделки:
```python
import asyncio
from tehzor import TehzorAPI
from examples.excel_apartments import result_flats
API_KEY = "00000000-0000-0000-0000-000000000000"
USER_ID = "123d7cdfc7ea123d123456ab"
async def main():
thz = await TehzorAPI.create(api_key=API_KEY, user_id=USER_ID)
async with asyncio.TaskGroup() as tg:
for id, data in result_flats.items():
tg.create_task(thz.update_spaces(id, data.model_dump_json()))
await thz.session_close()
if __name__ == "__main__":
asyncio.run(main())
```
## Внимание
Проект в разработке... Происходят изменения в исходном API (изменяются наименование методов, свойств объектов)
Raw data
{
"_id": null,
"home_page": "https://github.com/gritsyuk/tehzor",
"name": "tehzor",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.6",
"maintainer_email": null,
"keywords": "tehzor api tehzorapi construction supervision operation inspections constarctionsite building management",
"author": "Igor Gritsyuk",
"author_email": "gritsyuk.igor@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/2c/5a/2bebc041705eecee21efaa55140883ad2c4c16edd82d6c934197478580c2/tehzor-0.1.3.tar.gz",
"platform": null,
"description": "# ![logo Tehzor](https://tehzor.com/images/components/Header/logo.svg)\r\n![PyPI - Version](https://img.shields.io/pypi/v/tehzor)\r\n## \u041e\u0431\u0435\u0440\u0442\u043a\u0430 \u043d\u0430\u0434 API \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u0422\u0435\u0445\u0437\u043e\u0440 \u043d\u0430 python (async/await)\r\n\u041e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u0430\u044f \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044f [https://api.tehzor.ru/docs](https://api.tehzor.ru/docs)\r\n\r\n## \u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430\r\n```bash\r\npip install -U tehzor\r\n```\r\n\r\n## \u041f\u0440\u0438\u043c\u0435\u0440\u044b\r\n\u041e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u043a\u0432\u0430\u0440\u0442\u0438\u0440 (\u043f\u043b\u043e\u0449\u0430\u0434\u044c, \u043f\u043b\u0430\u0449\u0430\u0434\u044c \u0411\u0422\u0418, \u0442\u0438\u043f \u043e\u0442\u0434\u0435\u043b\u043a\u0438 ...). \u041f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0437\u043d\u0430\u0442\u044c id \u043a\u0432\u0430\u0440\u0442\u0438\u0440 \u0438 id \u0442\u0438\u043f\u0430 \u043e\u0442\u0434\u0435\u043b\u043a\u0438:\r\n\r\n```python\r\nimport asyncio\r\nfrom tehzor import TehzorAPI\r\nfrom examples.excel_apartments import result_flats\r\n\r\nAPI_KEY = \"00000000-0000-0000-0000-000000000000\"\r\nUSER_ID = \"123d7cdfc7ea123d123456ab\"\r\n\r\n\r\nasync def main():\r\n thz = await TehzorAPI.create(api_key=API_KEY, user_id=USER_ID)\r\n\r\n async with asyncio.TaskGroup() as tg:\r\n for id, data in result_flats.items():\r\n tg.create_task(thz.update_spaces(id, data.model_dump_json()))\r\n\r\n await thz.session_close()\r\n\r\n\r\nif __name__ == \"__main__\":\r\n asyncio.run(main())\r\n```\r\n## \u0412\u043d\u0438\u043c\u0430\u043d\u0438\u0435\r\n\u041f\u0440\u043e\u0435\u043a\u0442 \u0432 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0435... \u041f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u044f\u0442 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f \u0432 \u0438\u0441\u0445\u043e\u0434\u043d\u043e\u043c API (\u0438\u0437\u043c\u0435\u043d\u044f\u044e\u0442\u0441\u044f \u043d\u0430\u0438\u043c\u0435\u043d\u043e\u0432\u0430\u043d\u0438\u0435 \u043c\u0435\u0442\u043e\u0434\u043e\u0432, \u0441\u0432\u043e\u0439\u0441\u0442\u0432 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432) \r\n",
"bugtrack_url": null,
"license": null,
"summary": "A Python API wrapper for Tehzor API",
"version": "0.1.3",
"project_urls": {
"Download": "https://github.com/gritsyuk/tehzor/archive/refs/heads/develop.zip",
"GitHub": "https://github.com/gritsyuk/tehzor",
"Homepage": "https://github.com/gritsyuk/tehzor"
},
"split_keywords": [
"tehzor",
"api",
"tehzorapi",
"construction",
"supervision",
"operation",
"inspections",
"constarctionsite",
"building",
"management"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "0bbdac50ab08295a605daf13f9cd5190dc1bc931006b98651c490d8d67a5b287",
"md5": "f7dc6e73cf5541589bfea96a81ce60c4",
"sha256": "35ee0d2824640bbafcdf1d38b0f579600c34a5ca8036f07769a0fa2bc5d72c9c"
},
"downloads": -1,
"filename": "tehzor-0.1.3-py3-none-any.whl",
"has_sig": false,
"md5_digest": "f7dc6e73cf5541589bfea96a81ce60c4",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.6",
"size": 13586,
"upload_time": "2024-10-24T15:00:07",
"upload_time_iso_8601": "2024-10-24T15:00:07.185038Z",
"url": "https://files.pythonhosted.org/packages/0b/bd/ac50ab08295a605daf13f9cd5190dc1bc931006b98651c490d8d67a5b287/tehzor-0.1.3-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "2c5a2bebc041705eecee21efaa55140883ad2c4c16edd82d6c934197478580c2",
"md5": "9b3f231da6544627d401efc3913fed51",
"sha256": "2a45e6a0f45130290a074e20862e3d9df25161cf085b19edb3c3cb3e8c967284"
},
"downloads": -1,
"filename": "tehzor-0.1.3.tar.gz",
"has_sig": false,
"md5_digest": "9b3f231da6544627d401efc3913fed51",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.6",
"size": 9750,
"upload_time": "2024-10-24T15:00:09",
"upload_time_iso_8601": "2024-10-24T15:00:09.046290Z",
"url": "https://files.pythonhosted.org/packages/2c/5a/2bebc041705eecee21efaa55140883ad2c4c16edd82d6c934197478580c2/tehzor-0.1.3.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-10-24 15:00:09",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "gritsyuk",
"github_project": "tehzor",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "tehzor"
}