Currently, I am creating GitLab environments for each merge request to deploy temporary pages. These environments stop as soon as merge request is merged, but I want to add an additional step to the pipeline to "Remove environment" completely from "Stopped" environments. I don't want to use GUI and only option I found was an API method:
DELETE /projects/:id/environments/:environment_id
https://docs.gitlab.com/ee/api/environments.html#delete-an-environment
But, problem here is that it required :environment_id
variable, which I couldn't manage to find and get.
Any help with a different approach or how to get :environment_id
will be appreciated.