Skip to content

feat: sites.create takes a kind for redirect hosts - #17

Merged
gp42-ops merged 1 commit into
mainfrom
redirect-hosts
Nov 12, 2026
Merged

gp42-ops merged 1 commit into
mainfrom
redirect-hosts

Conversation

@gp42-ops

Copy link
Copy Markdown
Member

Summary

client.sites.create takes kind, for the public API's redirect hosts:

const { siteId } = await client.sites.create({ subdomain: "go", domain: "example.com", kind: "redirect" });

A redirect host is a hostname on one of the organization's own custom domains that serves only its redirect rules, set with client.sites.redirects. It takes no files, and doesn't count toward the plan's site limit. The API refuses:

  • a redirect host on a shared domain, with 409 CustomDomainRequired;
  • the 51st redirect host of an organization, with 403 RedirectHostLimitReached;
  • deploy() and startUpload() for a redirect host, with 409 RedirectHostHasNoFiles.

Site gains kind ("site" or "redirect"), and the SiteKind type is exported. Omitting kind creates a site, as before. The README describes redirect hosts under Sites.

The API side is hostsmith/hostsmith's redirect-hosts branch. The MCP server's create_site needs this release.

Type of change

  • fix: bug fix
  • feat: new feature
  • feat!: / BREAKING CHANGE: breaking change
  • docs: / chore: / refactor: / test: / perf: non-shipping

Checklist

  • npm run typecheck passes
  • npm test passes
  • Tests added or updated for behavior changes
  • No access tokens, secrets, or internal hostnames in the diff
  • Commit messages follow Conventional Commits

Related issues

kind "redirect" creates a redirect host: a hostname on one of the organization's own custom domains that serves only redirect rules and takes no uploads. Site gains kind, and SiteKind is exported.
@gp42-ops
gp42-ops marked this pull request as ready for review November 12, 2026 07:45
@gp42-ops
gp42-ops merged commit 77a742b into main Nov 12, 2026
1 check passed
@gp42-ops
gp42-ops deleted the redirect-hosts branch November 12, 2026 07:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant