Gandi

Table Of Contents

Previous topic

Http Reverse proxy API Reference

Next topic

Rating API Reference

Hosting Catalog API Reference

The Catalog API returns the cost in credits for hosting resources.

Methods

hosting.catalog.list(apikey[, opts=nil])

List credits consumption by resource

Parameters:
Returns:

list of struct – list of consumption

hosting.catalog.price(apikey, items)

Retrieve the prices for a given product_type/quantity/flavor/state.

Prices are returned in the same order they where entered.

Parameters:
  • apikey (string) – API connection key
  • items (array) – API connection key
Returns:

list of struct – list of consumption

Parameters

HostingCatalogFlavor

used by HostingCatalogListOptions

Name Description
v4_public -
public -
private -
v6 -
HostingCatalogListOptions

parameter of hosting.catalog.list()

Name Default Type Mandatory
flavor   string no
status   string no
status of the resource
type   string no
type of the resource
HostingCatalogStatus

used by HostingCatalogListOptions

Name Description
being_created -
created -
running -
paused -
locked -
deleted -
HostingCatalogType

used by HostingCatalogListOptions

Name Description
instance -
cpu -
ram -
disk_data -
disk_snapshot -
disk_snapshot_auto -
ip -
bw_out -
rproxy -
rproxy_server -
rproxy_ssl -

Returns

HostingCatalogPriceReturn

returned by hosting.catalog.price()

HostingCatalogReturn

returned by hosting.catalog.list()

Name Type
credits double
cost for resource matching type, flavor, range and status
flavor string
resource subtype. Can be nil
range array
boundaries of the resource metrics
slice int
resource metrics factor (Memory increase in slice of 64Mo)
status string
resource status: running, halted, ...
type string
type of the resource