There are two types of commands that can be included in a Configuration Management custom script:

  • Configuration Management commands
  • Device commands

Configuration Management commands are executed by Configuration Management itself. Device commands are executed by the device. Configuration Management commands begin with @ to distinguish them from device commands. Any command whose text begins with @ is a Configuration Management command, while any other command is a device command. In the previous example script, the @login and @write commands are Configuration Management commands, while all other commands are device commands.

Configuration Management defines the following commands:

  • @login
  • @connect
  • @write
  • @read
  • @read-more
  • @logout
  • @if
  • @endif
  • @scp-client-transfer
  • @sftp-client-transfer

The syntax for each of these commands is defined by Configuration Management. In contrast, Device commands are written using the native CLI commands supported by the device (IOS or CasOS commands for Cisco devices, Linux commands for Linux devices, etc.) These commands can use whatever syntax is required by the device's CLI command set.

In its simplest form, a command is just a string specifying the name of a command along with any parameters it requires. For example, the following script contains two simple commands:

@ login

username $(NewUserName) password $(NewPassword)