CLI commands

CLI commands

FactoryTalk Optix Studio
includes these command-line interface (CLI) commands.
TIP:
The following commands assume that you installed
FactoryTalk Optix Studio
in the default location. If you selected a custom location for your
FactoryTalk Optix Studio
installation, modify the paths accordingly.
To shorten the commands and invoke the executable with
FTOptixStudio
, add a system environment variable or navigate to the
FactoryTalk Optix Studio
installation directory.
TIP: The
--help
,
-h
, and
--version
commands take precedence over other commands.
--help
and
-h
take precedence over
--version
.

open

Use the
open
command to open a project in
FactoryTalk Optix Studio
.
"C:\Program Files\Rockwell Automation\FactoryTalk Optix\
version
\FTOptixStudio" --open
project_to_open
[--silent]
Parameters
Parameter
Importance
Description
version
Required
Folder name that reflects the installed
FactoryTalk Optix Studio
version.
project_to_open
Required
Path to the
OPTIX
file of the project to open.
--silent
Optional
Make the command output non-verbose in the command prompt.

new

Use the
new
command to create a project.
"C:\Program Files\Rockwell Automation\FactoryTalk Optix\
version
\FTOptixStudio" --new
project_to_create
path
[-e | --encrypt-secrets] [--template=
template
] [--main-window-width==
width
] [--main-window-height==
height
] [-l | --in-project-location] [--silent]
Parameters
Parameter
Importance
Description
version
Required
Folder name that reflects the installed
FactoryTalk Optix Studio
version.
project_to_create
Required
Name for the project.
path
Required
Location for the project.
-e
or
--encrypt-secrets
Optional
Encrypt secrets in the project.
--template=
template
Optional
Name of the template to use for the project.
The allowed values for
template
are:
  • main
    (default)
  • optixPanel
  • empty
--main-window-width=
width
Optional
Width for the main window in pixels. The default width is
400
pixels
--main-window-height=
height
Optional
Height for the main window in pixels. The default height is
400
pixels
-l
or
--in-project-location
Optional
Create the project directly under
path
--silent
Optional
Make the command output non-verbose in the command prompt.

connect

Use the
connect
command to connect
FactoryTalk Optix Studio
with an endpoint.
"C:\Program Files\Rockwell Automation\FactoryTalk Optix\
version
\FTOptixStudio" --connect
endpoint
[--silent]
Parameters
Parameter
Importance
Description
endpoint
Required
The IP address of the endpoint to connect to.
--silent
Optional
Make the command output non-verbose in the command prompt.

deploy

Use the
deploy
command to deploy a
FactoryTalk Optix Application
to a local device.
Consider the following when working with the
deploy
command:
  • You need to perform any necessary versioning operations before the
    FactoryTalk Optix Application
    deployment.
  • You need to ensure that the
    FactoryTalk Optix Application
    builds without errors before the deployment.
  • You can only deploy
    FactoryTalk Optix Applications
    to local devices.
  • You cannot deploy
    FactoryTalk Optix Applications
    with encrypted secrets.
"C:\Program Files\Rockwell Automation\FactoryTalk Optix\
version
\FTOptixStudio" deploy
project_to_deploy
--ip-address=
ip_address
--username=
username
[--thumbprint=
certificate_thumbprint
] [--disable-project-encryption] [--disable-source-project-transfer] [--transfer-application-files] [--transfer-optimized-project] [--silent]
Parameters
Parameter
Importance
Description
version
Required
Folder name that reflects the installed
FactoryTalk Optix Studio
version.
project_to_deploy
Required
Path to the
OPTIX
file of the project to deploy.
ip_address
Required
IP address of the target device to deploy the
FactoryTalk Optix Application
to.
username
Required
Username for logging on to the target device
Windows®
username
A system username:
  • DOMAIN\
    username
    , for domain users.
  • .username
    , for local users on domain-joined devices.
  • username
    , for local users on devices that do not belong to a domain.
Linux username
An administrator username.
IMPORTANT: Specify user password as a
OPTIX_STUDIO_DEPLOYMENT_PASSWORD
system environment variable.
--thumbprint=
certificate_thumbprint
Optional
Provide certificate thumbprint of the target FactoryTalk Optix Application Update Service to prevent the need to interact with the trust dialog.
The trust dialog displays only for the first deployment.
Ensure that the FactoryTalk Optix Runtime Tools and Update Service are installed. Then, you can obtain the thumbprint by running this command
openssl x509 -fingerprint -in
UpdateServicePath
/PKI/Own/Certs/FTOptixApplication.der -inform DER -noout
where
UpdateServicePath
is the installation directory of the FactoryTalk Optix Application Update Service.
--disable-project-encryption
Optional
Disable project encryption.
--disable-source-project-transfer
Optional
Disable the transfer of the source project to the target device.
IMPORTANT: You can only transfer source projects to Windows target devices.
--transfer-optimized-project
Optional
Optimize the project before its transfer.
Optimized projects:
  • Are smaller in size because nodes are only loaded when needed at runtime.
  • Keep tags in an external tag repository and not in the project repository.
  • May require more time to load and change screens on low performance devices.
You cannot optimize projects containing OPC UA servers that expose the entire model or at least one tag.
--silent
Optional
Make the command output non-verbose in the command prompt.

export

Use the
export
command to export a
FactoryTalk Optix Application
to a file.
"C:\Program Files\Rockwell Automation\FactoryTalk Optix\
version
\FTOptixStudio" export
project_to_export
--platform=
platform
--location=
location
[--silent]
Example:
"C:\Program Files\Rockwell Automation\FactoryTalk Optix\
version
\FTOptixStudio" deploy "D:\Device Sizing Tool\Projects\BlankProject\BlankProject.optix" --ip-address=172.19.16.187 --username=admin
Consider the following when working with the
export
command:
  • You need to ensure that the
    FactoryTalk Optix Application
    builds without errors before the export.
  • You cannot set passwords for exported
    FactoryTalk Optix Applications
    .
  • You cannot export
    FactoryTalk Optix Applications
    with encrypted secrets.
Parameters
Parameter
Importance
Description
version
Required
Folder name that reflects the installed
FactoryTalk Optix Studio
version.
project_to_export
Required
Path to the
OPTIX
file of the project to deploy.
--location=
location
Required
Path to the location where you want to save the
FactoryTalk Optix Application
.
--silent
Optional
Make the command output non-verbose in the command prompt.

--help

Use the
--help
or
-h
parameter to display a summary of the available commands in the command prompt.
TIP: Using unexpected parameters also displays help.
"C:\Program Files\Rockwell Automation\FactoryTalk Optix\
version
\FTOptixStudio" --help

--version

Use the
--version
parameter to display the
FactoryTalk Optix Studio
version.
"C:\Program Files\Rockwell Automation\FactoryTalk Optix\
version
\FTOptixStudio" --version
Provide Feedback
Have questions or feedback about this documentation? Please submit your feedback here.