A python wrapper for the ESA mustlink API
Project description
mustlink
A python wrapper for the WebMUST API (mustlink)
This is a simple wrapper in python for the WebMUST API.
Dependencies
The following dependencies must be met:
- python 3
- matplotlib
- pandas
- pyyaml
- requests
Installation
pip
pip install mustlink
should do the job, although creating a dedicated environment is recommended (see below).
conda
First, clone this repository. If you are using conda, the dependencies can be installed in a new environment using the provided environment file:
conda env create -f environment.yml
The newly created environment can be activated with:
conda activate mustlink
Otherwise, please make sure the dependencies are installed with your system package manager, or a tool like pip
. Use of a conda environment or virtualenv is recommended!
The package can then be installed with:
python setup.py install
URL
The URL for the WebMUST instance in use can be specified when instantiating the Must class. If none is given, a default URL is used. For example:
must = mustlink.Must(url='https://mustinstance.com/mustlink')
Authentication
Access to WebMUST needs authentication. This is controlled by a config file which can be pointed to by the config_file
parameter when instantiating the Must class, for example:
must = mustlink.Must(config_file='path_to/config.file')
If nothing is specified, a file mustlink.yml
is looked for in paths pointed to by the environment variables APPDATA
, XDG_CONFIG_HOME
or in the .config
folder in the user's home directory.
The configuration file should be in YAML format and contain the username and password as follows:
user:
login: "userone"
password: "blah"
Example
The Jupyter notebook included with this repository shows an example of how to use the code. Note that not all API functions are wrapped by this library, but only those that are commonly used. To view the notebook, click here.
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
Built Distribution
File details
Details for the file mustlink-0.3.1.tar.gz
.
File metadata
- Download URL: mustlink-0.3.1.tar.gz
- Upload date:
- Size: 8.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/0.0.0 pkginfo/1.6.0 requests/2.24.0 setuptools/50.3.0.post20201006 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.8.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d8b2882cc71d8a20525d7b606b39bb9ecd4dc350b6815c757057c6ab9d6a9300 |
|
MD5 | d56933c5f4a5816c9b67a80ffbf93a7b |
|
BLAKE2b-256 | 386242766f2a244ee8bd70d0d2388645d03e91e94d0e02671fe394f95be961f2 |
File details
Details for the file mustlink-0.3.1-py3-none-any.whl
.
File metadata
- Download URL: mustlink-0.3.1-py3-none-any.whl
- Upload date:
- Size: 8.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/0.0.0 pkginfo/1.6.0 requests/2.24.0 setuptools/50.3.0.post20201006 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.8.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 86b53377a513fdd860cf61f0d35914a3e1ae67368a3a4e7b5344893933188ddd |
|
MD5 | 1449b1d64c8affcf52cf1c79288ced10 |
|
BLAKE2b-256 | 2eca194d5ba58f40bbb5bf12c8e0a7fbbf0d68b1522087fba8a12e4e0d7c8020 |