# Network › Load Balancer › Service references API

> Part of the OVHcloud developer hub. Index of every page and section: https://developers.eu.ovhcloud.com/llms.txt
> The Network product's sections: https://developers.eu.ovhcloud.com/reference/network/llms.txt
> Everything in one file: https://developers.eu.ovhcloud.com/llms-full.txt

> 5 operations of the OVHcloud API. Calls carry `authorization: Bearer $OVH_TOKEN`; the EU host is shown, Canada and the United States answer on api.ca.ovhcloud.com and api.us.ovhcloud.com.

Page: https://developers.eu.ovhcloud.com/reference/network/load-balancer/service-references/

OpenAPI v1: https://api.eu.ovhcloud.com/1.0/__schemas/developer-hub-navigation/network/load-balancer/service-references.json?format=openapi3
OpenAPI v2: https://api.eu.ovhcloud.com/v2/__schemas/developer-hub-navigation/network/load-balancer/service-references.json?format=openapi3

## Operations

- `GET /ipLoadbalancing/{serviceName}/availableFrontendType` — List available frontend types
- `GET /ipLoadbalancing/{serviceName}/availableFarmType` — List available farm types
- `GET /ipLoadbalancing/{serviceName}/availableFarmProbes` — List available farm probes
- `GET /ipLoadbalancing/{serviceName}/availableRouteRules` — List available route match rules
- `GET /ipLoadbalancing/{serviceName}/availableRouteActions` — List available route actions

## List available frontend types

`GET /1.0/ipLoadbalancing/{serviceName}/availableFrontendType`

Link: https://developers.eu.ovhcloud.com/reference/network/load-balancer/service-references/#get-iploadbalancing-servicename-availablefrontendtype

**Status:** Stable production version  
**IAM actions:** `loadbalancer:apiovh:availableFrontendType/get`

### Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `serviceName` | path | string | yes | The internal name of your IP load balancing |

### Responses

| Status | Type | Description |
| --- | --- | --- |
| 200 | string[] | successful operation |

```json
[
  "string"
]
```

### Example

```bash
curl -X GET \
  "https://api.eu.ovhcloud.com/1.0/ipLoadbalancing/{serviceName}/availableFrontendType" \
  -H "accept: application/json" \
  -H "authorization: Bearer $OVH_TOKEN"
```

```python
'''
First, install the latest release of Python wrapper: $ pip install ovh
'''
import json
import ovh

# Instantiate an OVH Client.
# You can generate new credentials with full access to your account on
# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)
client = ovh.Client(
	endpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)
	application_key='xxxxxxxxxx',    # Application Key
	application_secret='xxxxxxxxxx', # Application Secret
	consumer_key='xxxxxxxxxx',       # Consumer Key
)

result = client.get("/ipLoadbalancing/{serviceName}/availableFrontendType")

# Pretty print
print(json.dumps(result, indent=4))
```

```php
<?php
/**
 * First, download the latest release of PHP wrapper on github
 * And include this script into the folder with extracted files
 */
require __DIR__ . '/vendor/autoload.php';
use \Ovh\Api;

/**
 * Instantiate an OVH Client.
 * You can generate new credentials with full access to your account on
 * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)
 */
$ovh = new Api('xxxxxxxxxx',  // Application Key
               'xxxxxxxxxx',  // Application Secret
               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)
               'xxxxxxxxxx'); // Consumer Key

$result = $ovh->get("/ipLoadbalancing/{serviceName}/availableFrontendType");

print_r($result);
?>
```

## List available farm types

`GET /1.0/ipLoadbalancing/{serviceName}/availableFarmType`

Link: https://developers.eu.ovhcloud.com/reference/network/load-balancer/service-references/#get-iploadbalancing-servicename-availablefarmtype

**Status:** Stable production version  
**IAM actions:** `loadbalancer:apiovh:availableFarmType/get`

### Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `serviceName` | path | string | yes | The internal name of your IP load balancing |

### Responses

| Status | Type | Description |
| --- | --- | --- |
| 200 | string[] | successful operation |

```json
[
  "string"
]
```

### Example

```bash
curl -X GET \
  "https://api.eu.ovhcloud.com/1.0/ipLoadbalancing/{serviceName}/availableFarmType" \
  -H "accept: application/json" \
  -H "authorization: Bearer $OVH_TOKEN"
```

