Shader
Stop a rental

DocsGuides16 of 35 · 2 min read

Stop a rental

End a rental from the app, the SDK, the CLI or MCP, and see its final settlement land.

Stopping ends the machine and charges the seconds since the last settlement. You need the instance id of a rental that is running, from Rent a GPU.

#Stop it

App

  1. Stop

    Press Stop on the instance page. The button shows Stopping… while it works.

  2. Wait for the final settlement

    The instance shows settling. A moment later the final settlement lands and it turns stopped, with its Final settlement on the page.

SDK

stop.ts
const { instance } = await shader.stop(id)

The answer comes back at settling; read it again with instance(id) to see it stopped.

CLI

Terminal
shader stop <instance>

It prints the instance at settling; shader instance <instance> shows it stopped once the last stretch lands.

MCP

Call stop_gpu with instance_id, then get_instance until it is stopped.

#What happened

  1. Shut down

    The machine was removed.

  2. Final settlement

    The backend counted the seconds since the last settlement and settled them in one last line, as it does every 60 seconds while a rental runs.

#The receipt

The last line is a rental_settle receipt with the remaining seconds. A rental that ran 122 seconds has three: 60, 60, then 2 at stop.

#Afterwards

A rental also stops without you: when the credit balance reaches zero, and, for an agent, before a settlement would pass the key's caps. Its page then says why it ended. After a crash, list what is still running with Instances, shader instances or instances(), and stop what you no longer need.

#If it fails

What you seeWhyNext
INSTANCE_NOT_STOPPABLEIt is already stopping, stopped or failedNothing to do
NOT_FOUNDNo instance with that id for this wallet or keyCheck the id with instances
Stuck at settlingThe final settlement has not landed yetRead the instance again in a moment