Stopping a workspace via API endpoints

I would like to know if stopping a workspace using Coder API is possible.
5 Replies
Codercord
Codercord6mo ago
<#1363981120009404456>
Category
Help needed
Product
Coder (v2)
Platform
Linux
Logs
Please post any relevant logs/error messages.
Danielle
Danielle6mo ago
https://coder.com/docs/reference/api/builds#create-workspace-build If you send a stop transition to this endpoint it will stop a workspace You can see a usage of this in the CLI source (https://github.com/coder/coder/blob/823d3ea64ee24c661872125b9494aaacc204e23b/cli/stop.go#L55-L63)
Phorcys
Phorcys6mo ago
(@Abderrahim)
TheScientist
TheScientistOP6mo ago
Thanks
Codercord
Codercord6mo ago
@Phorcys closed the thread.

Did you find this page helpful?