UA-Ilab-Tools
A set of tools that interact with Ilab's REST database.
Motivation
Was designed to implement a simple way to interact with Ilab's REST architecture.
Features
- ilab_api.py contains a class to use simple REST functions such as GET, PUT, POST, and DELETE.
- ua_ilab_tools.py contains a class to interact with the REST architecture outside of the simple REST verbs, such as:
- get_service requests which returns the service requests with a given status.
- get_service_cost which returns the cost associated with a given service_id.
- get_request_charges which returns all of the charges of the request id.
- get_milestones which returns all of the milestones associated with a service request.
- get_custom_forms which returns all of the custom forms associated with the request id.
- extract_project_info which gets the relevant project info from a request.
- extract_custom_form_info which gets all of the fields of a form.
Code Example
from ua_ilab_tools import ilab_api, ua_ilab_tools
api = ilab_api.IlabApi(core_id, auth_creds)
# "token" contains the Authorization information for headers.
tools = ua_ilab_tools.IlabTools(core_id, token)
prj_info = ua_ilab_tools.extract_project_info(soup)
form_info = ua_ilab_tools.extract_custom_form_info(
req_id, form_id, form_soup)
Installation
pip install ua-ilab-tools
Tests
You will have to create a file named "ilab_creds.json" in the format of:
{
"token": "Bearer {your token}",
"core_id": "{your core_id}"
}
```bash
pip install --update nose
cd ./ua_ilab_tools
cd ./tests
nosetests test_ilab_tools.py
How to Use
- Get general endpoints
- Get information associated with specific service requests.
- Get data associated with specific projects and custom_forms.
Credits
License
MIT
Metadata
Release files for ua-ilab-tools 2.1.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| ua_ilab_tools-2.1.4.tar.gz | 23.5 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| ua_ilab_tools-2.1.4-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 55.5 kB
Release files / ua_ilab_tools-2.1.4.tar.gz
| Download URL | ua_ilab_tools-2.1.4.tar.gz |
|---|---|
| Size | 23.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
afae512d10a037713eb19104debdda7ec793edfc90f564ac3fd81ce0e001bd70
|
|
BLAKE2b-256 checksum How to use checksums |
606a23b98e17a03a6dc2e46e6c4c12d643434fd29ed723d3cf97607c87f40a36
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.3 CPython/3.12.4 Linux/6.5.0-41-generic
|
Release files / ua_ilab_tools-2.1.4-py3-none-any.whl
| Download URL | ua_ilab_tools-2.1.4-py3-none-any.whl |
|---|---|
| Size | 32.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9d0e8d7e9bd65d9ffe5151a51f4e0cac4e8c7f494e8e0875be3d4610f7a953fe
|
|
BLAKE2b-256 checksum How to use checksums |
dcad4346cb39e3ef6772fe8e119ec514cc0cb8391cf5184b8e8be862cf315f81
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.3 CPython/3.12.4 Linux/6.5.0-41-generic
|
Security for ua-ilab-tools 2.1.4
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.