GET
https://jmpy.me/api/v1
/
domains
/
subdomains
List Subdomains
curl --request GET \
  --url https://jmpy.me/api/v1/domains/subdomains \
  --header 'Authorization: Bearer <token>'
{
  "subdomains": [
    {
      "id": "<string>",
      "subdomain": "<string>",
      "name": "<string>",
      "description": "<string>",
      "is_verified": true,
      "created_at": "<string>"
    }
  ],
  "total": 123
}
Retrieve a list of all jmpy.me subdomains registered to your account.

Response

subdomains
array
Array of subdomains.
total
integer
Total number of subdomains.

Request Examples

curl -X GET "https://jmpy.me/api/v1/domains/subdomains" \
  -H "Authorization: Bearer YOUR_API_KEY"

Response Examples

{
  "success": true,
  "data": {
    "subdomains": [
      {
        "id": "uuid-string",
        "subdomain": "acme",
        "name": "Acme Corp",
        "description": "Company links",
        "is_verified": true,
        "created_at": "2024-01-01T00:00:00Z"
      }
    ],
    "total": 1
  }
}

Use Cases

Fetch all active subdomains to populate a dropdown menu.
async function getSubdomainOptions() {
  const response = await fetch(
    'https://jmpy.me/api/v1/domains/subdomains',
    { headers: { 'Authorization': 'Bearer YOUR_API_KEY' } }
  );
  const result = await response.json();
  
  // Transform for dropdown
  return result.data.subdomains.map(sub => ({
    label: `${sub.subdomain}.jmpy.me`,
    value: sub.subdomain
  }));
}