deltatwin login

It logs the user to the DeltaTwin Service, and allows the use of commands, such as deltatwin list command, that requires online registration.

Once logged in, all the information are stored in a conf.ini file, if you want to login again you just have to use the command deltatwin login, it will try to refresh the token.

deltatwin login [OPTIONS] [USERNAME] [PASSWORD]

Options

-h, --help

Show this message and exit.

-c, --conf <conf>

Path to the configuration file that stores connection user data.

-a, --api <api>

Url to the DeltaTwin API service.

-f, --force

Log again the user without using the refresh token.

Arguments

USERNAME

Optional argument

PASSWORD

Optional argument

All connection information is stored in a conf.ini file. The path to this file can be set by the user.

deltatwin login username password -a http://delta-api.com

This command will log in to the service with the api given in argument. To set the service you want to query, you can either use –api, or set the path to your configuration file –conf. If no path is given, the conf.ini is saved in the .delta folder in your home directory.

INFO: Login to the service token saved in /home/jiloop/.deltatwin/conf.ini

When log, all the connection information will be stored into a configuration file (conf.ini), it will contain the token, and the api url, all the information mandatory to interact with, the deltatwin services.

Once this file is created, you can simply log again using this command.

deltatwin login

It will find all the connection information into the configuration file.


deltatwin version

Prints the DeltaTwin command line version currently used.

deltatwin version [OPTIONS]

Options

-a, --all

If present this option will also show the version of the delta-core.

-h, --help

Show this message and exit.

deltatwin version

Prints the DeltaTwin® command line version currently used.

DeltaTwin® CLI version : 1.2.0
deltatwin version --all

Prints the DeltaTwin® command line version and the core version installed.

DeltaTwin® CLI version : 1.3.0
DeltaTwin® CORE version : 1.1.0

deltatwin list

List the DeltaTwins components available to the user. The user can view his Delta component details, all the Delta components from the Starter Kit and those created with the visibility public.

This command will list the DeltaTwins components of the user. Before using this command the user must be logged in.

deltatwin list [OPTIONS]

Options

-c, --conf <conf>

Path to the conf file

-f, --format-output <format_output>

Format of the output json/text default is text

-h, --help

Show this message and exit.

deltatwin list

This command will list the DeltaTwin® components visible to the user, it includes, the user’s DeltaTwin® components, all the DeltaTwin® components of the Starter Kit and all the published DeltaTwins with public visibility. By default the information’s will be displayed as an array, these information can also be retrieved as a json.

deltatwin list --format-output json

This command will list the DeltaTwin® components of the user. Before using this command the user must be logged in, using the delta login command.

[
    {
        "name": "Deltatwin1",
        "description": "Description of the Deltatwin1",
        "creation_date": "2024-02-21T13:16:47.548Z",
        "license": "LGPLv3",
        "topics": [
            "starter-kit",
            "sentinel-2",
            "optical",
            "color-composition"
        ],
        "author": "delta-user"
    },
    {
        "name": "Deltatwin2",
        "description": "Description of the Deltatwin2",
        "creation_date": "2024-02-21T13:16:47.548Z",
        "license": "LGPLv3",
        "topics": [
            "starter-kit",
            "sentinel-2",
            "optical",
            "color-composition"
        ],
        "author": "delta-user"
    }
]

deltatwin get

Get information about a DeltaTwin component by specifying its name. By default, the command returns information for the latest version of the Delta component. To get information about a previous version, you must specify it with the –version option ‘delta get [deltatwin_name] –version x.y.z’. To get the list of all available versions you can either use ‘deltatwin list –version’ or ‘deltatwin get [deltatwin_name] –version’. DT_NAME : DeltaTwin component name [MANDATORY]

This command will show the DeltaTwin component information, before using this command the user must be logged in.

deltatwin get [OPTIONS] DT_NAME

Options

-c, --conf <conf>

Path to the conf file

-f, --format-output <format_output>

Format of the output json/text default is text

-v, --version <version>
-h, --help

Show this message and exit.

Arguments

DT_NAME

Required argument

deltatwin get dt_name -f json

This command will show the information of a DeltaTwin® component, before using this command the user must be logged in, using the delta login command.

{
    "name": "Deltatwin2",
    "description": "Description of the Deltatwin2",
    "publication_date": "2024-03-07T12:50:55.055721Z",
    "topics": [
        "starter-kit",
        "sentinel-2",
        "optical",
        "color-composition"
    ],
    "version": "1.1.0",
    "available_version": [
        "1.1.0",
        "1.0.1",
        "1.0.0"
    ],
    "author": "delta-user",
    "inputs": [],
    "outputs": []
}