Miran
Status: available · package wg-flow-plugin-miran 0.1.0 · provider miran · category cloud.
The plugin reads a Miran client cabinet through the BILLmanager API at https://bill.miran.ru/billmgr. Inventory receives dedicated servers, VDS, domains, virtual hosting, colocation, and IP services. The cabinet login and password stay in the agent YAML.
One source is one cabinet login. The plugin only reads the API: it does not order or change services. It opens a session (func=auth) and sends that id on later calls. The password is posted in the body, not in the URL. The session is tied to the agent IP and lasts about an hour after the last request; the next run logs in again.
If the panel has no function for a product (unknown function), that list is empty and the source still succeeds. Any other list error fails the whole source, so a partial snapshot is not sent. Deleted services (item_status = 4) are omitted, and inventory marks them inactive.
Tickets, payments, licenses, DNS records, and rack energy statistics are not collected in 0.1.0.
Provider docs: API overview, authorization.
Install
The agent must be connected to the API.
docker compose exec agent wg-flow-agent plugin install miran
# or
wg-flow-agent plugin install miranThen the local UI → Connections → miran, or YAML.
What lands in inventory
| Miran object | resource_type | Notes |
|---|---|---|
| Dedicated server | server | func=dedic. provider_resource_id = server:{id}. The name is the service domain. Public IPv4 → metadata.primary_ipv4, private addresses → metadata.private_ips. The data center is the region |
| VDS | instance | func=vds. instance:{id}. A panel VM name that differs from the domain is stored in metadata.server_name |
| Domain | domain | func=domain. provider_resource_id is the domain name (example.net). An expire date of 0000-00-00 is omitted |
| Virtual hosting | hosting | func=vhost. hosting:{id} |
| Colocation | server | func=colocation. colocation:{id}, so it does not collide with a dedicated server. metadata.product = colocation |
| IP address | network | func=ip. ip:{id}. metadata.product = additional_ip. Inventory has no separate ip type |
BILLmanager service status: 1 ordered → pending, 2 active → active, 3 suspended → stopped, 5 processing → pending. Other codes → unknown.
The cost field is stored as metadata.plan_price and metadata.billing_amount. If the row has no currency code, the plugin stores RUB. The tariff is metadata.plan_name, the OS template is metadata.image, and the end date is metadata.expire_date. The client name and the panel password are not copied into metadata.
Each collect flag can be turned off on its own. A disabled group is absent from the next successful sync, and inventory marks those rows inactive.
Several cabinets mean several sources. provider_account is your label.
YAML
plugins:
miran:
enabled: true
sources:
- id: cabinet
provider_account: "miran-main"
sync_interval_seconds: 300
api_url: "https://bill.miran.ru/billmgr"
username: "client"
password: "…"
collect_dedicated: true
collect_vds: true
collect_domains: true
collect_hosting: true
collect_colocation: true
collect_ips: trueSource fields
| Field | Required | Description |
|---|---|---|
id | yes | Log key (miran/cabinet) |
provider_account | yes | Cabinet label in inventory |
api_url | no | Default https://bill.miran.ru/billmgr |
username, password | yes | bill.miran.ru cabinet login |
collect_* | no | Default true |
sync_interval_seconds | no | Minimum 300 |
Check
wg-flow-agent status
wg-flow-agent dry-runJSON shows provider: miran. Health opens a session and calls func=dashboard.info. The password is not stored in inventory.
Common errors
| Symptom | What to check |
|---|---|
| Invalid username or password | Cabinet login pair. A password with special characters is a separate field, not a user:password string |
| Session rejected | The agent IP must be allowed to call the cabinet API. An IP allow-list blocks the session too |
| Empty server list | Services exist on this login and the matching collect_* flag is on. Deleted services (4) are hidden |
| No domains or hosting | The panel has no such function. That does not fail the source |
Access denied on a list | This login cannot call that function. The source does not send a partial snapshot |
| Duplicates with another plugin | A different provider is expected; merge them in the console |