Skip to main content
POST
Scale app service

Authorizations

X-API-Key
string
header
required

API key for authentication. Each key is bound to a specific account.

Path Parameters

service_id
string
required

App service ID (UUID) or short id (the service_id field)

Body

application/json

An app can have at most 6 instances. The limit is checked only when a value goes up, so an app above it can always scale down.

replicas
integer

Fixed number of instances.

autoscaling_set
boolean

Send true to change the autoscaling fields: autoscaling_enabled, min_replicas, max_replicas, autoscaling_metric, autoscaling_target and scale_to_zero. With it, autoscaling_enabled and scale_to_zero are set exactly as sent, so leaving one out turns it off. Without it, only replicas changes.

autoscaling_enabled
boolean

Only read when autoscaling_set is true.

min_replicas
integer

Fewest instances when autoscaling. Cannot be more than max_replicas.

max_replicas
integer

Most instances when autoscaling.

autoscaling_metric
enum<string>

What autoscaling follows: concurrency, the requests in progress per instance. Autoscaling is for web apps and for private apps with scale_to_zero; a worker or an always-on private app runs a fixed number of instances.

Available options:
concurrency
autoscaling_target
integer

Requests in progress per instance before another instance starts.

scale_to_zero
boolean

Stop every instance when idle (the app sleeps about 15 minutes after its last request and wakes on the next one). Only for web and private apps, and only read when autoscaling_set is true.

Response

Updated service

success
boolean
service
object

An app service on the Raff PaaS — a web service, private service, worker, cron job, or one-off job.

Last modified on August 26, 2026