curl --request PUT \ --url 'https://api.e2enetworks.com/myaccount/api/v1/scaler/scalegroups/{scaler_id}?project_id=<PROJECT_ID>&apikey=<API_KEY>&location=<LOCATION>' \ --header 'Authorization: Bearer <API_TOKEN>' \ --header 'Content-Type: application/json' \ --data '{ "cardinality": 2, "update_min_nodes": true}'import requests
response = requests.put( "https://api.e2enetworks.com/myaccount/api/v1/scaler/scalegroups/{scaler_id}", params={"project_id": "<PROJECT_ID>", "apikey": "<API_KEY>", "location": "<LOCATION>"}, headers={"Authorization": "Bearer <API_TOKEN>"}, json={ "cardinality": 2, "update_min_nodes": True, },)print(response.json())const url = new URL("https://api.e2enetworks.com/myaccount/api/v1/scaler/scalegroups/{scaler_id}");url.search = new URLSearchParams({ project_id: "<PROJECT_ID>", apikey: "<API_KEY>", location: "<LOCATION>" });
const response = await fetch(url, { method: "PUT", headers: { "Authorization": "Bearer <API_TOKEN>", "Content-Type": "application/json" }, body: JSON.stringify({ "cardinality": 2, "update_min_nodes": true }),});console.log(await response.json());Manually sets the number of running nodes (cardinality) for the group. The requested cardinality must be within the group’s [min_nodes, max_nodes] range. Set update_min_nodes: true to also raise min_nodes to the new cardinality so autoscaling does not immediately scale back down. A resize is rejected with 412 Precondition Failed if the group is not in a resizable state (for example while it is already SCALING).
Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The id of the auto scaling group, as returned by List.
Example
12345Query Parameters
Section titled “Query Parameters”Identifier of the project to scope the request to. Required integer project ID.
Example
<PROJECT_ID>API key used to authenticate the request.
Example
<API_KEY>Region of the group.
Example
<LOCATION>Request Body
Section titled “Request Body”Manually set the number of running nodes for the group.
object
Target number of running nodes.
Example
2When true, also raise min_nodes to the new cardinality so autoscaling does not scale back down.
Example
trueExample
{ "cardinality": 2, "update_min_nodes": true}Responses
Section titled “Responses”Successful response
Resize confirmation. A resize on a group that is not in a resizable state returns 412 Precondition Failed with the reason in errors (for example “Service cannot be scaled in state: SCALING”).
object
object
object
Example
{ "code": 200, "message": "Success"}