A mini SDK for interacting with the LLC Science Admin
Project description
LLC Science SDK
A simple way to fetch scientific data from the Science Admin. Please visit {BASE_URL}/api/schema/swagger-ui/#/ for more information on the API.
Installation
pip install llcsciencesdk
Updating to a new version
pip install llcsciencesdk -U
Usage
Specifying environment
from llcsciencesdk.llc_api import ScienceSdk
llc_api = ScienceSdk() # connect to production
llc_api = ScienceSdk(environment="staging") # connect to staging
llc_api = ScienceSdk(environment="local") # connect to localhost
llc_api = ScienceSdk(environment="http://127.0.0.1:8009") # connect to custom url
Logging in
from llcsciencesdk.llc_api import ScienceSdk
llc_api = ScienceSdk()
llc_api.login("username", "password")
Using the endpoints
from llcsciencesdk.llc_api import ScienceSdk
llc_api = ScienceSdk()
llc_api.login("username", "password")
model_input = llc_api.get_ft_input(1)
planting_design_list = llc_api.get_planting_design_list()
planting_design_detail = llc_api.get_planting_design(10)
Supported endpoints
See the swagger docs for a complete list. {BASE_URL}/api/schema/swagger-ui/#/
For Developers
Updating package
- Make sure you have supported version of flit installed (see project.toml).
python3 -m pip install flit
- Set env variables for PiPy login:
Get the token from the PiPy website and run the following commands:
- Update the version of the API in the init.py file.
- Run command to publish to PiPy:
flit publish
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
llcsciencesdk-2.2.7.tar.gz
(9.8 kB
view details)
Built Distribution
File details
Details for the file llcsciencesdk-2.2.7.tar.gz
.
File metadata
- Download URL: llcsciencesdk-2.2.7.tar.gz
- Upload date:
- Size: 9.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: python-requests/2.32.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ff86cb06ecbc45602e9b14a6151e12dbb5e66af20f80b1d39007ef0d7c967deb |
|
MD5 | ccffccabd5033932eba65fb8fe1a23d2 |
|
BLAKE2b-256 | 009d84efeb9adce856c6e75bdcfa0ae461613e62d4e48e8f4a8c74bd9af4cd02 |
File details
Details for the file llcsciencesdk-2.2.7-py2.py3-none-any.whl
.
File metadata
- Download URL: llcsciencesdk-2.2.7-py2.py3-none-any.whl
- Upload date:
- Size: 11.1 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: python-requests/2.32.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 57909c63da0d8abef8b8ee2ded26efd32a30cfd0f3a40b30bf328e57cc4af9ca |
|
MD5 | 11fa1bcf8fddb07046a5efb8038df795 |
|
BLAKE2b-256 | c0221e60e5bd8507ec061605eb5400414809c3d3d446eefb71a0e7f5e0901b4b |