CorefinityCorefinityDocs
Open the Control PanelControl Panel
Sites · 9 of 23

corestack_site_attach_domain_check

Check hosts before attaching them.

Scope readNo secrets returnedCoreCluster
On this page

When to use it

Check hosts before attaching them to a site or environment: per host whether its DNS reaches the platform, what point_dns would change, and advice. Nothing is changed.

blockers lists what refuses the attach whatever DNS says, each {reason, message} exactly as corestack_site_attach_domain would answer it; empty when nothing does. Today that is a WordPress production site's platform plugins: platform_plugins_off while they are turned off, until they are turned back on with corestack_site_platform_plugins_set (enabled: true); platform_plugins_applying while they are back on but the platform has not finished applying that, until the task that tool answered completes (if it failed, turning them on again starts it afresh). Tell the person the message before you attach.

proxied_unconfirmed lists each host Cloudflare proxies in a zone the Control Panel cannot look behind (no Cloudflare connection, or a zone it does not reach), in the order asked: {host, confirmable, challenge_path: {ok, code, status, note}, verification: {name, value, found, state}}; empty when there are none. Such a host stays ok: false, because its record was not checked. challenge_path is whether the certificate check gets through Cloudflare to the platform: ok: true it does; ok: false it cannot, so the host is not confirmable and note says what to change in Cloudflare; ok: null is advice that may not matter (a cached or blocked answer, no answer). verification is the proof that the person controls the host: a TXT record named name holding value (their company's value; null when this Control Panel cannot check proofs yet), found once it is there, and state one of found, missing, unreadable or unavailable. A host is confirmable only when its path does not block and its proof is found; the host's problems say what to add or change. Before you attach with proxied_records_checked, ask the person to add any missing TXT record and to check in Cloudflare that each record points at the host's expected_ip.

Magento store choices run the same checks as the attach: unknown or inactive stores and an unreadable store list are refused before anything starts. A valid store check also returns warnings, such as base URLs on another address.

After the store change completes and before changing DNS:

Request / with corestack_site_smoke_test, setting host to the store domain. The final URL must be on that store's base_url host from corestack_site_magento_stores_list (the domain itself, or its bare or www form when the base URL uses it), and the title must be that store's. Magento redirects to the store's base URL; a redirect to any other host means its base URL points elsewhere. GraphQL picks its store from the Store header, so it cannot prove a domain's store.

Ask for it

Prompt
Using the Corefinity MCP server, call corestack_site_attach_domain_check with site_id 4211, hosts ["example.co.uk","guns.example.co.uk","www.guns.example.co.uk"], canonical example.co.uk, aliases [{"host":"guns.example.co.uk","serve":"storefront","store":{"code":"guns","type":"website"},"base_url":true},{"host":"www.guns.example.co.uk","serve":"storefront","store":{"code":"guns","type":"website"}}], default_store {"code":"base","type":"website"}. (Check hosts before attaching them.) Tell me what it returned.

Inputs

aliasesarray of objects

How non-canonical hosts are served on Shopware and Magento 2. Up to 9 items.

host: One of hosts, other than canonical, listed once. store: {code, type} where type is website or store; required for storefront. base_url: Choose this address for the store's base URLs; at most one per store.

Fields of each item
base_urlboolean
hoststringRequired

Up to 253 characters.

servestringRequired
redirectstorefront
storeobject
Fields
codestringRequired

Up to 32 characters.

typestringRequired
websitestore
canonicalstringRequired

The host the row is served on; one of hosts. Up to 253 characters.

default_storeobject or null

{code, type} for the default store, or null for Magento's default.

Fields
codestringRequired

Up to 32 characters.

typestringRequired
websitestore
hostsarray of stringsRequired

The hosts to attach (production row: the site's domain or its www form among them; any other row: never it). A host-migration copy made under its provider's platform host may leave that name out (it can never point here). Up to 10 items.

site_idintegerRequired

At least 1.

wwwstring

Which form the other redirects to; default from canonical.

wwwbare

Example call

tools/call
{
  "name": "corestack_site_attach_domain_check",
  "arguments": {
    "site_id": 4211,
    "hosts": [
      "example.co.uk",
      "guns.example.co.uk",
      "www.guns.example.co.uk"
    ],
    "canonical": "example.co.uk",
    "aliases": [
      {
        "host": "guns.example.co.uk",
        "serve": "storefront",
        "store": {
          "code": "guns",
          "type": "website"
        },
        "base_url": true
      },
      {
        "host": "www.guns.example.co.uk",
        "serve": "storefront",
        "store": {
          "code": "guns",
          "type": "website"
        }
      }
    ],
    "default_store": {
      "code": "base",
      "type": "website"
    }
  }
}

If it is refused

ReasonWhat to do
provisioningThe site is still being created; wait for corestack_site_provisioning_get to finish.
managed_elsewhereAnother control panel manages this site, so use that control panel for it. This is refused before anything else about the site, as in the Control Panel and the API. Nothing was done.
invalid_argumentsOn hosts ("<install>.wpengine.com is WP Engine's own address, which can never point here: attach the site's own domains."): a host under a migration provider's own platform domain (*.wpengine.com, *.wpenginepowered.com, *.cloudwaysapps.com); the site's own domain is the one exception. Nothing is written.
store_hostsThe site has platform store addresses managed by staff; contact support.
store_requiredaliases.<n>.store identifies the missing choice. Choose a Magento website or store view for every serving alias.
store_unknownaliases.<n>.store or default_store identifies the choice. Read the stores again and choose a code Magento lists.
store_inactivealiases.<n>.store or default_store identifies the choice. Switch the store view on in Magento or choose another.
store_code_formataliases.<n>.store or default_store identifies the choice. Use a Magento code with lower-case letters, digits or underscores, up to 32 characters.
store_host_not_servedFirst add the address as an alias that shows its own store.
store_mapping_foreignThe store rules are managed outside the Control Panel; contact support.
store_mapping_unreadableThe existing store rules cannot be read safely; contact support.
nginx_rules_not_adoptedThe site's rules are not ready for this change; contact support.
nginx_rules_lockedThe site's rules are locked; contact support.
nginx_invalidThe site's existing rules need attention before the store can be changed.
upstream_unavailableMagento's stores could not be read; try again in a moment.
tenant_mismatchThe object does not exist or the token may not see it. Check the id.
scope_requiredThe token lacks a scope this call needs. Open the link in the answer to add it, then call again.
pin_refusedThe grant is limited to chosen clusters, sites or environments, and this call is outside them. Open the link in the answer to widen it.
rate_limitedToo many calls. Wait for the number of seconds the answer names.
temporarily_unavailableThe Control Panel could not answer just now. Nothing was started; try again shortly.
internal_errorSomething went wrong on our side. Quote the trace id to support.

Store-choice refusals name aliases.<n>.store, where n is the alias's zero-based position, or aliases when its host cannot be matched. Default-store refusals name default_store.

The same task elsewhere

Was this helpful?
Open in ClaudeOpen in ChatGPT