Creating Agent Procedures in Kaseya VSA: Tips and Tricks

Agent-Procedure-Featured-Image

Agent Procedures are the Swiss Army Knife of Kaseya VSA and are crucial for doing more with less. Utilizing procedures within your environment can help reduce 2-hour tasks to 2 minutes, saving valuable time for your team! Before we get started, here is Kaseya’s official reference document.

The first thing step to creating a new procedure is giving it a name. Your team having its own naming convention, whether basic or advanced, is crucial for current and new members to understand what a procedure does simply by name and allows for easier searching based on keywords.

Some examples include:

  • Install – ApplicationName
  • Remove – ApplicationName
  • Wifi Profile – ClientName
  • VPN Connection – ClientName
  • Add Printer – PrinterName – ClientName

Creating procedure templates can be extremely useful by allowing team members an easy way to create a procedure based on a tried and tested procedure template. Templates can be as simple or as advanced as your expertise allows. If the procedure works, that’s all that matters. Procedures can always be modified as your skills and needs increase, just make sure you have comments to help your team members more easily understand the steps you have added. Comments can be created by starting a line off with “//” followed by an explanation of the next line or lines.

creating-comments-procedure-template

To get you started, here are a few templates for your use or just as reference. Procedure Templates

When creating procedures, think BIG! If you have a solution to install that has client specific tokens, instead of having the mindset “I need a procedure for each Organization”, think “How can I utilize a single procedure for all clients?” In the same way templates can be utilized to simplify procedure creation, Managed Variables can be used to assign specific data directly to Organizations and Machine Groups and allow you to pull that data in by calling it from a procedure using the “getVariable” Parameter, assigning “Constant Value” and calling a Managed Variable by typing “<” and selecting the variable needed. You can then pass that data into the installation arguments.

How to create variables
How to call variables in procedures

If you have software that cannot pass variables through command line arguments and requires its own installation package, you can still use a single procedure by using Managed Variables to call the location of the media from Managed Files. This solution uses Database Views to call the “groupName’ of the machine the command is executed against. The groupName is displayed as the “ReverseGroupID” which can be easily found on the Manage Agents function under the Agents module.

This solution requires you to create a folder matching the “ReverseGroupID” and placing the installer into that folder. You then call the media by using “writeFile” statement being the location, and the name of the variable. While this is not an optimal solution, it will prevent you from having multiple policies and procedures to upkeep for a single installer.

manage-agents-image-3
getvariable-group-image-4

Procedures can be used to pull and store information in Custom Fields that would not be otherwise gathered by Kaseya Audits. If you can get the data to write to shell, you can write that data to a Custom Field. To do this, you need to ensure that “Return Results” is set to true and then call that data using “#global:psresult#”. You can write the data to the machine’s procedure log using the “writeProcedureLogEntry” statement or to a Custom Field by use the “updateSystemInfo” statement. This is very useful when auditing software, but not at all limited to it. Let’s look at a procedure that checks if LastPass is installed.

  • PowerShell is determining if the application exists and is returning results because the TRUE option is set.
  • checkVar reads the output of the above PS command from the “global:psresults” and determines if a word is present
  • Based on that, the procedure uses “updateSystemInfo” to write a specific phrase to the “cPVAL LastPass Status” Custom Field
PowerShell-true-image-5

Lastly! We have several videos covering the topic of Agent Procedures on our YouTube that I know you will find useful. I’ve included links here.

For more information or tips and tricks on Kaseya VSA please reach out to us!

They truly act as an extension of our team, providing the right consulting support exactly when we need it.

ProVal brings deep, hands-on knowledge of how ConnectWise PSA really works, combined with a thoughtful, consultative approach that sets them apart.

They listen first—both to understand our environment and who we are as an organization—and focus on finding the right solutions rather than pushing products. With strong command of best practices and experience across many MSP environments, they truly act as an extension of our team, providing the right consulting support exactly when we need it.

michael-lafond
Michael LaFond
ConnectWise Program Manager
New Charter Technologies

Creating Agent Procedures in Kaseya VSA: Tips and Tricks

Agent-Procedure-Featured-Image

I truly view ProVal as a partner and extension of my team, not as one of my vendors

When our NOC Manager left last fall we wanted to replace the position with an outsourced NOC to reduce headcount, and bring in an expert to both Labtech and our backup solutions. Bringing in ProVal Technologies was one of the best decisions we made last year and has paid for itself.During our first few monthly recurring Labtech admin meetings the ProVal team discovered incorrect settings and policies that were not applying correctly in our Labtech server. Things that we thought were automated and working were not. For example, there were multiple scripts and policies running but set to do nothing such as disk cleanup scripts. Cisco Umbrella was not configured correctly. Server alerting was not set right and the list went on.The backup team sends daily and weekly reports and updates that reduce my technicians time that we used to spend on backup or antivirus tickets that took forever and were tedious.ProVal also brings in great insights to our business and really cares about our success. They will frequently mention to me in meetings what new scripts they can import to make us more efficient or will schedule upgrades to our backups, Labtech, etc so I don’t have to worry. I truly view ProVal as a partner and extension of my team not as one of my vendors.

Chris-Warnick-Headshot
Chris Warnick
Vision Computer Solutions
Northville, MI

They will quickly become an extension of your team and your ROI will reflect the results

We have been a long time user of Labtech and had tried for many years to manage the product internally with no real success at the level we needed to make our solutions more efficient for our customers. Once we hired Vikram and his team at ProVal, it solved all our pain points with the product and we really felt like we were leveraging the tool as it was designed. If this sounds like you and it’s keeping you up at night, then you need these guys. They will quickly become an extension of your team and your ROI will reflect the results.

Bryan-Wolff-Headshot
Bryan Wolff
CEO, Wolff Logics LT Managed & Admin Services
Cedar Park, Texas

They work well, fast and on budget

We met Vikram from ProVal Tech at Gary Pica’s Shnizzfest a year ago. Vikram explained the advantage of having trained, certified personnel take care of our recent Automate implementation. Even though we had taken an implementation package from ConnectWise to start up the program, we felt many custom configurations we needed for our business were lacking. We hired ProVal Tech after Automate was installed to help us with this task. From sales to technicians everyone was professional and knowledgeable. Onboarding was simple, and well documented. Tools on the web were supplied while we did the work, and they allowed us to track what was done, and see the improvements in the environment. It was easy to reach any of the team members, for any concern or question – all answered with courtesy and smile. Once the work was finished, we were given some training and explanations, add to that documentation, about the work and the scripts and features added to the program. We have been happily working with Automate since then. We can only recommend this efficient team of people for any work into Automate: they work well, fast and on budget.

Ben-Prevost-Headshot
Ben Prevost
FarWeb IT
Sherbrooke, Canada
Copy link