New to Kestra?
Use blueprints to kickstart your first workflows.
Automate Nutanix AHV chargeback with Kestra. List VMs, compute per-VM cost from vCPU cores, append rows to a Google Sheet, and post a Slack summary on a monthly schedule.
Finance teams running private cloud on Nutanix AHV need a recurring, defensible cost-allocation report, but the inventory lives in Prism Central while the chargeback ledger lives in a spreadsheet. This blueprint closes that gap. It pulls every AHV virtual machine with its resource configuration, computes a cost per VM from vCPU cores and a configurable rate, appends the rows to a Google Sheet that accumulates one period per run, and posts a summary to Slack so stakeholders see the numbers without opening a tool. It is a complete Nutanix inventory, showback, and chargeback pipeline you can run on day one.
list_vms (io.kestra.plugin.ee.nutanix.ahv.ListVms) queries Prism Central with fetchType: FETCH and returns all AHV VMs and their socket and core configuration as rows.compute_chargeback (io.kestra.plugin.scripts.python.Script, run on a python:3.11-slim Docker task runner) reads those rows, multiplies numSockets by numCoresPerSocket per VM, applies the core_hour_rate input, writes a chargeback.csv, and emits vm_count and total_cost outputs.append_to_sheet (io.kestra.plugin.googleworkspace.sheets.Load) loads the CSV into the Chargeback range with insertType: APPEND, so each run adds a fresh period to the finance ledger.notify (io.kestra.plugin.slack.notifications.SlackIncomingWebhook) posts the VM count and period total to Slack.Schedule trigger (monthly_report) is wired for the 1st of each month at 06:00 and ships disabled, ready to enable.Prism Central can list VMs but cannot run them through a pricing model, write them to a finance spreadsheet, and notify a channel on a schedule. Kestra ties those steps into one declarative YAML flow with event and schedule triggers, automatic retries, and full execution lineage, so a failed Sheets write or Slack post is visible and replayable instead of silent. You get auditable runs, versioned logic, and a single place to evolve the cost model.
NUTANIX_HOST: Prism Central host.NUTANIX_TOKEN: Prism Central bearer token.GCP_SERVICE_ACCOUNT: service account key JSON with Google Sheets access.SLACK_WEBHOOK_URL: Slack incoming webhook URL.spreadsheet_id.core_hour_rate to your pricing (defaults to 0.05).monthly_report trigger to schedule it.compute_chargeback with memory and storage, not just cores.Schedule cron to weekly or quarterly, or trigger the flow from an external event.