REST API - Add tags to a tagset - Octopus.Client.dll

Hello there,
I am trying to use Powershell to automate the creation of new environments/target machines and so tags mapped to the single tagset (in my scenario).
I have tried using Octopus.Client.dll. I can export the tagset with all the Tags, but I don’t know how to create a new tag and map to it. (I need probably to modify the existing tagset with the new tag in the instruction)…
Thank you for your help.
I am going insane :smiley:

Hi Lucio,

Deep apologies for the terrible delay here! Somehow this thread slipped through the cracks of our support process :(. Hope you are still sane!

Give this script a try and let me know how it goes:


Hi Dalmiro,
thanks for your reply.
I tried the instructions provided, and now I have the new tag in the $tagset.tags list, but if I check on the webpage I cannot find the created tag in the tagset.
PS: I have filled all the fields (apart the description).
Thank you for your time.

Hi Lucio,

Can you believe I forgot to add the line that saves the changes to the TagSet?

I just added it in github :). Go back to that same link and grab the latest version.

Sorry about that!


Hi Dalmiro.
It’s perfect. Thank you indeed.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.