- CivoCloud/api
The CivoCloud/api module acts as an abstracton layer for accessing the various civo APIs
- Backend :
Object
The CivoCloud/api module acts as an abstracton layer for accessing the various civo APIs
- CivoCloud/api
- .Civo
- .Charges ⇐
Civo
- ~listCharges([options]) ⇒
Promise
- ~listCharges([options]) ⇒
- .Domain ⇐
Civo
- ~listDomains() ⇒
Promise
- ~createDomain(name) ⇒
Promise
- ~deleteDomain(id) ⇒
Promise
- ~listDomainRecords(id) ⇒
Promise
- ~createDomainRecord(domainId, type, name, value, [options]) ⇒
Promise
- ~deleteDomainRecord(domainId, id) ⇒
Promise
- ~listDomains() ⇒
- .Firewall ⇐
Civo
- ~listFirewalls() ⇒
Promise
- ~createFirewall(name) ⇒
Promise
- ~deleteFirewall(id) ⇒
Promise
- ~listFirewallRules(id) ⇒
Promise
- ~createFirewallRule(id, start_port, [options]) ⇒
Promise
- ~deleteFirewallRule(firewallId, id) ⇒
Promise
- ~listFirewalls() ⇒
- .Instance ⇐
Civo
- instance
- .instanceSizes :
Object
- .instanceSizes :
- inner
- ~listInstances() ⇒
Promise
- ~createInstance(size, network_id, hostname, [options]) ⇒
Promise
- ~deleteInstance(id) ⇒
Promise
- ~getInstance(id) ⇒
Promise
- ~retagInstance(id, [options]) ⇒
Promise
- ~rebootInstance(id) ⇒
Promise
- ~hardRebootInstance(id) ⇒
Promise
- ~softRebootInstance(id) ⇒
Promise
- ~stopInstance(id) ⇒
Promise
- ~startInstance(id) ⇒
Promise
- ~resizeInstance(id, size) ⇒
Promise
- ~rebuildInstance(id) ⇒
Promise
- ~restoreInstance(id, snapshot) ⇒
Promise
- ~updateInstanceFirewall(id, [options]) ⇒
Promise
- ~movePublicIpToInstance(id, ipAddress) ⇒
Promise
- ~listInstances() ⇒
- instance
- .InstanceRegion ⇐
Civo
- ~listRegions() ⇒
Promise
- ~listRegions() ⇒
- .InstanceSizing ⇐
Civo
- ~listInstanceSizes() ⇒
Promise
- ~listInstanceSizes() ⇒
- .LoadBallancer ⇐
Civo
- ~listLoadBalancers() ⇒
Promise
- ~createLoadBalancer(hostname, backends, [options]) ⇒
Promise
- ~updateLoadBalancer(id, [options]) ⇒
Promise
- ~deleteLoadBalancer(id) ⇒
Promise
- ~listLoadBalancers() ⇒
- .Network ⇐
Civo
- ~listNetworks() ⇒
Promise
- ~createNetwork(label, [options]) ⇒
Promise
- ~renameNetwork(id, label) ⇒
Promise
- ~deleteNetwork(id) ⇒
Promise
- ~listNetworks() ⇒
- .Quota ⇐
Civo
- ~getQuota() ⇒
Promise
- ~getQuota() ⇒
- .Snapshot ⇐
Civo
- ~listSnapshots() ⇒
Promise
- ~createSnapshot(name, instance_id, safe) ⇒
Promise
- ~updateSnapshot(name, instance_id, safe) ⇒
Promise
- ~deleteSnapshot(name) ⇒
Promise
- ~listSnapshots() ⇒
- .SSHKeys ⇐
Civo
- ~listSSHKeys() ⇒
Promise
- ~uploadSSHKey(name, public_key) ⇒
Promise
- ~deleteSSHKey(name) ⇒
Promise
- ~listSSHKeys() ⇒
- .Template ⇐
Civo
- ~listTemplates() ⇒
Promise
- ~createTemplate(name, image_id, [options]) ⇒
Promise
- ~updateTemplate(id, [options]) ⇒
Promise
- ~deleteTemplate(id) ⇒
Promise
- ~listTemplates() ⇒
- .Webhook ⇐
Civo
- ~listWebhooks() ⇒
Promise
- ~createWebhook(url, [options]) ⇒
Promise
- ~deleteWebhook(id) ⇒
Promise
- ~testWebhook(id) ⇒
Promise
- ~updateWebhook(id, [options]) ⇒
Promise
- ~listWebhooks() ⇒
Kind: static class of CivoCloud/api
Param | Type | Default | Description |
---|---|---|---|
options | Object |
||
options.apiToken | String |
the provided api token from your civo account | |
[options.host] | String |
https://api.civo.com/v2 |
An optional end point |
[options.port] | String | Number |
443 |
an optional port to call |
CivoCloud/api.Charges ⇐ Civo
Kind: static class of CivoCloud/api
Extends: Civo
See: https://www.civo.com/api/charges
gets an array of chargable service hours [GET]
Kind: inner method of Charges
Access: public
See: https://www.civo.com/api/charges#listing-charges
Param | Type | Description |
---|---|---|
[options] | Object |
an optional options object |
[options.from] | String | Date |
optional from date range |
[options.to] | String | Date |
optional to date range (max 31 days) |
CivoCloud/api.Domain ⇐ Civo
Kind: static class of CivoCloud/api
Extends: Civo
See: https://www.civo.com/api/dns
- .Domain ⇐
Civo
- ~listDomains() ⇒
Promise
- ~createDomain(name) ⇒
Promise
- ~deleteDomain(id) ⇒
Promise
- ~listDomainRecords(id) ⇒
Promise
- ~createDomainRecord(domainId, type, name, value, [options]) ⇒
Promise
- ~deleteDomainRecord(domainId, id) ⇒
Promise
- ~listDomains() ⇒
gets an array of the domains on civo account [GET]
Kind: inner method of Domain
Returns: Promise
- a promise wich resolves with the foirewall list or rejects with an error
Access: public
See: https://www.civo.com/api/dns#list-domain-names
creates a new domain within civo [POST]
Kind: inner method of Domain
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/dns#setup-a-new-domain
Param | Type | Description |
---|---|---|
name | String |
the ndomain name for the new domain |
removes a new domain within civo [DELETE]
Kind: inner method of Domain
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/dns#deleting-a-domain
Param | Type | Description |
---|---|---|
id | String |
the domain id to be deleted |
gets an array of the domains on civo account [GET]
Kind: inner method of Domain
Returns: Promise
- a promise wich resolves with the foirewall list or rejects with an error
Access: public
See: https://www.civo.com/api/dns#list-dns-records
Param | Type | Description |
---|---|---|
id | String |
the domains id to get the records in |
gets an array of the domains on civo account [POST]
Kind: inner method of Domain
Returns: Promise
- a promise wich resolves with the foirewall list or rejects with an error
Access: public
See: https://www.civo.com/api/dns#create-a-new-dns-record
Param | Type | Default | Description |
---|---|---|---|
domainId | String |
the domain to delete the record from | |
type | String |
the type of dns record to use which can be either: 'a', 'cname', 'mx', or 'txt' | |
name | String |
the portion before the domain name (e.g. 'www', or '@') | |
value | Stirng |
the ip address fr this dns record to serve | |
[options] | Object |
an optional options object | |
[options.priority] | Number |
10 |
mx records only but determines the priority of the |
[options.ttl] | Number |
3600 |
the time to live for the dns record in seconds |
removes a new domain within civo [DELETE]
Kind: inner method of Domain
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/dns#deleting-a-dns-record
Param | Type | Description |
---|---|---|
domainId | String |
the domain to delete the record from |
id | String |
the record to be deleted |
CivoCloud/api.Firewall ⇐ Civo
Kind: static class of CivoCloud/api
Extends: Civo
See: https://www.civo.com/api/firewall
- .Firewall ⇐
Civo
- ~listFirewalls() ⇒
Promise
- ~createFirewall(name) ⇒
Promise
- ~deleteFirewall(id) ⇒
Promise
- ~listFirewallRules(id) ⇒
Promise
- ~createFirewallRule(id, start_port, [options]) ⇒
Promise
- ~deleteFirewallRule(firewallId, id) ⇒
Promise
- ~listFirewalls() ⇒
gets an array of the firewalls on civo account [GET]
Kind: inner method of Firewall
Returns: Promise
- a promise wich resolves with the foirewall list or rejects with an error
Access: public
See: https://www.civo.com/api/firewall#list-firewalls
creates a new firewall in civo [POST]
Kind: inner method of Firewall
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/firewall#create-a-new-firewall
Param | Type | Description |
---|---|---|
name | String |
the name to be used to identify the firewall in civo |
deletes an existing firewall within civo [DELETE]
Kind: inner method of Firewall
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/firewall#deleting-a-firewall
Param | Type | Description |
---|---|---|
id | String |
the firewalls id to be used to identify the network in civo |
gets an array of the firewalls rules on civo account [GET]
Kind: inner method of Firewall
Returns: Promise
- a promise wich resolves with the foirewall list or rejects with an error
Access: public
See: https://www.civo.com/api/firewall#list-firewall-rules
Param | Type | Description |
---|---|---|
id | String |
the firewalls id to be used to identify the network in civo |
creates a new firewall rule within an existing firewall [POST]
Kind: inner method of Firewall
Returns: Promise
- a promise wich resolves with a success or rejects with an error
Access: public
See: https://www.civo.com/api/firewall#create-a-new-firewall-rule
Param | Type | Description |
---|---|---|
id | String |
the Id for the firewall to create the rule in |
start_port | String | Number |
The single port or start of a range of ports to allows |
[options] | Object |
an optional object |
[options.end_port] | Stirng | Number |
the end of a range of ports |
[options.protocol] | String |
the protocol that the ule will allow e.g. 'tcp' |
[options.direction] | String |
the direction in which the rule applies to e.g. 'inwards' |
[options.cidr] | String |
a ip range in which the rule is applied to e.g. '0.0.0.0/0' for all |
deletes an existing firewall rule within a firewall [DELETE]
Kind: inner method of Firewall
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/firewall#deleting-a-firewall-rule
Param | Type | Description |
---|---|---|
firewallId | String |
the firewalls id to be used to identify in civo |
id | String |
the firewall rules id in civo |
CivoCloud/api.Instance ⇐ Civo
Kind: static class of CivoCloud/api
Extends: Civo
See: https://www.civo.com/api/instances
- .Instance ⇐
Civo
- instance
- .instanceSizes :
Object
- .instanceSizes :
- inner
- ~listInstances() ⇒
Promise
- ~createInstance(size, network_id, hostname, [options]) ⇒
Promise
- ~deleteInstance(id) ⇒
Promise
- ~getInstance(id) ⇒
Promise
- ~retagInstance(id, [options]) ⇒
Promise
- ~rebootInstance(id) ⇒
Promise
- ~hardRebootInstance(id) ⇒
Promise
- ~softRebootInstance(id) ⇒
Promise
- ~stopInstance(id) ⇒
Promise
- ~startInstance(id) ⇒
Promise
- ~resizeInstance(id, size) ⇒
Promise
- ~rebuildInstance(id) ⇒
Promise
- ~restoreInstance(id, snapshot) ⇒
Promise
- ~updateInstanceFirewall(id, [options]) ⇒
Promise
- ~movePublicIpToInstance(id, ipAddress) ⇒
Promise
- ~listInstances() ⇒
- instance
an object containing the different instance sizes for use with the API
Kind: instance property of Instance
gets an array of the instances on civo cloud [GET]
Kind: inner method of Instance
Returns: Promise
- a promise wich resolves with the instance list or rejects with an error
Access: public
See: https://www.civo.com/api/instances#list-instances
creates a new instance network in civo [POST]
Kind: inner method of Instance
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/instances#create-an-instance
Param | Type | Description |
---|---|---|
size | String |
the size of the instance to create (obtained from listInstanceSizes()) |
network_id | String |
the id of the private network to create the instance in |
hostname | String |
the name of the instance to use |
[options] | Object |
an optional options object |
[options.template] | String |
the id of the template to use |
[options.initial_user] | String |
the name of the initial user to create on the instance |
[options.ssh_key_id] | String |
the id of the ssh key to add to the instance |
[options.region] | String |
the region to create the instance in |
[options.public_ip] | Boolean |
specifies if a public ip should be used for the instance |
[options.snapshot_id] | String |
the id of the snapshot to load into the instance |
[options.tags] | String |
a space seperated list of tags to add to the instance |
deletes an existing instance within civo [DELETE]
Kind: inner method of Instance
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/instances#deleting-an-instance
Param | Type | Description |
---|---|---|
id | String |
the instance id to be used to identify the instance in civo |
gets an existing instance from civo [GET]
Kind: inner method of Instance
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/instances#retrieving-an-instance
Param | Type | Description |
---|---|---|
id | String |
the instance id to be used to identify the instance in civo |
updates the tags on an existing instance in civo [PUT]
Kind: inner method of Instance
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/instances#retagging-an-instance
Param | Type | Description |
---|---|---|
id | String |
the instance id to be used to identify the instance in civo |
[options] | Object |
an optional options object |
[options.tags] | Array.<String> | String |
a space seperated string of tags or an array of tags |
reboots an instance in civo [POST]
Kind: inner method of Instance
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/instances#rebooting-an-instance
Param | Type | Description |
---|---|---|
id | String |
the instance id to be used to identify the instance in civo |
hard reboots an instance in civo [POST]
Kind: inner method of Instance
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/instances#rebooting-an-instance
Param | Type | Description |
---|---|---|
id | String |
the instance id to be used to identify the instance in civo |
soft reboots an instance in civo [POST]
Kind: inner method of Instance
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/instances#rebooting-an-instance
Param | Type | Description |
---|---|---|
id | String |
the instance id to be used to identify the instance in civo |
stops (shutdown) an instance in civo [PUT]
Kind: inner method of Instance
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/instances#shutting-down-an-instance
Param | Type | Description |
---|---|---|
id | String |
the instance id to be used to identify the instance in civo |
starts an instance in civo [PUT]
Kind: inner method of Instance
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/instances#starting-an-instance-after-being-shut-down
Param | Type | Description |
---|---|---|
id | String |
the instance id to be used to identify the instance in civo |
resizes an instance in civo [PUT]
Kind: inner method of Instance
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/instances#updating-resizing-an-instance
Param | Type | Description |
---|---|---|
id | String |
the instance id to be used to identify the instance in civo |
size | String |
the new size to resize the exsting instance to |
rebuilds an instance in civo [PUT]
Kind: inner method of Instance
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/instances#rebuilding-an-instance
Param | Type | Description |
---|---|---|
id | String |
the instance id to be used to identify the instance in civo |
restores an instance in civo from a snapshot [PUT]
Kind: inner method of Instance
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/instances#restoring-an-instance-from-a-snapshot
Param | Type | Description |
---|---|---|
id | String |
the instance id to be used to identify the instance in civo |
snapshot | String |
the snapshot id to specify which snapshot to restore |
Applies a firewall to an instance [PUT]
Kind: inner method of Instance
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/instances#setting-the-firewall-for-an-instance
Param | Type | Description |
---|---|---|
id | String |
the instance id to be used to identify the instance in civo |
[options] | Object |
an optional options object |
[options.firewall_id] | String |
the firewall id to specify which firewall to apply |
Moves an owned public ip address from one instance you own to another instance [PUT]
Kind: inner method of Instance
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/instances#moving-a-public-ip-between-instances
Param | Type | Description |
---|---|---|
id | String |
the instance id to be used to identify the instance in civo |
ipAddress | String |
the ip address to move to this instance |
CivoCloud/api.InstanceRegion ⇐ Civo
Kind: static class of CivoCloud/api
Extends: Civo
See: https://www.civo.com/api/regions
gets an array of the currently available regions on civo cloud [GET]
Kind: inner method of InstanceRegion
Returns: Promise
- a promise wich resolves with the available region list or rejects with an
error
Access: public
See: https://www.civo.com/api/regions#listing-available-regions
CivoCloud/api.InstanceSizing ⇐ Civo
Kind: static class of CivoCloud/api
Extends: Civo
See: https://www.civo.com/api/sizes
gets an array of the currently available instance sizes on civo cloud [GET]
Kind: inner method of InstanceSizing
Returns: Promise
- a promise wich resolves with the instance size list or rejects with an
error
Access: public
See: https://www.civo.com/api/sizes#listing-available-sizes
CivoCloud/api.LoadBallancer ⇐ Civo
Kind: static class of CivoCloud/api
Extends: Civo
See: https://www.civo.com/api/loadbalancer
- .LoadBallancer ⇐
Civo
- ~listLoadBalancers() ⇒
Promise
- ~createLoadBalancer(hostname, backends, [options]) ⇒
Promise
- ~updateLoadBalancer(id, [options]) ⇒
Promise
- ~deleteLoadBalancer(id) ⇒
Promise
- ~listLoadBalancers() ⇒
Lists all of the available load ballancers on the civo account [GET]
Kind: inner method of LoadBallancer
Returns: Promise
- resolves with a list of available load balancers or rejects with an error
Access: public
See: https://www.civo.com/api/loadbalancer#list-load-balancers
Creates a new load ballancer on the civo account [POST]
Kind: inner method of LoadBallancer
Returns: Promise
- resolves when load balancer is created or rejects with an error
Access: public
See: https://www.civo.com/api/loadbalancer#setup-a-new-load-balancer
Param | Type | Default | Description |
---|---|---|---|
hostname | String |
the hostname to receive traffic on | |
backends | Array.<Backend> |
an array of backends to load ballance | |
[options] | Object |
an optional object containing all optional parameters | |
[options.protocol] | String |
'http' |
protocol to use (either 'http' or 'https') |
[options.tls_certificate] | String |
if protocol is https then base64-encoded certificate in PEM format | |
[options.tls_key] | String |
if protocol is https then base64-encoded key in PEM format | |
[options.port] | String | Number |
80 |
the port to listen on |
[options.max_request_size] | Number |
20 |
the maximum request size in megabytes |
[options.policy] | String |
'random' |
routing policy can be either 'least_conn', 'random', 'round_robin', or 'ip_hash' |
[options.health_check_path] | String |
'/' |
what url to use on the backends to check status |
[options.fail_timeout] | Number |
30 |
how long to wait (in seconds) before determining backend failure |
[options.max_conns] | Number |
10 |
how many concurrent connections a backend can handle |
[options.ignore_invalid_backend_tls] | Boolean |
true |
ignore invalid/self-signed tls certs on backend |
updates an existing load ballancer with new information [PUT]
Kind: inner method of LoadBallancer
Returns: Promise
- resolves when load balancer is created or rejects with an error
Access: public
See: https://www.civo.com/api/loadbalancer#update-a-load-balancer
Param | Type | Description |
---|---|---|
id | String |
the load balancers id to update |
[options] | Object |
an optional object containing all optional parameters |
[options.hostname] | String |
the hostname to receive traffic on |
[options.backends] | Array.<Backend> |
an array of backends to load ballance |
[options.protocol] | String |
protocol to use (either 'http' or 'https') |
[options.tls_certificate] | String |
if protocol is https then base64-encoded certificate in PEM format |
[options.tls_key] | String |
if protocol is https then base64-encoded key in PEM format |
[options.port] | String | Number |
the port to listen on |
[options.max_request_size] | Number |
the maximum request size in megabytes |
[options.policy] | String |
routing policy can be either 'least_conn', 'random', 'round_robin', or 'ip_hash' |
[options.health_check_path] | String |
what url to use on the backends to check status |
[options.fail_timeout] | Number |
how long to wait (in seconds) before determining backend failure |
[options.max_conns] | Number |
how many concurrent connections a backend can handle |
[options.ignore_invalid_backend_tls] | Boolean |
ignore invalid/self-signed tls certs on backend |
deletes an existing load ballancer from the civo account [DELETE]
Kind: inner method of LoadBallancer
Returns: Promise
- resolves when load balancer is deleted or rejects with an error
Access: public
See: https://www.civo.com/api/loadbalancer#deleting-a-load-balancer
Param | Type | Description |
---|---|---|
id | String |
the id for the load balancers to delete |
CivoCloud/api.Network ⇐ Civo
Kind: static class of CivoCloud/api
Extends: Civo
See: https://www.civo.com/api/networks
- .Network ⇐
Civo
- ~listNetworks() ⇒
Promise
- ~createNetwork(label, [options]) ⇒
Promise
- ~renameNetwork(id, label) ⇒
Promise
- ~deleteNetwork(id) ⇒
Promise
- ~listNetworks() ⇒
gets an array of the private networks on civo cloud [GET]
Kind: inner method of Network
Returns: Promise
- a promise wich resolves with the network list or rejects with an error
Access: public
See: https://www.civo.com/api/networks#listing-the-private-networks
creates a new private network in civo [POST]
Kind: inner method of Network
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/networks#create-a-private-network
Param | Type | Description |
---|---|---|
label | String |
the name to be used to identify the key in civo |
[options] | Object |
an optional options object |
[options.region] | String |
an optional region to create the network in |
renames an existing network within civo [PUT]
Kind: inner method of Network
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/networks#renaming-a-network
Param | Type | Description |
---|---|---|
id | String |
the networks id to be used to identify the network in civo |
label | String |
the new label to be used for the network |
deletes an existing network within civo [DELETE]
Kind: inner method of Network
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/networks#removing-a-private-network
Param | Type | Description |
---|---|---|
id | String |
the networks id to be used to identify the network in civo |
CivoCloud/api.Quota ⇐ Civo
Kind: static class of CivoCloud/api
Extends: Civo
See: https://www.civo.com/api/quota
gets an object of quota values [GET]
Kind: inner method of Quota
Access: public
See: https://www.civo.com/api/quota#determining-current-quota
CivoCloud/api.Snapshot ⇐ Civo
Kind: static class of CivoCloud/api
Extends: Civo
See: https://www.civo.com/api/snapshot
- .Snapshot ⇐
Civo
- ~listSnapshots() ⇒
Promise
- ~createSnapshot(name, instance_id, safe) ⇒
Promise
- ~updateSnapshot(name, instance_id, safe) ⇒
Promise
- ~deleteSnapshot(name) ⇒
Promise
- ~listSnapshots() ⇒
gets an array of the snapshots on civo account [GET]
Kind: inner method of Snapshot
Returns: Promise
- a promise wich resolves with the foirewall list or rejects with an error
Access: public
See: https://www.civo.com/api/snapshots#list-snapshots
creates a snapshot of a given instance (alias of updateSnapshot) [PUT]
Kind: inner method of Snapshot
Returns: Promise
- a promise wich resolves with the foirewall list or rejects with an error
Access: public
See: https://www.civo.com/api/snapshots#create-a-new-or-update-an-old-snapshot
Param | Type | Description |
---|---|---|
name | String |
the new name of the snapshot |
instance_id | String |
the id of the instance to be snapshotted |
safe | Boolean |
determins if an instance is stopped before snapshotting |
updates a snapshot of a given instance [PUT]
Kind: inner method of Snapshot
Returns: Promise
- a promise wich resolves with the foirewall list or rejects with an error
Access: public
See: https://www.civo.com/api/snapshots#create-a-new-or-update-an-old-snapshot
Param | Type | Description |
---|---|---|
name | String |
the new name of the snapshot |
instance_id | String |
the id of the instance to be snapshotted |
safe | Boolean |
determins if an instance is stopped before snapshotting |
deletes an existing snapshot within civo [DELETE]
Kind: inner method of Snapshot
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/snapshots#deleting-a-snapshot
Param | Type | Description |
---|---|---|
name | String |
the snapshots name to be used to identify the network in civo |
CivoCloud/api.SSHKeys ⇐ Civo
Kind: static class of CivoCloud/api
Extends: Civo
See: https://www.civo.com/api/sshkeys
- .SSHKeys ⇐
Civo
- ~listSSHKeys() ⇒
Promise
- ~uploadSSHKey(name, public_key) ⇒
Promise
- ~deleteSSHKey(name) ⇒
Promise
- ~listSSHKeys() ⇒
gets an array of the currently available ssh keys on civo cloud [GET]
Kind: inner method of SSHKeys
Returns: Promise
- a promise which resolves with the sshkeys list or rejects with an error
Access: public
See: https://www.civo.com/api/sshkeys#listing-the-ssh-keys
uploads a supplied ssh key into civo [POST]
Kind: inner method of SSHKeys
Returns: Promise
- a promise wich resolves with the result and id or rejects with an error
Access: public
See: https://www.civo.com/api/sshkeys#uploading-an-ssh-key
Param | Type | Description |
---|---|---|
name | String |
the name to be used to identify the key in civo |
public_key | String |
the public key string to be uploaded |
gets an array of the currently available ssh keys on civo cloud [DELETE]
Kind: inner method of SSHKeys
Returns: Promise
- a promise wich resolves with the sshkeys list or rejects with an error
Access: public
See: https://www.civo.com/api/sshkeys#removing-an-ssh-key
Param | Type | Description |
---|---|---|
name | String |
the name of the public key to delete |
CivoCloud/api.Template ⇐ Civo
Kind: static class of CivoCloud/api
Extends: Civo
See: https://www.civo.com/api/templates
- .Template ⇐
Civo
- ~listTemplates() ⇒
Promise
- ~createTemplate(name, image_id, [options]) ⇒
Promise
- ~updateTemplate(id, [options]) ⇒
Promise
- ~deleteTemplate(id) ⇒
Promise
- ~listTemplates() ⇒
gets an array of the currently available templates on civo cloud [GET]
Kind: inner method of Template
Returns: Promise
- a promise wich resolves with the available region list or rejects with an
error
Access: public
See: https://www.civo.com/api/templates#listing-available-templates
creates a new template on the civo account [POST]
Kind: inner method of Template
Returns: Promise
- a promise wich resolves with the available region list or rejects with an
error
Access: public
See: https://www.civo.com/api/templates#create-a-new-template
Param | Type | Description |
---|---|---|
name | String |
a readable name for the custom template |
image_id | String |
an openstack glance image id |
[options] | Object |
an optional object |
[options.short_description] | String |
an optional one line description of the template |
[options.description] | String |
an optional full description of the template |
[options.default_username] | String |
an optional udername to be created within the new template |
[options.cloud_config] | String |
an optional customisation script to run after the instance is first booted |
updates an existing template on the civo account [PUT]
Kind: inner method of Template
Returns: Promise
- a promise wich resolves with the available region list or rejects with an
error
Access: public
See: https://www.civo.com/api/templates#update-a-template
Param | Type | Description |
---|---|---|
id | String |
the templates id to be used to identify the network in civo |
[options] | Object |
an optional object |
[options.name] | String |
a readable name for the custom template |
[options.short_description] | String |
an optional one line description of the template |
[options.description] | String |
an optional full description of the template |
[options.default_username] | String |
an optional udername to be created within the new template |
[options.cloud_config] | String |
an optional customisation script to run after the instance is first booted |
deletes an existing template within civo [DELETE]
Kind: inner method of Template
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/templates#deleting-a-template
Param | Type | Description |
---|---|---|
id | String |
the templates id to be used to identify the network in civo |
CivoCloud/api.Webhook ⇐ Civo
Kind: static class of CivoCloud/api
Extends: Civo
See: https://www.civo.com/api/webhooks
- .Webhook ⇐
Civo
- ~listWebhooks() ⇒
Promise
- ~createWebhook(url, [options]) ⇒
Promise
- ~deleteWebhook(id) ⇒
Promise
- ~testWebhook(id) ⇒
Promise
- ~updateWebhook(id, [options]) ⇒
Promise
- ~listWebhooks() ⇒
gets an array of the currently available ebhooks sizes on civo cloud [GET]
Kind: inner method of Webhook
Returns: Promise
- a promise wich resolves with the webhook list or rejects with an error
Access: public
See: https://www.civo.com/api/webhooks#list-webhooks
creates and registers a new webhook onto the civo account. [POST]
Kind: inner method of Webhook
Returns: Promise
- resolves with the newly created webhook or rejects with an error
Access: public
See: https://www.civo.com/api/webhooks#create-a-new-webhook
Param | Type | Default | Description |
---|---|---|---|
url | String |
a url to send the webhook request too | |
[options] | Object |
an object for options | |
[options.events] | Array.<String> | String |
all events |
an array of event names to subscribe to |
[options.secret] | String |
random string |
a secret to send with webhook requests |
deletes an existing webhook within civo [DELETE]
Kind: inner method of Webhook
Returns: Promise
- a promise wich resolves with the result or rejects with an error
Access: public
See: https://www.civo.com/api/webhooks#deleting-a-webhook
Param | Type | Description |
---|---|---|
id | String |
the webhook id to be used to identify which webhook to delete in civo |
sends a dummy payload to the specific webhook in order to test it [POST]
Kind: inner method of Webhook
Returns: Promise
- resolves when the tummy payload is sent or rejects with an error
Access: public
See: https://www.civo.com/api/webhooks#test-a-webhook
Param | Type | Description |
---|---|---|
id | String |
the id for the specific webhook to test |
creates and registers a new webhook onto the civo account. [PUT]
Kind: inner method of Webhook
Returns: Promise
- resolves with the newly created webhook or rejects with an error
Access: public
See: https://www.civo.com/api/webhooks#create-a-new-webhook
Param | Type | Description |
---|---|---|
id | String |
the id for the specific webhook |
[options] | Object |
an object for options |
[options.url] | String |
a url to send the webhook request too |
[options.events] | Array.<String> | String |
an array of event names to subscribe to |
[options.secret] | String |
a secret to send with webhook requests |
Kind: global typedef
Properties
Name | Type | Description |
---|---|---|
[instance_id] | String |
the backend instance_id |
[protocol] | String |
the protocol to communicate with the backend on (either 'http' or 'https') |
[port] | Number |
the port to communicate with the backend on |