List of certificates in octopus

I would like to utilize the rest api to list all certificates stored in octopus. Is this possible?

Hey Brian,

First and foremost, welcome to the Octopus forums!

Thanks for reaching out.

You can do this by getting a list of all spaces, then iterating on the certificates endpoint for each space.

The pseudo-code would be:
GET all spaces
FOREACH space in spaces
GET all certs
FOREACH cert in certs

You can adapt the logic in this script to get most of the way there: OctopusDeploy-Api/FindMachineMatchingUri.ps1 at master · OctopusDeploy/OctopusDeploy-Api · GitHub

Instead of working with the machines, you would work with the certificates endpoint.

You may already know, but a great way to find the endpoints for Octopus is to go to your URL for your Octopus instance and add /swaggerui to the url. e.g. https://octopus/swaggerui

Another method that I like to use is to do the action in the Octopus portal with the network tab of F12 in my browser open. You can click in and see the requests and responses for each call.

Please let me know if that helps or if you have any other questions.


Thank you for your quick response. This is exactly what I was looking for.

1 Like

Hey Brian,

You’re very welcome!

Please let me know if you hit any snags.

We’re here in the future for any other help you need.

I hope you have a great rest of your week.


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