Skip to content
README.md 1.54 KiB
Newer Older
carmelo's avatar
carmelo committed
# MatMust minimal Documentation

MatMust is a Matlab™ class to access to ESA WebMust via API.

Documentation of the ESA rest API is available [here](https://bepicolombo.esac.esa.int/webclient-must/mustlink/api-docs/index.html#/Projects/getProjects).

A comprehensive example is available in `/test` of this repository. Simply copy all the folder in your working directory and run test.

## Installation

To install simply copy the `src/classes` folder into your working directory and type in matlab `addpath('relativepathto_classes_dir')`

Than simply initialize the class with Mywebmustclass = MatMust. 

When the user will login via the login class method `MatMust_login()` a auth.json file with the authorization tocken will be wrote on your workingdirectory root.  

The tocken is valid for a 24h only. If the class see a expired tocken, a new login is requested to renew the authorization token to the API.

## List of Methods

The functions for this issues is only oriented to TM parameters read. The TC part is foreseen, but still to be wrote.

### Matmust Login 

`MatMust_login(M, loginjson)`
inputs: 
- `M` -> A MutMust Class
- `loginjson` -> `jsondecode('{"username": "ajejebrazorv",  "password": "123456%!", "maxDuration": false}')`
Outputs:
none

When the user will succesfully login via the login class method `MatMust_login()` a auth.json file with the authorization tocken will be wrote on your workingdirectory root.  

- `MatMust_logincheck(M)`

A check method

- `MatMust_getUserProjects`
- `MatMust_getDataFromName`
- `MatMust_searchTMparFromName`