Error when creating users API Key

Hi,

I am creating a new user in Octopus (version 2021.3.12372) and when I go to create an API Key I get the below error:

It will allow me to create an API Key if dont set an expiry date, but fails when I select any of the below options

image

Kind Regards,
Micheal Power

Hi @mikepower79,

Thanks for reaching out and for reporting you’re experiencing this issue.

Fortunately, we’re aware of this one and you can view more about the progress we’ve made by checking out the GitHub Issue.

This bug in particular has been fixed in 2022.1.184+.
It only appears to show up when creating a new API key via the Users page, if you follow the steps below from the GitHub Issue to create a key via your profile, it should allow you to change the expiry date:

1. Click into your profile (upper right)
2. Click API Keys
3. Click New API Key
4. Type in a name
5. Change the duration to one of the predefined durations
6. Click Generate new

I hope this helps! Please reach out if you have any further questions or concerns, or if you’re not able to generate an API key using this alternative method.

Kind Regards,
Adam

Hi @adam.hollow,
Thanks for the reply.
Do you know if it affects a Powershell script updating the expiry date on API Keys.

Kind Regards,
Micheal Power

Hi @mikepower79,

I believe that since the error is rooted in the UI of creating an API key particularly via the Users page, I would expect the underlying API call to still function as expected.

I haven’t explicitly tested this out but as the REST API is used when generating API keys from the Profile page, I don’t think PowerShell scripts will be impacted.

Kind Regards,
Adam

1 Like

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