HF PanelDocsv1.0.0

API: search

Search accounts, domains, mailboxes, databases, invoices, tickets, resellers, IP addresses and screens with one request.

GET /v1/search is for administrator and reseller tokens. It returns the same groups as the search box in the panel. A reseller's token finds only their own customers' data. A customer's token gets 403.

bash
A=https://api.yourdomain.com:2087/v1
H="Authorization: Bearer hf_xxx"
curl -s -H "$H" "$A/search?q=sarah&limit=5"
Query field Meaning
q what to look for, at least 2 characters (otherwise 422)
limit hits per group, 1–20, 5 by default
json
{
    "ok": true,
    "query": "sarah",
    "groups": [
        {
            "group": "accounts",
            "label": "Accounts",
            "hits": [
                {"id": "12", "title": "sarahbakes", "detail": "sarah@example.com", "url": "/accounts?q=sarahbakes"}
            ]
        }
    ]
}

Groups with no hits are left out. The groups are screens, accounts, domains, mailboxes, databases, invoices, tickets, resellers and ips.