---
title: "Set or clear the app platform subdomain - the '<subdomain>.<base domain>' host Fine Structure already serves the app on"
method: POST
path: "/api/mcp/tools/set_app_subdomain"
tags: ["tools"]
---

# Set or clear the app platform subdomain - the '<subdomain>.<base domain>' host Fine Structure already serves the app on

`POST /api/mcp/tools/set_app_subdomain`

## Request

- Base URL: `https://finestructure.ai`
- URL: `https://finestructure.ai/api/mcp/tools/set_app_subdomain`
- Auth: HTTP bearer

Set or clear the app platform subdomain - the '<subdomain>.<base domain>' host Fine Structure already serves the app on. Runs the same ownership, format, reserved-name and uniqueness checks as the Studio subdomain field because it calls the same model function. Replacing a subdomain takes effect immediately and creates NO redirect: the previous name stops resolving to this app and is released for anyone to claim. Pass an empty subdomain to clear it. For a domain the user owns, use add_custom_domain instead.

## Request body

- object
  - `app_id` string, required: The app ID
  - `subdomain` string, required: Subdomain label: 3-32 characters, lowercase letters, digits and hyphens, no leading or trailing hyphen, not a reserved platform name. Empty string clears the subdomain.

## Response `200`

Tool executed successfully

- ToolResult
  - `ok` boolean, required
  - `tool` string, required
  - `result` object, required

## Other responses

- `400`: Invalid arguments for this tool
- `401`: Missing or invalid bearer token
- `402`: Not enough credits on the account
- `403`: Token scope does not permit this tool
- `404`: Unknown tool name
- `429`: Rate limit exceeded, retry after the indicated delay
- `500`: Internal error while executing the tool

---

[API](https://skmtc.dev/finestructure/apis/fine-structure-api.md) · [All operations](https://skmtc.dev/finestructure/apis/fine-structure-api/llms.txt) · [OpenAPI document](https://skmtc.dev/finestructure/apis/fine-structure-api/revisions/02c50ed5fd70?raw)
