---
title: "Check if a subdomain is valid and available"
method: GET
path: "/api/v1/sites/availability"
tags: ["sites"]
---

# Check if a subdomain is valid and available

`GET /api/v1/sites/availability`

## Request

- Base URL: `https://slatehut.com`
- URL: `https://slatehut.com/api/v1/sites/availability`
- Auth: HTTP bearer

Same rules as the editor: normalization, reserved names, length 2–48, uniqueness. Empty `q` returns `{ normalized: "", available: true }`.

## Query parameters

- `q` string

## Response `200`

normalized slug and whether it can be registered

- SubdomainAvailabilityResponse
  - `normalized` string, required: Sanitized slug (empty string if `q` was empty)
  - `available` boolean, required: False if reserved, taken, or invalid length after normalize

## Other responses

- `400`: Validation or conflict error
- `401`: Missing or invalid credentials

---

[API](https://skmtc.dev/slatehut/apis/slatehut-api.md) · [All operations](https://skmtc.dev/slatehut/apis/slatehut-api/llms.txt) · [OpenAPI document](https://skmtc.dev/slatehut/apis/slatehut-api/revisions/32dae277550c?raw)
