Taxonomy
Manage taxonomies: list a summary of the available taxonomies if no option is provided, otherwise download, import or delete a taxonomy.
opal taxonomy <CREDENTIALS> [OPTIONS] [EXTRAS]
Options
Option |
Description |
---|---|
|
Download a taxonomy from the provided name, in YAML format |
|
Import a taxonomy from a YAML file in Opal file system. Fail if the taxonomy already exists. |
|
Delete a taxonomy from the provided name |
|
Skip taxonomy deletion confirmation |
Credentials
Authentication can be done by username/password credentials OR by personal access token OR by certificate/private key pair (two-way SSL authentication).
Option |
Description |
---|---|
|
Opal server base url |
|
Credentials auth: user name (requires a password) |
|
Credentials auth: user password (requires a user name) |
|
Token auth: user’s personal access token |
|
Two-way SSL auth: certificate/public key file (requires a private key) |
|
Two-way SSL auth: private key file (requires a certificate) |
Extras
Option |
Description |
---|---|
|
Show the command help’s message. |
|
Verbose output. |
|
Output pretty-print JSON |
Example
List the taxonomies:
opal taxonomy --opal https://opal-demo.obiba.org --user administrator --password password --json
Download a taxonomy in YAML format:
opal taxonomy --opal https://opal-demo.obiba.org --user administrator --password password --download MyTaxo > MyTaxo.yml
Upload a local taxonomy file (in YAML format) into the Opal file system and import it:
opal file --opal https://opal-demo.obiba.org --user administrator --password password --upload /path/to/MyTaxo.yml /home/administrator
opal taxonomy --opal https://opal-demo.obiba.org --user administrator --password password --import-file /home/administrator/MyTaxo.yml
Delete a taxonomy:
opal taxonomy --opal https://opal-demo.obiba.org --user administrator --password password --delete MyTaxo