ves-io-schema-infraprotect_billing-CustomAPI-List

Examples of performing infraprotect_billing CustomAPI List

Usecase:

List all zones configured

Request:

Request using vesctl:

vesctl request rpc infraprotect_billing.CustomAPI.List -i request.yaml --uri /public/namespaces/system/infraprotect_billings --http-method GET

where file request.yaml has following contents:

namespace: system

vesctl yaml response:

items:
  currentMonth: 1
  currentYear: 10
  last30Days: 1
  last365Days: 2
  previousMonth: 3
  previousYear: 4

Request using curl:

curl -X 'GET' -H 'Content-Type: application/json' -H 'X-Volterra-Useragent: v1/pgm=_tmp_go-build896999001_b001_apidocs.test/host=docker-desktop' 'https://acmecorp.console.ves.volterra.io/api/infraprotect/namespaces/system/infraprotect_billings?namespace=system'

curl response:

HTTP/1.1 200 OK
Content-Length: 163
Content-Type: application/json
Date: Fri, 31 Jul 2020 12:54:16 GMT
Vary: Accept-Encoding

{
  "items": {
    "current_month": 1,
    "current_year": 10,
    "last_30_days": 1,
    "last_365_days": 2,
    "previous_month": 3,
    "previous_year": 4
  }
}