Modulify

Check a free subdomain is available

check_subdomain_available

Checks whether a free modulify.website subdomain is still available before change_subdomain takes it.

POST /v1/check_subdomain_availableScopesites:readRead only

The subdomain is the free public web address of a site, which it holds whether or not it is published, and it is how a site is identified everywhere else. The check answers ok when the subdomain is free and not-ok when it is taken.

The answer is platform-wide, since a subdomain is unique across all of Modulify, and the projectId only says which workspace the call belongs to. Testing the address the site already holds reports it as taken, because the check cannot tell that the holder is you, and a deleted site keeps holding its subdomain.

A subdomain that breaks the rules change_subdomain applies, on length, characters or reserved words, comes back as an error rather than as taken. See Your free web address.

Request

Call it with a POST to https://api.modulify.ai/v1/check_subdomain_available, sending the inputs below as a JSON object. The token needs the sites:read scope.

It only reads and changes nothing, so retrying it is safe.

curl -X POST https://api.modulify.ai/v1/check_subdomain_available \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"projectId":"PROJECT_ID","subdomain":"SUBDOMAIN"}'

Over MCP, the same method is the check_subdomain_available tool.

Inputs

Input Type Required Description
projectId string Yes The site id. It only decides which workspace the call belongs to.
subdomain string Yes The subdomain to test, without the .modulify.website suffix.

Response

Every call answers with the JSON envelope of success, message, data, code and version. data holds the result described above, and on a method that returns a total, count carries it. The response headers carry the call's X-Request-Id and what is left of your per-minute budget in X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset. Errors explains every status code a call can answer with.