Get a user's domains

This endpoint gets the domains connected to a user's vPanel account.

HTTP Endpoint

POST https://panel.myownfreehost.net/xml-api/getuserdomains.php

Usage

⚠️

Make sure to use the username given by vPanel (e.g hname_12345678) here and not the username you set yourself.

cURL


curl -X POST -u username:password -d "api_user=username&api_key=password&username=hname_12345678" "https://panel.myownfreehost.net/xml-api/getuserdomains.php"

Python


import requests
from requests.auth import HTTPBasicAuth
url = "https://panel.myownfreehost.net/xml-api/getuserdomains.php"
data = {'api_user': 'username', 'api_key': 'password', 'username': 'hname_12345678'}
response = requests.post(url, params=data, auth=HTTPBasicAuth('username', 'password'))
print(response.text)

Response

💡

The above request returns a list/array structured like this:


[["ACTIVE","subdomain.example.com"]]