Metadata-Version: 2.4
Name: polyanalyst6api
Version: 0.37.6
Summary: polyanalyst6api is a PolyAnalyst API client for Python
Author-email: yatmanov <yatmanov@megaputer.ru>
License-Expression: MIT
Project-URL: documentation, https://polyanalyst6api-py.rtfd.io/
Project-URL: repository, https://github.com/Megaputer/polyanalyst6api-py
Project-URL: changelog, https://github.com/Megaputer/polyanalyst6api-py/blob/master/CHANGELOG.md
Keywords: megaputer,polyanalyst,polyanalyst6api,api
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Topic :: Internet
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Requires-Python: >=3.9
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: requests<3.0.0,>=2.32.2
Requires-Dist: pytus==0.2.1
Provides-Extra: test
Requires-Dist: pytest>=7.4.0; extra == "test"
Provides-Extra: docs
Requires-Dist: sphinx>=7.0.1; python_version >= "3.11" and extra == "docs"
Requires-Dist: sphinx-autodoc-typehints>=1.23.3; python_version >= "3.11" and extra == "docs"
Dynamic: license-file

[![Telegram Group](https://img.shields.io/badge/support-join-blue?logo=telegram)](https://t.me/+_AdHkBRnul4xZTg6)
[![PyPI package](https://img.shields.io/pypi/v/polyanalyst6api)](https://pypi.org/project/polyanalyst6api)
[![Downloads](https://static.pepy.tech/badge/polyanalyst6api/month)](https://pepy.tech/project/polyanalyst6api)
[![Supported Python versions](https://img.shields.io/pypi/pyversions/polyanalyst6api)](https://pypi.org/project/polyanalyst6api/)
[![MIT License](https://img.shields.io/github/license/megaputer/polyanalyst6api-py)](https://github.com/Megaputer/polyanalyst6api-py/blob/master/LICENSE)

Welcome to the official Python client library for the PolyAnalyst REST API.

This package provides python wrappers for PolyAnalyst applications, such as *Analytical Client*, *Scheduler*, *Drive*.
Using `polyanalyst6api` you can access and edit projects, publications, files and more.

## Installation

```shell
pip install -u polyanalyst6api
```
> Python 3.9 or later is required.

## Documentation

See [API Reference](https://polyanalyst6api-py.rtfd.io) for the client library methods.

Refer to PolyAnalyst's **User Manual** at **Application Programming Interfaces** > **Version 1** for REST API specification.

## Usage

Import and initialize a client:
```python
from polyanalyst6api import API

# using an api token
client = API(<POLYANALIST_URL>, token=<API_TOKEN>)

# or using PolyAnalyst user credentials. Note that in this case you need to call .login()
client = API(<POLYANALIST_URL>, <USERNAME>, <PASSWORD>)
client.login()
```

Request data using client methods:

```python
>>> prj = client.project(<prjUUID>)
>>> prj.status()
{'status': 'Loaded'}

>>> prj.get_node_list()
[{'id': 11,
  'name': 'Internet Source',
  'status': 'synchronized',
  'subtype': 'INET',
  'type': 'DataSource'},
 {'id': 12,
  'name': 'Python',
  'status': 'synchronized',
  'subtype': 'Python',
  'type': 'Dataset'}]
```

View the [examples](https://github.com/Megaputer/polyanalyst6api-py/tree/master/examples) directory for more code snippets.

## License

This project is licensed under the MIT License - see the [LICENSE](https://github.com/Megaputer/polyanalyst6api-py/tree/master/LICENSE) file for details
