Create an L7 Load Balancer

POST/v1/load_balancers/l7

Send a POST request to /v1/load_balancers/l7 to create a new Load Balancer. Fill in the required parameters to specify details.

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Request Body

application/json

Response Body

application/json

application/json

curl -X POST "https://example.com/v1/load_balancers/l7" \  -H "Content-Type: application/json" \  -d '{    "name": "name676",    "location_id": 699,    "store_logs": true,    "store_logs_region_id": 0,    "geoip": "true",    "vhost_zones": [      {        "id": "name677",        "ports": [          338        ],        "ssl": true,        "http2": true,        "ssl_certificate_id": "X7axGrey",        "domains": [          "example-761.com"        ],        "location_zones": [          {            "location": "/path1",            "upstream_path": "/path2",            "upstream_id": "name678"          }        ],        "real_ip_header": {          "name": "forwarded_for",          "networks": [            "127.0.0.1/16",            "192.168.0.1/32"          ]        }      }    ],    "upstream_zones": [      {        "id": "name678",        "upstreams": [          {            "ip": "10.0.8.4",            "port": 339,            "weight": 1          }        ]      }    ],    "labels": {      "environment": "production",      "service": "my-web-app",      "example.com/project": "my-project",      "example.com/owner": "my-team"    }  }'
{  "id": "GRb4x1bB",  "name": "name681",  "type": "l7",  "status": "in_process",  "external_addresses": [],  "location_id": 701,  "redirect_http": false,  "geoip": true,  "geoip_enabled": true,  "store_logs": true,  "domains": [    "127.0.5.1"  ],  "vhost_zones": [    {      "ssl": true,      "http2": true,      "http2_push_preload": false,      "http_to_https_redirect": false,      "proxy_request_headers": [],      "id": "name682",      "ports": [        344      ],      "domains": [        "127.0.5.1"      ],      "location_zones": [        {          "upstream_path": "/path4",          "location": "/path3",          "upstream_id": "name683"        }      ],      "real_ip_header": {        "name": "forwarded_for",        "networks": [          "127.0.0.1/16",          "192.168.0.1/32"        ]      },      "ssl_certificate_id": "zPdy8WbQ"    }  ],  "upstream_zones": [    {      "method": "random.least_conn",      "hc_interval": 5,      "hc_jitter": 5,      "hc_fails": 1,      "hc_passes": 3,      "grpc": false,      "sticky": true,      "ssl": false,      "hc_path": "/",      "hc_method": "GET",      "id": "name683",      "hc_domain": "127.0.5.1",      "upstreams": [        {          "ip": "10.0.8.4",          "port": 345,          "weight": 1,          "max_conns": 63000,          "max_fails": 0,          "fail_timeout": 30,          "status": "unknown"        }      ]    }  ],  "labels": {    "environment": "production",    "service": "my-web-app",    "example.com/project": "my-project",    "example.com/owner": "my-team"  },  "cluster_id": null,  "shared_cluster": true,  "created_at": "2026-05-28T06:59:48Z",  "updated_at": "2026-05-28T06:59:49Z"}
{  "message": "Validation failed",  "code": "UNPROCESSABLE_ENTITY",  "errors": {    "name": "is missing",    "location_id": "is missing",    "vhost_zones": "is missing",    "upstream_zones": "is missing"  }}