Endurance

Portal

Adopt this appliance into the Portal

Adopt Sidecar Refused while a transaction is open. Commit or roll back the transaction first.

PUT /portal/adopt

This change is staged. Send PUT /services/apply to apply it.

Body parameters
email string Required
password string Required
curl
curl -X PUT "https://appliance.example.com/api/v1/portal/adopt" \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "email": "<email>",
  "password": "<password>"
}'
PHP
<?php

$url = 'https://appliance.example.com/api/v1/portal/adopt';
$headers = [
    'Authorization: Bearer ' . $token,
    'Content-Type: application/json',
];

$payload = [
    'email' => '<email>',
    'password' => '<password>',
];

$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 = {
    "email": "<email>",
    "password": "<password>"
}

response = requests.put("https://appliance.example.com/api/v1/portal/adopt", headers=headers, json=payload)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/portal/adopt', {
  method: 'PUT',
  headers: {
    Authorization: `Bearer ${token}`,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
  "email": "<email>",
  "password": "<password>"
}),
});

const data = await response.json();
Bruno
meta {
  name: Adopt this appliance into the Portal
  type: http
  seq: 1
}

put {
  url: https://{{node-0}}:{{port}}/api/v1/portal/adopt
  body: json
  auth: bearer
}

headers {
  Content-Type: application/json
}

auth:bearer {
  token: {{token}}
}

body:json {
  {
    "email": "<email>",
    "password": "<password>"
  }
}
Response
{
  "status": "success",
  "message": "Update Sidecar successfully"
}

Remote

Remote Sidecar details

GET /portal/remote

curl
curl -X GET "https://appliance.example.com/api/v1/portal/remote" \
  -H "Authorization: Bearer $TOKEN"
PHP
<?php

$url = 'https://appliance.example.com/api/v1/portal/remote';
$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/portal/remote", headers=headers)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/portal/remote', {
  method: 'GET',
  headers: {
    Authorization: `Bearer ${token}`,
  },
});

const data = await response.json();
Bruno
meta {
  name: Get the remote Portal sidecar details
  type: http
  seq: 1
}

get {
  url: https://{{node-0}}:{{port}}/api/v1/portal/remote
  body: none
  auth: bearer
}

auth:bearer {
  token: {{token}}
}
Response
{
  "status": "success",
  "message": "Remote Sidecar Details",
  "data": {
    "managementIP": "10.10.10.10",
    "managementPort": 12000
  }
}

Update Remote Sidecar Refused while a transaction is open. Commit or roll back the transaction first.

PUT /portal/remote

This change is staged. Send PUT /services/apply to apply it.

Body parameters
managementIP string Required
managementPort string Required
curl
curl -X PUT "https://appliance.example.com/api/v1/portal/remote" \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "managementIP": "<managementIP>",
  "managementPort": "<managementPort>"
}'
PHP
<?php

$url = 'https://appliance.example.com/api/v1/portal/remote';
$headers = [
    'Authorization: Bearer ' . $token,
    'Content-Type: application/json',
];

$payload = [
    'managementIP' => '<managementIP>',
    'managementPort' => '<managementPort>',
];

$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 = {
    "managementIP": "<managementIP>",
    "managementPort": "<managementPort>"
}

response = requests.put("https://appliance.example.com/api/v1/portal/remote", headers=headers, json=payload)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/portal/remote', {
  method: 'PUT',
  headers: {
    Authorization: `Bearer ${token}`,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
  "managementIP": "<managementIP>",
  "managementPort": "<managementPort>"
}),
});

const data = await response.json();
Bruno
meta {
  name: Update the remote Portal sidecar details
  type: http
  seq: 1
}

put {
  url: https://{{node-0}}:{{port}}/api/v1/portal/remote
  body: json
  auth: bearer
}

headers {
  Content-Type: application/json
}

auth:bearer {
  token: {{token}}
}

body:json {
  {
    "managementIP": "<managementIP>",
    "managementPort": "<managementPort>"
  }
}
Response
{
  "status": "success",
  "message": "Remote Sidecar updated successfully"
}

Get the Portal connection status

Status

GET /portal/status

curl
curl -X GET "https://appliance.example.com/api/v1/portal/status" \
  -H "Authorization: Bearer $TOKEN"
PHP
<?php

