Frontends
A frontend is the address and port a Virtual Service listens on — what clients connect to — and the rules that decide which backend serves a request.
Frontends
curl
curl -X GET "https://appliance.example.com/api/v1/ipvsDirector/frontends" \
-H "Authorization: Bearer $TOKEN"
PHP
<?php
$url = 'https://appliance.example.com/api/v1/ipvsDirector/frontends';
$headers = [
'Authorization: Bearer ' . $token,
];
$ch = curl_init($url);
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_HTTPHEADER => $headers,
CURLOPT_RETURNTRANSFER => true,
]);
$response = json_decode(curl_exec($ch), true);
curl_close($ch);
Python
import requests
headers = {"Authorization": f"Bearer {token}"}
response = requests.get("https://appliance.example.com/api/v1/ipvsDirector/frontends", headers=headers)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/ipvsDirector/frontends', {
method: 'GET',
headers: {
Authorization: `Bearer ${token}`,
},
});
const data = await response.json();
Response
{
"status": "success",
"message": "Frontends retrieved successfully",
"data": [
{
"id": "50c-d3f-7f2-f3e",
"name": "Test FE",
"ports": [
80
],
"aclIds": [
"111-111-111-111"
],
"fipId": "de0-27c-3f8-15d",
"mode": "tcp"
}
]
}
curl
curl -X POST "https://appliance.example.com/api/v1/ipvsDirector/frontends" \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "<name>",
"ports": [
"<ports>"
],
"mode": "udp",
"fipId": "<fipId>",
"aclIds": "["
}'
PHP
<?php
$url = 'https://appliance.example.com/api/v1/ipvsDirector/frontends';
$headers = [
'Authorization: Bearer ' . $token,
'Content-Type: application/json',
];
$payload = [
'name' => '<name>',
'ports' => [
'<ports>',
],
'mode' => 'udp',
'fipId' => '<fipId>',
'aclIds' => '[',
];
$ch = curl_init($url);
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_HTTPHEADER => $headers,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POSTFIELDS => json_encode($payload),
]);
$response = json_decode(curl_exec($ch), true);
curl_close($ch);
Python
import requests
headers = {"Authorization": f"Bearer {token}"}
payload = {
"name": "<name>",
"ports": [
"<ports>"
],
"mode": "udp",
"fipId": "<fipId>",
"aclIds": "["
}
response = requests.post("https://appliance.example.com/api/v1/ipvsDirector/frontends", headers=headers, json=payload)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/ipvsDirector/frontends', {
method: 'POST',
headers: {
Authorization: `Bearer ${token}`,
'Content-Type': 'application/json',
},
body: JSON.stringify({
"name": "<name>",
"ports": [
"<ports>"
],
"mode": "udp",
"fipId": "<fipId>",
"aclIds": "["
}),
});
const data = await response.json();
Response
{
"status": "success",
"message": "Frontend added successfully",
"data": {
"id": "5cf-0e9-6fa-3f5"
}
}
By ID
curl
curl -X GET "https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}" \
-H "Authorization: Bearer $TOKEN"
PHP
<?php
$url = 'https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}';
$headers = [
'Authorization: Bearer ' . $token,
];
$ch = curl_init($url);
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_HTTPHEADER => $headers,
CURLOPT_RETURNTRANSFER => true,
]);
$response = json_decode(curl_exec($ch), true);
curl_close($ch);
Python
import requests
headers = {"Authorization": f"Bearer {token}"}
response = requests.get("https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}", headers=headers)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}', {
method: 'GET',
headers: {
Authorization: `Bearer ${token}`,
},
});
const data = await response.json();
Response
{
"status": "success",
"message": "Frontends retrieved successfully",
"data": {
"id": "50c-d3f-7f2-f3e",
"name": "Test FE",
"ports": [
80
],
"aclIds": [
"111-111-111-111"
],
"fipId": "de0-27c-3f8-15d",
"mode": "tcp"
}
}
curl
curl -X PUT "https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}" \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "<name>",
"ports": [
"<ports>"
],
"mode": "udp",
"fipId": "<fipId>",
"aclIds": [
"<aclIds>"
]
}'
PHP
<?php
$url = 'https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}';
$headers = [
'Authorization: Bearer ' . $token,
'Content-Type: application/json',
];
$payload = [
'name' => '<name>',
'ports' => [
'<ports>',
],
'mode' => 'udp',
'fipId' => '<fipId>',
'aclIds' => [
'<aclIds>',
],
];
$ch = curl_init($url);
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'PUT',
CURLOPT_HTTPHEADER => $headers,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POSTFIELDS => json_encode($payload),
]);
$response = json_decode(curl_exec($ch), true);
curl_close($ch);
Python
import requests
headers = {"Authorization": f"Bearer {token}"}
payload = {
"name": "<name>",
"ports": [
"<ports>"
],
"mode": "udp",
"fipId": "<fipId>",
"aclIds": [
"<aclIds>"
]
}
response = requests.put("https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}", headers=headers, json=payload)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}', {
method: 'PUT',
headers: {
Authorization: `Bearer ${token}`,
'Content-Type': 'application/json',
},
body: JSON.stringify({
"name": "<name>",
"ports": [
"<ports>"
],
"mode": "udp",
"fipId": "<fipId>",
"aclIds": [
"<aclIds>"
]
}),
});
const data = await response.json();
Response
{
"status": "success",
"message": "Frontend updated successfully",
"data": []
}
curl
curl -X DELETE "https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}" \
-H "Authorization: Bearer $TOKEN"
PHP
<?php
$url = 'https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}';
$headers = [
'Authorization: Bearer ' . $token,
];
$ch = curl_init($url);
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'DELETE',
CURLOPT_HTTPHEADER => $headers,
CURLOPT_RETURNTRANSFER => true,
]);
$response = json_decode(curl_exec($ch), true);
curl_close($ch);
Python
import requests
headers = {"Authorization": f"Bearer {token}"}
response = requests.delete("https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}", headers=headers)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}', {
method: 'DELETE',
headers: {
Authorization: `Bearer ${token}`,
},
});
const data = await response.json();
Response
{
"status": "success",
"message": "Frontend deleted successfully",
"data": []
}
List the ACLs of a Layer 4 frontend
curl
curl -X GET "https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/acls" \
-H "Authorization: Bearer $TOKEN"
PHP
<?php
$url = 'https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/acls';
$headers = [
'Authorization: Bearer ' . $token,
];
$ch = curl_init($url);
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_HTTPHEADER => $headers,
CURLOPT_RETURNTRANSFER => true,
]);
$response = json_decode(curl_exec($ch), true);
curl_close($ch);
Python
import requests
headers = {"Authorization": f"Bearer {token}"}
response = requests.get("https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/acls", headers=headers)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/acls', {
method: 'GET',
headers: {
Authorization: `Bearer ${token}`,
},
});
const data = await response.json();
Response
{
"status": "success",
"message": "ACLs retrieved successfully",
"data": {
"111-111-111-111": {
"conditionType": "default",
"condition": "eq",
"redirectType": "backend",
"redirectLocation": "333-333-333-333"
}
}
}
Delete a Layer 4 frontend and everything attached to it
curl
curl -X DELETE "https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/all" \
-H "Authorization: Bearer $TOKEN"
PHP
<?php
$url = 'https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/all';
$headers = [
'Authorization: Bearer ' . $token,
];
$ch = curl_init($url);
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'DELETE',
CURLOPT_HTTPHEADER => $headers,
CURLOPT_RETURNTRANSFER => true,
]);
$response = json_decode(curl_exec($ch), true);
curl_close($ch);
Python
import requests
headers = {"Authorization": f"Bearer {token}"}
response = requests.delete("https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/all", headers=headers)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/all', {
method: 'DELETE',
headers: {
Authorization: `Bearer ${token}`,
},
});
const data = await response.json();
Response
{
"status": "success",
"message": "Frontend and all unused, associated items deleted successfully",
"data": []
}
List the backends of a Layer 4 frontend
curl
curl -X GET "https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/backends" \
-H "Authorization: Bearer $TOKEN"
PHP
<?php
$url = 'https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/backends';
$headers = [
'Authorization: Bearer ' . $token,
];
$ch = curl_init($url);
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_HTTPHEADER => $headers,
CURLOPT_RETURNTRANSFER => true,
]);
$response = json_decode(curl_exec($ch), true);
curl_close($ch);
Python
import requests
headers = {"Authorization": f"Bearer {token}"}
response = requests.get("https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/backends", headers=headers)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/backends', {
method: 'GET',
headers: {
Authorization: `Bearer ${token}`,
},
});
const data = await response.json();
Response
{
"status": "success",
"message": "Backends retrieved successfully",
"data": {
"5f7-1e1-af5-6b0": {
"name": "testingbackend",
"ripIds": [
"5ce-788-600-844"
],
"balanceMode": "leastConnections",
"forwardingMode": "sourceNat",
"persistenceEnabled": true,
"persistenceTimeout": "15m",
"healthCheckId": "3f2-9ab-41c-05d",
"fallbackServerId": "",
"fallbackServerForwardingMode": "destinationNat"
}
}
}
Drain a Layer 4 frontend
curl
curl -X PUT "https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/drain" \
-H "Authorization: Bearer $TOKEN"
PHP
<?php
$url = 'https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/drain';
$headers = [
'Authorization: Bearer ' . $token,
];
$ch = curl_init($url);
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'PUT',
CURLOPT_HTTPHEADER => $headers,
CURLOPT_RETURNTRANSFER => true,
]);
$response = json_decode(curl_exec($ch), true);
curl_close($ch);
Python
import requests
headers = {"Authorization": f"Bearer {token}"}
response = requests.put("https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/drain", headers=headers)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/drain', {
method: 'PUT',
headers: {
Authorization: `Bearer ${token}`,
},
});
const data = await response.json();
Response
{
"status": "success",
"message": "Drained all Real Servers in Frontend",
"data": []
}
Halt a Layer 4 frontend
curl
curl -X PUT "https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/halt" \
-H "Authorization: Bearer $TOKEN"
PHP
<?php
$url = 'https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/halt';
$headers = [
'Authorization: Bearer ' . $token,
];
$ch = curl_init($url);
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'PUT',
CURLOPT_HTTPHEADER => $headers,
CURLOPT_RETURNTRANSFER => true,
]);
$response = json_decode(curl_exec($ch), true);
curl_close($ch);
Python
import requests
headers = {"Authorization": f"Bearer {token}"}
response = requests.put("https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/halt", headers=headers)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/halt', {
method: 'PUT',
headers: {
Authorization: `Bearer ${token}`,
},
});
const data = await response.json();
Response
{
"status": "success",
"message": "Halted all real servers in the frontend",
"data": []
}
Bring a Layer 4 frontend online
curl
curl -X PUT "https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/online" \
-H "Authorization: Bearer $TOKEN"
PHP
<?php
$url = 'https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/online';
$headers = [
'Authorization: Bearer ' . $token,
];
$ch = curl_init($url);
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'PUT',
CURLOPT_HTTPHEADER => $headers,
CURLOPT_RETURNTRANSFER => true,
]);
$response = json_decode(curl_exec($ch), true);
curl_close($ch);
Python
import requests
headers = {"Authorization": f"Bearer {token}"}
response = requests.put("https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/online", headers=headers)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/ipvsDirector/frontends/{id}/online', {
method: 'PUT',
headers: {
Authorization: `Bearer ${token}`,
},
});
const data = await response.json();
Response
{
"status": "success",
"message": "Enabled all Real Servers in Frontend"
}