Skip to content
Live resize of a volume through the public API (workspace token), without restarting the service
declic-app
OP

a month ago

Hi Railway team,

We run a platform on the Pro plan that deploys and manages many small services, each with its own volume. We grow volumes automatically when they reach 80% usage, through the public GraphQL API with a workspace token.

Today we resize with this mutation:

mutation ($e: String!, $p: EnvironmentConfig, $m: String) {
  environmentPatchCommit(environmentId: $e, patch: $p, commitMessage: $m, skipDeploys: true)
}

and this patch:

{ "volumes": { "<volumeId>": { "sizeMB": 10000, "allowOnlineResize": true } } }

The new size is applied, but the service attached to the volume is restarted with the same image. On October 14, 2026, it did not respond for about 7 seconds, although the volume was only about 2% full.

On the same volume, the dashboard's "Live Resize" button grew the volume with no restart and no new deployment. However, that button asks for a typed confirmation phrase and a 2FA code, so it is meant for a human and cannot be used by an automated workflow.

Our questions:

  1. Is there a supported way to do a live resize (no restart) through the public API with a workspace token?
  2. If so, which mutation and fields should we use? Does it require a 2FA code when called with a workspace token?
  3. Is allowOnlineResize the right field, and is it honored for changes committed through the API? Could skipDeploys or environmentPatchCommit be what causes the restart?
  4. If live resize is not available through the API today, is it planned?

We can share the project and volume IDs privately if that helps.

Thanks a lot!

Solved

1 Reply

Railway
BOT

a month ago

Volume size changes committed through the environment config always run as an offline resize, which restarts the attached service. Neither the online-resize setting in your patch nor skipping deploys changes that, since skipping deploys only controls service deployments. That matches the restart you saw on October 14.

The live resize behind the dashboard's Live Resize button is a separate operation from the environment-config path. We can't currently point you to it as a supported, documented public API workflow for automation, so we can't give you a mutation, fields, or 2FA behaviour to rely on, or a timeline for that.


Status changed to Awaiting User Response Railway • about 1 month ago


Railway
BOT

25 days ago

This thread has been marked as solved automatically due to a lack of recent activity. Please re-open this thread or create a new one if you require further assistance. Thank you!

Status changed to Solved Railway • 25 days ago


Welcome!

Sign in to your Railway account to join the conversation.

Loading...