```python
'''
First, install the latest release of Python wrapper: $ pip install ovh
'''
import json
import ovh

# Instantiate an OVH Client.
# You can generate new credentials with full access to your account on
# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)
client = ovh.Client(
	endpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)
	application_key='xxxxxxxxxx',    # Application Key
	application_secret='xxxxxxxxxx', # Application Secret
	consumer_key='xxxxxxxxxx',       # Consumer Key
)

result = client.get("/ipLoadbalancing/{serviceName}/availableFarmType")

# Pretty print
print(json.dumps(result, indent=4))
```

```php
<?php
/**
 * First, download the latest release of PHP wrapper on github
 * And include this script into the folder with extracted files
 */
require __DIR__ . '/vendor/autoload.php';
use \Ovh\Api;

/**
 * Instantiate an OVH Client.
 * You can generate new credentials with full access to your account on
 * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)
 */
$ovh = new Api('xxxxxxxxxx',  // Application Key
               'xxxxxxxxxx',  // Application Secret
               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)
               'xxxxxxxxxx'); // Consumer Key

$result = $ovh->get("/ipLoadbalancing/{serviceName}/availableFarmType");

print_r($result);
?>
```

## List available farm probes

`GET /1.0/ipLoadbalancing/{serviceName}/availableFarmProbes`

Link: https://developers.eu.ovhcloud.com/reference/network/load-balancer/service-references/#get-iploadbalancing-servicename-availablefarmprobes

**Status:** Stable production version  
**IAM actions:** `loadbalancer:apiovh:availableFarmProbes/get`

### Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `serviceName` | path | string | yes | The internal name of your IP load balancing |

### Responses

| Status | Type | Description |
| --- | --- | --- |
| 200 | ipLoadbalancing.FarmAvailableProbe[] | successful operation |

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `matches` | string[] |  | List of possible probe result checkers for this type of probe |
| `method` | string[] |  | List of available HTTP method, if available |
| `negatableMatches` | string[] |  | List of matches operators that accept the negate option for this type of probe |
| `port` | boolean |  | True is this probe type supports a custom port |
| `type` | string |  | Probe protocol name. See probe "type" field in the farm probe |
| `url` | boolean |  | True is this probe type supports a URL |

```json
[
  {
    "matches": [
      "string"
    ],
    "method": [
      "string"
    ],
    "negatableMatches": [
      "string"
    ],
    "port": true,
    "type": "string",
    "url": true
  }
]
```

### Example

```bash
curl -X GET \
  "https://api.eu.ovhcloud.com/1.0/ipLoadbalancing/{serviceName}/availableFarmProbes" \
  -H "accept: application/json" \
  -H "authorization: Bearer $OVH_TOKEN"
```

```python
'''
First, install the latest release of Python wrapper: $ pip install ovh
'''
import json
import ovh

# Instantiate an OVH Client.
# You can generate new credentials with full access to your account on
# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)
client = ovh.Client(
	endpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)
	application_key='xxxxxxxxxx',    # Application Key
	application_secret='xxxxxxxxxx', # Application Secret
	consumer_key='xxxxxxxxxx',       # Consumer Key
)

result = client.get("/ipLoadbalancing/{serviceName}/availableFarmProbes")

# Pretty print
print(json.dumps(result, indent=4))
```

```php
<?php
/**
 * First, download the latest release of PHP wrapper on github
 * And include this script into the folder with extracted files
 */
require __DIR__ . '/vendor/autoload.php';
use \Ovh\Api;

/**
 * Instantiate an OVH Client.
 * You can generate new credentials with full access to your account on
 * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)
 */
$ovh = new Api('xxxxxxxxxx',  // Application Key
               'xxxxxxxxxx',  // Application Secret
               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)
               'xxxxxxxxxx'); // Consumer Key

$result = $ovh->get("/ipLoadbalancing/{serviceName}/availableFarmProbes");

print_r($result);
?>
```

## List available route match rules

`GET /1.0/ipLoadbalancing/{serviceName}/availableRouteRules`

Link: https://developers.eu.ovhcloud.com/reference/network/load-balancer/service-references/#get-iploadbalancing-servicename-availablerouterules

**Status:** Stable production version  
**IAM actions:** `loadbalancer:apiovh:availableRouteRules/get`

### Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `serviceName` | path | string | yes | The internal name of your IP load balancing |

### Responses

