Command Line Tool
  • 17 Oct 2023
  • 1 Minute to read
  • PDF

Command Line Tool

  • PDF

Article summary

While the 12d Synergy Cmd Line tool is not an API, it can be used in batch processing to automate tasks without needing to program in .NET.

Each of the below commands can be used from the Windows Command Prompt or from another calling application.

They each of their own inputs, which are documented when running the command.

Generally speaking, the format to run this is:

"c:\program files (x86)\12d\12d synergy\4.0\client\app\12dSynergyCmdLine.exe" COMMAND INPUTS

If an input is more than one word (contains a space), it should be wrapped in quotes.

Example of Syntax:

12dSynergyCmdLine.exe <action> -server <server> -user <username> -password <password> -job <job full path> -path <folder path within job>

Example of a GET:

12dSynergyCmdLine.exe get -server localhost -user steve.smith -password Password1 -job "Jacaranda Company/Projects/20160001 - Emu Park" -path "03 Engineering/Letters"

This would do a get all on the folder and it would stored in the workspace.

You can also run the program without any arguments to see the available commands for your version:

12dSynergyCmdLine.exe

Each command then has its own individual -options. To view these, enter the command with no inputs or options as follows:

12dSynergyCmdLine.exe List

Command Description

CheckOut

Checks out a file, managed folder or 12d Model project

CheckIn

Checks in a file, managed folder or 12d Model project

CancelCheckOut

Cancels the checkout of a file, managed folder or 12d Model project

Add

Adds a new file

Get

Gets a file, managed folder or 12d model project

List

Lists the contents of a job or folder

CreateJob

Creates a new job

CreateFolder

Creates a new folder

GetJobName

Gets the job name from the current path in the workspace

Open

Opens a file

GetLocalPath

Gets the local path (a.k.a. workspace path) of a file, folder or 12d Model project

EditFolder

Updates information about a folder

FileInfo

Gets information about a given file

FolderInfo

Gets information about a given folder

Purge

Purge a file, managed folder or 12d Model project

Script

Accepts a text or console input for a set of these commands

FileListReport

Generates a File List Report on a job

AddFiles

Adds multiple files.

The -files arg is a bit ambiguous but seems to work with a wildcard, e.g. c:/temp/a* will upload all files beginning with "a" in the temp folder

To upload files in the current working directory, try something like ./*.docx (where ./ signifies the cwd) or ./* to match everything.

Subdirs seem to be ignored

GetProjectName


SetJobAttributes


SyncConnector



Was this article helpful?