Download OpenAPI specification:Download
API documentation for GreenNode Global Load Balancer (GLB)
Get all global listeners
| glbid required | string glbid |
const request = require('request'); const options = { method: 'GET', url: 'https://glb.api.vngcloud.vn/glb-controller/v1/global-load-balancers/%7Bglbid%7D/global-listeners', headers: {Authorization: 'REPLACE_KEY_VALUE'} }; request(options, function (error, response, body) { if (error) throw new Error(error); console.log(body); });
Create a global listener
| glbid required | string Global Load Balancer ID |
| allowedCidrs required | string |
| description | string |
| globalPoolId | string |
| headers | string |
| name required | string |
| port required | integer |
| protocol required | string |
| timeoutClient required | integer |
| timeoutConnection required | integer |
| timeoutMember required | integer |
{- "allowedCidrs": "string",
- "description": "string",
- "globalPoolId": "string",
- "headers": "string",
- "name": "string",
- "port": 0,
- "protocol": "string",
- "timeoutClient": 0,
- "timeoutConnection": 0,
- "timeoutMember": 0
}Get a global listener
| glbid required | string glbid |
| listenerid required | string listenerid |
const request = require('request'); const options = { method: 'GET', url: 'https://glb.api.vngcloud.vn/glb-controller/v1/global-load-balancers/%7Bglbid%7D/global-listeners/%7Blistenerid%7D', headers: {Authorization: 'REPLACE_KEY_VALUE'} }; request(options, function (error, response, body) { if (error) throw new Error(error); console.log(body); });
Update a global listener
| glbid required | string glbid |
| listenerid required | string listenerid |
| allowedCidrs required | string |
| globalPoolId required | string |
| headers | string |
| timeoutClient required | integer |
| timeoutConnection required | integer |
| timeoutMember required | integer |
{- "allowedCidrs": "string",
- "globalPoolId": "string",
- "headers": "string",
- "timeoutClient": 0,
- "timeoutConnection": 0,
- "timeoutMember": 0
}Delete a global listener
| glbid required | string Global Load Balancer ID |
| listenerid required | string Listener ID |
const request = require('request'); const options = { method: 'DELETE', url: 'https://glb.api.vngcloud.vn/glb-controller/v1/global-load-balancers/%7Bglbid%7D/global-listeners/%7Blistenerid%7D', headers: {Authorization: 'REPLACE_KEY_VALUE'} }; request(options, function (error, response, body) { if (error) throw new Error(error); console.log(body); });
const request = require('request'); const options = { method: 'GET', url: 'https://glb.api.vngcloud.vn/glb-controller/v1/global-load-balancers', headers: {Authorization: 'REPLACE_KEY_VALUE'} }; request(options, function (error, response, body) { if (error) throw new Error(error); console.log(body); });
Create a global load balancer
| description | string |
object (CreateGlobalListenerRequest) | |
object (CreateGlobalPoolRequest) | |
| name required | string |
| package required | string |
| paymentFlow required | string Enum: "automated" "gateway" |
| type required | string |
{- "description": "string",
- "globalListener": {
- "allowedCidrs": "string",
- "description": "string",
- "globalPoolId": "string",
- "headers": "string",
- "name": "string",
- "port": 0,
- "protocol": "string",
- "timeoutClient": 0,
- "timeoutConnection": 0,
- "timeoutMember": 0
}, - "globalPool": {
- "algorithm": "string",
- "description": "string",
- "globalPoolMembers": [
- {
- "description": "string",
- "members": [
- {
- "address": "string",
- "backupRole": true,
- "description": "string",
- "monitorPort": 0,
- "name": "string",
- "port": 0,
- "subnetId": "string",
- "weight": 0
}
], - "name": "string",
- "region": "string",
- "trafficDial": 0,
- "type": "string",
- "vpcId": "string"
}
], - "health": {
- "domainName": "string",
- "healthyThreshold": 0,
- "httpMethod": "string",
- "httpVersion": "string",
- "interval": 0,
- "path": "string",
- "protocol": "string",
- "successCode": "string",
- "timeout": 0,
- "unhealthyThreshold": 0
}, - "name": "string",
- "protocol": "string",
- "stickySession": true,
- "tlsEnabled": true
}, - "name": "string",
- "package": "string",
- "paymentFlow": "automated",
- "type": "string"
}Get a global load balancer
| glbid required | string glbid |
const request = require('request'); const options = { method: 'GET', url: 'https://glb.api.vngcloud.vn/glb-controller/v1/global-load-balancers/%7Bglbid%7D', headers: {Authorization: 'REPLACE_KEY_VALUE'} }; request(options, function (error, response, body) { if (error) throw new Error(error); console.log(body); });
Delete a global load balancer
| glbid required | string glbid |
const request = require('request'); const options = { method: 'DELETE', url: 'https://glb.api.vngcloud.vn/glb-controller/v1/global-load-balancers/%7Bglbid%7D', headers: {Authorization: 'REPLACE_KEY_VALUE'} }; request(options, function (error, response, body) { if (error) throw new Error(error); console.log(body); });
Get global pools
| glbid required | string Global Load Balancer ID |
const request = require('request'); const options = { method: 'GET', url: 'https://glb.api.vngcloud.vn/glb-controller/v1/global-load-balancers/%7Bglbid%7D/global-pools', headers: {Authorization: 'REPLACE_KEY_VALUE'} }; request(options, function (error, response, body) { if (error) throw new Error(error); console.log(body); });
Create a global pool
| glbid required | string Global Load Balancer ID |
| algorithm required | string |
| description | string |
required | Array of objects (CreateGlobalPoolMemberRequest) |
required | object (CreateGlobalPoolHealthRequest) |
| name required | string |
| protocol required | string |
| stickySession | boolean |
| tlsEnabled | boolean |
{- "algorithm": "string",
- "description": "string",
- "globalPoolMembers": [
- {
- "description": "string",
- "members": [
- {
- "address": "string",
- "backupRole": true,
- "description": "string",
- "monitorPort": 0,
- "name": "string",
- "port": 0,
- "subnetId": "string",
- "weight": 0
}
], - "name": "string",
- "region": "string",
- "trafficDial": 0,
- "type": "string",
- "vpcId": "string"
}
], - "health": {
- "domainName": "string",
- "healthyThreshold": 0,
- "httpMethod": "string",
- "httpVersion": "string",
- "interval": 0,
- "path": "string",
- "protocol": "string",
- "successCode": "string",
- "timeout": 0,
- "unhealthyThreshold": 0
}, - "name": "string",
- "protocol": "string",
- "stickySession": true,
- "tlsEnabled": true
}Get a global pool
| glbid required | string Global Load Balancer ID |
| poolid required | string Global Pool ID |
const request = require('request'); const options = { method: 'GET', url: 'https://glb.api.vngcloud.vn/glb-controller/v1/global-load-balancers/%7Bglbid%7D/global-pools/%7Bpoolid%7D', headers: {Authorization: 'REPLACE_KEY_VALUE'} }; request(options, function (error, response, body) { if (error) throw new Error(error); console.log(body); });
Update a global pool
| glbid required | string Global Load Balancer ID |
| poolid required | string Global Pool ID |
| algorithm required | string |
required | object (UpdateGlobalPoolHealthRequest) |
| stickySession | boolean |
| tlsEnabled | boolean |
{- "algorithm": "string",
- "health": {
- "domainName": "string",
- "healthyThreshold": 0,
- "httpMethod": "string",
- "httpVersion": "string",
- "interval": 0,
- "path": "string",
- "successCode": "string",
- "timeout": 0,
- "unhealthyThreshold": 0
}, - "stickySession": true,
- "tlsEnabled": true
}Delete a global pool
| glbid required | string Global Load Balancer ID |
| poolid required | string Global Pool ID |
const request = require('request'); const options = { method: 'DELETE', url: 'https://glb.api.vngcloud.vn/glb-controller/v1/global-load-balancers/%7Bglbid%7D/global-pools/%7Bpoolid%7D', headers: {Authorization: 'REPLACE_KEY_VALUE'} }; request(options, function (error, response, body) { if (error) throw new Error(error); console.log(body); });
Get pool members
| glbid required | string Global Load Balancer ID |
| poolid required | string Global Pool ID |
const request = require('request'); const options = { method: 'GET', url: 'https://glb.api.vngcloud.vn/glb-controller/v1/global-load-balancers/%7Bglbid%7D/global-pools/%7Bpoolid%7D/pool-members', headers: {Authorization: 'REPLACE_KEY_VALUE'} }; request(options, function (error, response, body) { if (error) throw new Error(error); console.log(body); });
Create a pool member
| glbid required | string Global Load Balancer ID |
| poolid required | string Global Pool ID |
| description | string |
required | Array of objects (GlobalMemberRequest) |
| name required | string |
| region required | string |
| trafficDial | integer |
| type required | string |
| vpcId | string |
{- "description": "string",
- "members": [
- {
- "address": "string",
- "backupRole": true,
- "description": "string",
- "monitorPort": 0,
- "name": "string",
- "port": 0,
- "subnetId": "string",
- "weight": 0
}
], - "name": "string",
- "region": "string",
- "trafficDial": 0,
- "type": "string",
- "vpcId": "string"
}Patch pool members
| glbid required | string Global Load Balancer ID |
| poolid required | string Global Pool ID |
required | Array of objects (ActionChangePoolMember) |
{- "bulkActions": [
- {
- "action": "string",
- "createPoolMember": {
- "description": "string",
- "members": [
- {
- "address": "string",
- "backupRole": true,
- "description": "string",
- "monitorPort": 0,
- "name": "string",
- "port": 0,
- "subnetId": "string",
- "weight": 0
}
], - "name": "string",
- "region": "string",
- "trafficDial": 0,
- "type": "string",
- "vpcId": "string"
}, - "id": "string",
- "updatePoolMember": {
- "members": [
- {
- "address": "string",
- "backupRole": true,
- "description": "string",
- "monitorPort": 0,
- "name": "string",
- "port": 0,
- "subnetId": "string",
- "weight": 0
}
], - "trafficDial": 0
}
}
]
}Get a pool member
| glbid required | string glbid |
| poolid required | string poolid |
| poolmemberid required | string poolmemberid |
const request = require('request'); const options = { method: 'GET', url: 'https://glb.api.vngcloud.vn/glb-controller/v1/global-load-balancers/%7Bglbid%7D/global-pools/%7Bpoolid%7D/pool-members/%7Bpoolmemberid%7D', headers: {Authorization: 'REPLACE_KEY_VALUE'} }; request(options, function (error, response, body) { if (error) throw new Error(error); console.log(body); });
Update a pool member
| glbid required | string Global load balancer ID |
| poolid required | string Global pool ID |
| poolmemberid required | string Global pool member ID |
required | Array of objects (GlobalMemberRequest) |
| trafficDial | integer |
{- "members": [
- {
- "address": "string",
- "backupRole": true,
- "description": "string",
- "monitorPort": 0,
- "name": "string",
- "port": 0,
- "subnetId": "string",
- "weight": 0
}
], - "trafficDial": 0
}Delete a pool member
| glbid required | string Global load balancer ID |
| poolid required | string Global pool ID |
| poolmemberid required | string Global pool member ID |
const request = require('request'); const options = { method: 'DELETE', url: 'https://glb.api.vngcloud.vn/glb-controller/v1/global-load-balancers/%7Bglbid%7D/global-pools/%7Bpoolid%7D/pool-members/%7Bpoolmemberid%7D', headers: {Authorization: 'REPLACE_KEY_VALUE'} }; request(options, function (error, response, body) { if (error) throw new Error(error); console.log(body); });
const request = require('request'); const options = { method: 'GET', url: 'https://glb.api.vngcloud.vn/glb-controller/v1/packages', headers: {Authorization: 'REPLACE_KEY_VALUE'} }; request(options, function (error, response, body) { if (error) throw new Error(error); console.log(body); });
const request = require('request'); const options = { method: 'GET', url: 'https://glb.api.vngcloud.vn/glb-controller/v1/regions', headers: {Authorization: 'REPLACE_KEY_VALUE'} }; request(options, function (error, response, body) { if (error) throw new Error(error); console.log(body); });
Retrieve the usage histories for a specific global load balancer
| glbid required | string Global Load Balancer ID |
| from required | string Start time in Unix timestamp |
| to required | string End time in Unix timestamp |
| type required | string Usage type (e.g., connection_rate, domestic_traffic_total, non_domestic_traffic_total) |
const request = require('request'); const options = { method: 'GET', url: 'https://glb.api.vngcloud.vn/glb-controller/v1/global-load-balancers/%7Bglbid%7D/usage-histories', qs: {from: 'SOME_STRING_VALUE', to: 'SOME_STRING_VALUE', type: 'SOME_STRING_VALUE'}, headers: {Authorization: 'REPLACE_KEY_VALUE'} }; request(options, function (error, response, body) { if (error) throw new Error(error); console.log(body); });