| Status | Type | Description |
| --- | --- | --- |
| 200 | ipLoadbalancing.RouteAvailableRule[] | successful operation |

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `enum` | string[] |  | If pattern is "enum", list of available options |
| `hasSubField` | boolean |  | If true, this rule needs a subfield. Typically a cookie or header name |
| `matches` | string[] |  | List of match operators compatible with this rule |
| `name` | string |  | Rule name |
| `pattern` | string |  | Expected type for the pattern. Like "enum", "backend", "cidr", ... |
| `type` | string |  | Protocol supported by this action |

```json
[
  {
    "enum": [
      "string"
    ],
    "hasSubField": true,
    "matches": [
      "string"
    ],
    "name": "string",
    "pattern": "string",
    "type": "string"
  }
]
```

### Example

```bash
curl -X GET \
  "https://api.eu.ovhcloud.com/1.0/ipLoadbalancing/{serviceName}/availableRouteRules" \
  -H "accept: application/json" \
  -H "authorization: Bearer $OVH_TOKEN"
```

```python
'''
First, install the latest release of Python wrapper: $ pip install ovh
'''
import json
import ovh

# Instantiate an OVH Client.
# You can generate new credentials with full access to your account on
# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)
client = ovh.Client(
	endpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)
	application_key='xxxxxxxxxx',    # Application Key
	application_secret='xxxxxxxxxx', # Application Secret
	consumer_key='xxxxxxxxxx',       # Consumer Key
)

result = client.get("/ipLoadbalancing/{serviceName}/availableRouteRules")

# Pretty print
print(json.dumps(result, indent=4))
```

```php
<?php
/**
 * First, download the latest release of PHP wrapper on github
 * And include this script into the folder with extracted files
 */
require __DIR__ . '/vendor/autoload.php';
use \Ovh\Api;

/**
 * Instantiate an OVH Client.
 * You can generate new credentials with full access to your account on
 * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)
 */
$ovh = new Api('xxxxxxxxxx',  // Application Key
               'xxxxxxxxxx',  // Application Secret
               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)
               'xxxxxxxxxx'); // Consumer Key

$result = $ovh->get("/ipLoadbalancing/{serviceName}/availableRouteRules");

print_r($result);
?>
```

## List available route actions

`GET /1.0/ipLoadbalancing/{serviceName}/availableRouteActions`

Link: https://developers.eu.ovhcloud.com/reference/network/load-balancer/service-references/#get-iploadbalancing-servicename-availablerouteactions

**Status:** Stable production version  
**IAM actions:** `loadbalancer:apiovh:availableRouteActions/get`

### Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `serviceName` | path | string | yes | The internal name of your IP load balancing |

### Responses

| Status | Type | Description |
| --- | --- | --- |
| 200 | ipLoadbalancing.RouteAvailableAction[] | successful operation |

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `destination` | string |  | Type of the destination for this action |
| `name` | string |  | Action name |
| `status` | integer[] |  | List of available HTTP status code if applicable |
| `type` | string |  | Protocol supported by this action |

```json
[
  {
    "destination": "string",
    "name": "string",
    "status": [
      0
    ],
    "type": "string"
  }
]
```

### Example

```bash
curl -X GET \
  "https://api.eu.ovhcloud.com/1.0/ipLoadbalancing/{serviceName}/availableRouteActions" \
  -H "accept: application/json" \
  -H "authorization: Bearer $OVH_TOKEN"
```

```python
'''
First, install the latest release of Python wrapper: $ pip install ovh
'''
import json
import ovh

# Instantiate an OVH Client.
# You can generate new credentials with full access to your account on
# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)
client = ovh.Client(
	endpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)
	application_key='xxxxxxxxxx',    # Application Key
	application_secret='xxxxxxxxxx', # Application Secret
	consumer_key='xxxxxxxxxx',       # Consumer Key
)

result = client.get("/ipLoadbalancing/{serviceName}/availableRouteActions")

# Pretty print
print(json.dumps(result, indent=4))
```

```php
<?php
/**
 * First, download the latest release of PHP wrapper on github
 * And include this script into the folder with extracted files
 */
require __DIR__ . '/vendor/autoload.php';
use \Ovh\Api;

/**
 * Instantiate an OVH Client.
 * You can generate new credentials with full access to your account on
 * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)
 */
$ovh = new Api('xxxxxxxxxx',  // Application Key
               'xxxxxxxxxx',  // Application Secret
               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)
               'xxxxxxxxxx'); // Consumer Key

$result = $ovh->get("/ipLoadbalancing/{serviceName}/availableRouteActions");

print_r($result);
?>
```
