Skip to content

[FEATURE] Add agent-friendly discovery commands for VPS purchase inputs #32

@coygeek

Description

@coygeek

Feature Description

Please add higher-level discovery commands or examples that help users collect the exact IDs needed for API-created VPS workflows:

  • VPS price item ID
  • template ID
  • data center ID
  • payment method ID
  • public key ID

Problem Statement

The API requires several IDs to purchase and set up a VPS. Some are easy to list with the current CLI:

hapi vps templates list --format json
hapi vps data-centers list --format json
hapi vps public-keys list --format json

But priced item discovery is not exposed through the CLI today, even though the OpenAPI spec has GET /api/billing/v1/catalog.

For agentic workflows, the discovery path should be obvious and fully scriptable. Agents should not need dashboard screenshots or trial-and-error item IDs to know whether the correct value is:

hostingercom-vps-kvm2

or:

hostingercom-vps-kvm2-usd-1m

Proposed Solution

Add a guided command such as:

hapi vps plans list --format json

or expose filtered billing catalog commands:

hapi billing catalog list --category VPS --format json

It would be especially helpful if output clearly distinguished:

  • parent catalog item IDs, for example hostingercom-vps-kvm2
  • purchasable price item IDs, for example hostingercom-vps-kvm2-usd-1m
  • currency
  • billing period
  • first-period price
  • renewal price

Use Cases

  • Generate config for repeatable VPS provisioning.
  • Select a region/template/plan from JSON without visiting hPanel.
  • Let agents validate a requested plan before attempting a billable operation.
  • Avoid common API errors caused by using a parent catalog ID where a price item ID is required.

Additional Context

This would make the official CLI a complete setup companion for future-proof automation: discover IDs, create keys, purchase a VPS, inspect it, and stop it all from one tool.

Are you willing to contribute?

  • Yes, I'd like to implement this feature
  • Yes, but I need guidance
  • No, but I'm available for testing
  • No

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions