https://github.com/ail-project/pyail
Python library using the AIL Rest API
https://github.com/ail-project/pyail
Last synced: about 1 year ago
JSON representation
Python library using the AIL Rest API
- Host: GitHub
- URL: https://github.com/ail-project/pyail
- Owner: ail-project
- License: bsd-3-clause
- Created: 2020-05-27T20:50:56.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2024-10-04T09:59:32.000Z (almost 2 years ago)
- Last Synced: 2024-11-08T20:18:09.656Z (over 1 year ago)
- Language: Python
- Size: 77.1 KB
- Stars: 7
- Watchers: 7
- Forks: 1
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
PyAIL
======
[](https://www.python.org/downloads/release/python-360/)
# PyAIL - Python library using the AIL Rest API
PyAIL is a Python library to access [AIL](https://github.com/ail-project/ail-framework) platforms via their REST API.
## Install from pip
**It is strongly recommended to use a virtual environment**
If you want to know more about virtual environments, [python has you covered](https://docs.python.org/3/tutorial/venv.html)
Install pyail:
```bash
pip3 install pyail
```
## Usage
### Feeding items to AIL
```python
from pyail import PyAIL
ail_url = 'https://localhost:7000'
ail_key = ''
try:
pyail = PyAIL(ail_url, ail_key, ssl=False)
except Exception as e:
print(e)
sys.exit(0)
data = 'my item content'
metadata = {}
source = ''
source_uuid = ''
pyail.feed_json_item(data, metadata, source, source_uuid)
```
# License
This software is licensed under BSD 3-Clause License
Copyright (C) 2020-2023 CIRCL - Computer Incident Response Center Luxembourg
Copyright (C) 2020-2023 Aurelien Thirion