NodeBalancers

Node View

get
https://api.linode.com/v4/nodebalancers/{nodeBalancerId}/configs/{configId}/nodes/{nodeId}

Returns information about a single Node, a backend for this NodeBalancer's configured port.

Path Parameters

nodeBalancerId
Required
integer

The ID of the NodeBalancer to access.

configId
Required
integer

The ID of the Config to access

nodeId
Required
integer

The ID of the Node to access

Request Samples

curl -H "Authorization: Bearer $TOKEN" \
    https://api.linode.com/v4/nodebalancers/12345/configs/4567/nodes/54321

Response Samples

{
  "status": "UP",
  "id": 1234,
  "label": "node54321",
  "weight": 50,
  "address": "192.168.210.120:80",
  "nodebalancer_id": 12345,
  "mode": "accept",
  "config_id": 4567
}

Responses

200: A paginated list of NodeBalancer nodes.

status
string
Enum: "unknown""UP""DOWN"

The current status of this node, based on the configured checks of its NodeBalancer Config.

id
integer

This node's unique ID.

label
string [3 .. 32] characters [a-zA-Z0-9-_.]{3,32}

The label for this node. This is for display purposes only.

weight
integer

Used when picking a backend to serve a request and is not pinned to a single backend yet. Nodes with a higher weight will receive more traffic.

address
string <ip>

The private IP Address where this backend can be reached. This must be a private IP address.

nodebalancer_id
integer

The NodeBalancer ID that this Node belongs to.

mode
string
Enum: "accept""reject""drain""backup"

The mode this NodeBalancer should use when sending traffic to this backend.

  • If set to accept this backend is accepting traffic.
  • If set to reject this backend will not receive traffic.
  • If set to drain this backend will not receive new traffic, but connections already pinned to it will continue to be routed to it.

  • If set to backup, this backend will only receive traffic if all accept nodes are down.

config_id
integer

The NodeBalancer Config ID that this Node belongs to.

default: Error

errors
array of objects
reason
string

What happened to cause this error. In most cases, this can be fixed immediately by changing the data you sent in the request, but in some cases you will be instructed to open a Support Ticket or perform some other action before you can complete the request successfully.

field
string

The field in the request that caused this error. This may be a path, separated by periods in the case of nested fields. In some cases this may come back as "null" if the error is not specific to any single element of the request.

Node Update

put
https://api.linode.com/v4/nodebalancers/{nodeBalancerId}/configs/{configId}/nodes/{nodeId}

Updates information about a Node, a backend for this NodeBalancer's configured port.

Path Parameters

nodeBalancerId
Required
integer

The ID of the NodeBalancer to access.

configId
Required
integer

The ID of the Config to access

nodeId
Required
integer

The ID of the Node to access

Request Body Schema

address
string <ip>

The private IP Address where this backend can be reached. This must be a private IP address.

label
string [3 .. 32] characters [a-zA-Z0-9-_.]{3,32}

The label for this node. This is for display purposes only.

mode
string
Enum: "accept""reject""drain""backup"

The mode this NodeBalancer should use when sending traffic to this backend.

  • If set to accept this backend is accepting traffic.
  • If set to reject this backend will not receive traffic.
  • If set to drain this backend will not receive new traffic, but connections already pinned to it will continue to be routed to it.

  • If set to backup, this backend will only receive traffic if all accept nodes are down.

weight
integer

Used when picking a backend to serve a request and is not pinned to a single backend yet. Nodes with a higher weight will receive more traffic.

Request Samples

curl -H "Content-Type: application/json" \
    -H "Authorization: Bearer $TOKEN" \
    -X PUT -d '{
      "address": "192.168.210.120:80",
      "label": "node54321",
      "weight": 50,
      "mode": "accept"
    }' \
    https://api.linode.com/v4/nodebalancers/12345/configs/4567/nodes/54321

Response Samples

{
  "id": 1234,
  "label": "node54321",
  "status": "UP",
  "weight": 50,
  "address": "192.168.210.120:80",
  "nodebalancer_id": 12345,
  "mode": "accept",
  "config_id": 4567
}

Responses

200: Node updated successfully.

id
integer

This node's unique ID.

label
string [3 .. 32] characters [a-zA-Z0-9-_.]{3,32}

The label for this node. This is for display purposes only.

status
string
Enum: "unknown""UP""DOWN"

The current status of this node, based on the configured checks of its NodeBalancer Config.

weight
integer

Used when picking a backend to serve a request and is not pinned to a single backend yet. Nodes with a higher weight will receive more traffic.

address
string <ip>

The private IP Address where this backend can be reached. This must be a private IP address.

nodebalancer_id
integer

The NodeBalancer ID that this Node belongs to.

mode
string
Enum: "accept""reject""drain""backup"

The mode this NodeBalancer should use when sending traffic to this backend.

  • If set to accept this backend is accepting traffic.
  • If set to reject this backend will not receive traffic.
  • If set to drain this backend will not receive new traffic, but connections already pinned to it will continue to be routed to it.

  • If set to backup, this backend will only receive traffic if all accept nodes are down.

config_id
integer

The NodeBalancer Config ID that this Node belongs to.

default: Error

errors
array of objects
reason
string

What happened to cause this error. In most cases, this can be fixed immediately by changing the data you sent in the request, but in some cases you will be instructed to open a Support Ticket or perform some other action before you can complete the request successfully.

field
string

The field in the request that caused this error. This may be a path, separated by periods in the case of nested fields. In some cases this may come back as "null" if the error is not specific to any single element of the request.

Node Delete

delete
https://api.linode.com/v4/nodebalancers/{nodeBalancerId}/configs/{configId}/nodes/{nodeId}

Deletes a Node from this Config. This backend will no longer receive traffic for the configured port of this NodeBalancer.

This does not change or remove the Linode whose address was used in the creation of this Node.

Path Parameters

nodeBalancerId
Required
integer

The ID of the NodeBalancer to access.

configId
Required
integer

The ID of the Config to access

nodeId
Required
integer

The ID of the Node to access

Request Samples

curl -H "Authorization: Bearer $TOKEN" \
    -X DELETE \
    https://api.linode.com/v4/nodebalancers/12345/configs/4567/nodes/54321

Response Samples

{}

Responses

200: Node deleted successfully.

default: Error

errors
array of objects
reason
string

What happened to cause this error. In most cases, this can be fixed immediately by changing the data you sent in the request, but in some cases you will be instructed to open a Support Ticket or perform some other action before you can complete the request successfully.

field
string

The field in the request that caused this error. This may be a path, separated by periods in the case of nested fields. In some cases this may come back as "null" if the error is not specific to any single element of the request.