Scaleway logo
Load Balancer API

The Load Balancer route object. It represents a configuration on a particular frontend to direct traffic to a particular backend if certain conditions are fulfilled. Conditions must be based on SNI for direction to TCP backends, or HTTP host headers for direction to HTTP backends. Use the routes endpoint to create, edit, list, get and delete your routes.


List all routes

GET
https://api.scaleway.com
/lb/v1/zones/{zone}/routes

List all routes for a given frontend. The response is an array of routes, each one with a specified backend to direct to if a certain condition is matched (based on the value of the SNI field or HTTP Host header).

List all routes › path Parameters

zone
​string · enum · required

The zone you want to target

Enum values:
fr-par-1
fr-par-2
nl-ams-1
nl-ams-2
nl-ams-3
pl-waw-1
pl-waw-2
pl-waw-3

List all routes › query Parameters

order_by
​scaleway.lb.v1.ListRoutesRequest.OrderBy · enum

Sort order of routes in the response.

Enum values:
created_at_asc
created_at_desc
Default: created_at_asc
page_size
​integer · uint32

The number of route objects to return.

page
​integer · int32

The page number to return, from the paginated results.

frontend_id
​string

Frontend ID to filter for, only Routes from this Frontend will be returned.

List all routes › Responses

200

List of route objects.

total_count
​integer · uint32

The total number of route objects.


Create a route

POST
https://api.scaleway.com
/lb/v1/zones/{zone}/routes

Create a new route on a given frontend. To configure a route, specify the backend to direct to if a certain condition is matched (based on the value of the SNI field or HTTP Host header).

Create a route › path Parameters

zone
​string · enum · required

The zone you want to target

Enum values:
fr-par-1
fr-par-2
nl-ams-1
nl-ams-2
nl-ams-3
pl-waw-1
pl-waw-2
pl-waw-3

Create a route › Request Body

frontend_id
​string

ID of the source frontend to create the route on.

backend_id
​string

ID of the target backend for the route.

Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend.

Create a route › Responses

200
id
​string

Route ID.

frontend_id
​string

ID of the source frontend.

backend_id
​string

ID of the target backend.

Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend.

created_at
​string | null · date-time

Date on which the route was created. (RFC 3339 format)

updated_at
​string | null · date-time

Date on which the route was last updated. (RFC 3339 format)


Get a route

GET
https://api.scaleway.com
/lb/v1/zones/{zone}/routes/{route_id}

Retrieve information about an existing route, specified by its route ID. Its full details, origin frontend, target backend and match condition, are returned in the response object.

Get a route › path Parameters

zone
​string · enum · required

The zone you want to target

Enum values:
fr-par-1
fr-par-2
nl-ams-1
nl-ams-2
nl-ams-3
pl-waw-1
pl-waw-2
pl-waw-3
route_id
​string · required

Route ID.

Get a route › Responses

200
id
​string

Route ID.

frontend_id
​string

ID of the source frontend.

backend_id
​string

ID of the target backend.

Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend.

created_at
​string | null · date-time

Date on which the route was created. (RFC 3339 format)

updated_at
​string | null · date-time

Date on which the route was last updated. (RFC 3339 format)


Update a route

PUT
https://api.scaleway.com
/lb/v1/zones/{zone}/routes/{route_id}

Update the configuration of an existing route, specified by its route ID.

Update a route › path Parameters

zone
​string · enum · required

The zone you want to target

Enum values:
fr-par-1
fr-par-2
nl-ams-1
nl-ams-2
nl-ams-3
pl-waw-1
pl-waw-2
pl-waw-3
route_id
​string · required

Route ID.

Update a route › Request Body

backend_id
​string

ID of the target backend for the route.

Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend.

Update a route › Responses

200
id
​string

Route ID.

frontend_id
​string

ID of the source frontend.

backend_id
​string

ID of the target backend.

Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend.

created_at
​string | null · date-time

Date on which the route was created. (RFC 3339 format)

updated_at
​string | null · date-time

Date on which the route was last updated. (RFC 3339 format)


Delete a route

DELETE
https://api.scaleway.com
/lb/v1/zones/{zone}/routes/{route_id}

Delete an existing route, specified by its route ID. Deleting a route is permanent, and cannot be undone.

Delete a route › path Parameters

zone
​string · enum · required

The zone you want to target

Enum values:
fr-par-1
fr-par-2
nl-ams-1
nl-ams-2
nl-ams-3
pl-waw-1
pl-waw-2
pl-waw-3
route_id
​string · required

Route ID.

Delete a route › Responses

No data returned