Destroy Machine
Changed onDelete a specific Machine within an app by Machine ID.
Only a Machine in the stopped, suspended, failed, pending or archived state can be deleted. Deleting a Machine in any other state, such as started, fails with 412 Precondition Failed unless you set force=true, which kills the Machine first. Deleting a Machine that is already destroying or destroyed succeeds without doing anything.
If someone else holds a lease on the Machine, the request fails with 409 Conflict. Pass the lease nonce in the fly-machine-lease-nonce header to delete a Machine you hold the lease on.
Request
- Base URLhttps://api.machines.dev
- URLhttps://api.machines.dev/v1/apps/{app_name}/machines/{machine_id}
- AuthHTTP bearer
Path parameters
Fly App Name
Machine ID
Query parameters
Kill the Machine first if it's not stopped, suspended, failed, pending or archived
Response
OK
Changes
- info
added the media type
application/jsonfor the response with the status - info
added the non-success response with the status
- info
added the non-success response with the status
- info
- info
endpoint added
- info