$url = 'https://appliance.example.com/api/v1/portal/status';
$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/portal/status", headers=headers)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/portal/status', {
  method: 'GET',
  headers: {
    Authorization: `Bearer ${token}`,
  },
});

const data = await response.json();
Bruno
meta {
  name: Get the Portal connection status
  type: http
  seq: 1
}

get {
  url: https://{{node-0}}:{{port}}/api/v1/portal/status
  body: none
  auth: bearer
}

auth:bearer {
  token: {{token}}
}
Response
{
  "status": "success",
  "message": "Sidecar Details",
  "data": {
    "adopted": false
  }
}

Sidecar

Get Sidecar

GET /{applianceId}/portal/sidecar

Path parameters
applianceId string Required

The id of the cluster node the request is for.

curl
curl -X GET "https://appliance.example.com/api/v1/{applianceId}/portal/sidecar" \
  -H "Authorization: Bearer $TOKEN"
PHP
<?php

$url = 'https://appliance.example.com/api/v1/{applianceId}/portal/sidecar';
$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/{applianceId}/portal/sidecar", headers=headers)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/{applianceId}/portal/sidecar', {
  method: 'GET',
  headers: {
    Authorization: `Bearer ${token}`,
  },
});

const data = await response.json();
Bruno
meta {
  name: Get the Portal sidecar details
  type: http
  seq: 1
}

get {
  url: https://{{node-0}}:{{port}}/api/v1/{applianceId}/portal/sidecar
  body: none
  auth: bearer
}

auth:bearer {
  token: {{token}}
}
Response
{
  "status": "success",
  "message": "Sidecar Details",
  "data": []
}

Update Sidecar Refused while a transaction is open. Commit or roll back the transaction first.

PUT /{applianceId}/portal/sidecar

This change is staged. Send PUT /services/apply to apply it.

Path parameters
applianceId string Required

The id of the cluster node the request is for.

Body parameters
enabled boolean Required
portalAddress string Required
portalPort integer Required
managementIPId string Required
managementPort integer Required
subnetIds array Required
curl
curl -X PUT "https://appliance.example.com/api/v1/{applianceId}/portal/sidecar" \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "enabled": true,
  "portalAddress": "<portalAddress>",
  "portalPort": 0,
  "managementIPId": "<managementIPId>",
  "managementPort": 0,
  "subnetIds": [
    "<subnetIds>"
  ]
}'
PHP
<?php

$url = 'https://appliance.example.com/api/v1/{applianceId}/portal/sidecar';
$headers = [
    'Authorization: Bearer ' . $token,
    'Content-Type: application/json',
];

$payload = [
    'enabled' => true,
    'portalAddress' => '<portalAddress>',
    'portalPort' => 0,
    'managementIPId' => '<managementIPId>',
    'managementPort' => 0,
    'subnetIds' => [
        '<subnetIds>',
    ],
];

$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 = {
    "enabled": true,
    "portalAddress": "<portalAddress>",
    "portalPort": 0,
    "managementIPId": "<managementIPId>",
    "managementPort": 0,
    "subnetIds": [
        "<subnetIds>"
    ]
}

response = requests.put("https://appliance.example.com/api/v1/{applianceId}/portal/sidecar", headers=headers, json=payload)
response.raise_for_status()
print(response.json())
JavaScript
const response = await fetch('https://appliance.example.com/api/v1/{applianceId}/portal/sidecar', {
  method: 'PUT',
  headers: {
    Authorization: `Bearer ${token}`,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
  "enabled": true,
  "portalAddress": "<portalAddress>",
  "portalPort": 0,
  "managementIPId": "<managementIPId>",
  "managementPort": 0,
  "subnetIds": [
    "<subnetIds>"
  ]
}),
});

const data = await response.json();
Bruno
meta {
  name: Update the Portal sidecar details
  type: http
  seq: 1
}

put {
  url: https://{{node-0}}:{{port}}/api/v1/{applianceId}/portal/sidecar
  body: json
  auth: bearer
}

headers {
  Content-Type: application/json
}

auth:bearer {
  token: {{token}}
}

body:json {
  {
    "enabled": true,
    "portalAddress": "<portalAddress>",
    "portalPort": 0,
    "managementIPId": "<managementIPId>",
    "managementPort": 0,
    "subnetIds": [
      "<subnetIds>"
    ]
  }
}
Response
{
  "status": "success",
  "message": "Sidecar updated successfully"
}