Tia-Portal-CLI

Install and harmonise a TIA Portal global library by command

A library is how one engineered solution reaches many projects. These verbs create and read global libraries, install a whole library on a PLC, check which project types are behind their library version, and harmonise the project against it.

24 of the 351 verbs · TIA Portal V19, V20 and V21

tia list-library --file X.al19
master copies and types of a global library file, with their folder path
tia retrieve-library --file X.zal19 [--dir D] [--upgrade] [--apply]
unarchives .zal1x → .al2x
tia create-library --file X.al21 [--folder A/B]... [--apply]
empty library
tia lib-update-check --file X.al21 [--all]
whether the instance in the project is behind the version in the library
tia lib-update-project [--file X.al21] [--name T] [--plc P] [--apply]
applies to the project the version in the library
tia lib-harmonize-project [--file X.al21] [--name T] [--plc P] [--mode names|paths|names,paths] [--apply]
aligns the NAME and the FOLDER of the instances with those of the library
tia import-master-copy --file X.al19 --name M [--folder A/B] [--apply] [--force]
--force: deletes the one with the same name and recreates it
tia import-library-type --file X.al21 --name T [--folder A/B] [--unit U] [--apply]
instantiates a library TYPE in the PLC
tia add-master-copy [--file X.al21] (--name BLOCK | --folder A/B) [--lib-folder L] [--apply]
PLC → library
tia delete-master-copy [--file X.al21] --name M [--apply]
without --file the PROJECT library
tia compare-library --file X.al21 [--all] [--max 200] [--detail]
read-only: the PROJECT library against a global library file
tia compare-type --file X.al21 --name T [--version V] [--all]
read-only: ONE element of the project library against the one with the same name in the global library file
tia list-project-library
the PROJECT library
tia copy-project-type --file X.al21 --name T [--apply]
copies a type from the global library into the project library
tia import-project-type --name T [--folder A/B] [--unit U] [--apply]
instantiates in the PLC a type from the project library
tia delete-project-type --name T [--apply]
deletes the type and every version
tia export-library-doc --name T --dir D [--file X.al21] [--doc N] [--version V] [--format F] [--info-file] [--apply]
exports a library type version as document(s)
tia create-library-doc --dir D --doc N [--file X.al21] [--name T] [--plc P] [--unit U] [--override] [--apply]
the other side: builds a type from exported documents
tia list-type-instances --name T [--plc P] [--file X.al21] [--version V]
read-only: where the instances of a library type live inside a PLC (FindInstances), version by version
tia edit-type-version --name T [--plc P] [--file X.al21] [--version V] [--apply]
opens a new IN-WORK version out of a committed one (Edit)
tia release-type-version --name T [--file X.al21] [--version V] [--author A] [--comment C] [--no-deps] [--apply]
commits the in-work version and write-protects it (Release)
tia discard-type-version --name T [--file X.al21] [--version V] [--apply]
throws the in-work version away (Discard) and every use falls back to the last released one
tia set-default-type-version --name T --version V [--file X.al21] [--apply]
makes that version the default one (SetAsDefault), the version a new instance gets
tia delete-type-version --name T --version V [--file X.al21] [--apply]
deletes ONE version of the type, against delete-project-type which takes the type with all of them

Common questions

How do I bring a TIA Portal global library into a project by command?

tia retrieve-library opens the library, tia import-library-type and tia import-master-copy bring its types and master copies in, and tia lib-harmonize-project aligns the project with it.

How do I find project types that are behind their library version?

tia lib-update-check lists them and tia lib-update-project applies the update; tia compare-library and tia compare-type show the difference, and tia list-type-instances finds every instance before a version change.

Run these verbs on your own project

Every verb above takes JSON on the way out and plain flags on the way in. Tia-Portal-CLI is local and on-premise: nothing is sent to a cloud service, and every write is a preview until you pass --apply. 14-day free trial, e-mail only, no card.

Start a 14-day free trial

Other verb families