Menú

Referencia de la API · Branding

Dominios del portal

branding · portal_domains · 3 operaciones

POST/v1/branding/portal-domains

Add a client portal address

branding.portal_domains.add

EscrituraIdempotenteDesde 2026-11-01

Registers an address for the organization's client portal: a full hostname, either <label>.mb-suite.com (its MB Suite subdomain: the label follows the same rules as branding.subdomain.set) or its own domain (portal.youragency.com, never mb-suite.com itself nor a hosting provider's domain). Validates that no other organization nor this organization's team access uses it, registers it with the hosting provider and saves it enabled; a custom domain starts unverified (verification_record may come back; its CNAME must point to cname.vercel-dns.com; then branding.portal_domains.verify). One subdomain and one custom domain per portal. A different MB Suite subdomain replaces the current one in this same call: the new one is registered and saved first, then the old one is released (previous_host; previous_released_from_hosting false when the hosting provider did not release it — it no longer opens the portal), so the portal is never left without an address. A second custom domain is 409 portal_domain_already_set (remove the current one first: it has its own DNS and verification). The same address again changes nothing. Fires branding.domain.added (and branding.domain.removed for a replaced subdomain). Owners and admins with edit access to Branding and to the Client Portal.

Pide confirmación: primero dry_run: true (vista previa y confirm_token, que vale 10 minutos y una sola vez), después el mismo cuerpo con confirm_token. En unas pocas, solo con ciertos datos: la descripción dice cuándo. Por qué y cómo: Vista previa y confirmación.

Alcance
branding:write
Permiso
Editar en el módulo · Solo owner, admin
Tool del MCP
branding_portal_domains_addEn la superficie completa; en la compacta, mb_execute_operation con id: "branding.portal_domains.add".

Costo declarado: hasta 32 lecturas y 1 escrituras por llamada (cuentan en el cupo diario). Toca una plataforma externa (vercel): cuenta en el cupo de operaciones externas.

Parámetros

domainstringcuerporequerido

The full hostname: portal.youragency.com (its own domain) or clients.mb-suite.com (an MB Suite subdomain).

Respuesta

domainobject
verification_recordobject | null
changedboolean
previous_hoststring
previous_released_from_hostingboolean

Errores

Ejemplo

curl -X POST "https://api.mb-suite.com/v1/branding/portal-domains" \
  -H "Authorization: Bearer $MB_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "domain": "DOMAIN",
  "dry_run": true
}'

Probar con tu API key de prueba

Con una API key de prueba el pedido va siempre a tu organización de práctica: datos de ejemplo que puedes reiniciar. En la práctica esta operación no se simula (toca otra plataforma): responde 409 sandbox_external_unavailable.

POST/v1/branding/portal-domains/verify

Verify the client portal's custom domain

branding.portal_domains.verify

EscrituraIdempotenteDesde 2026-11-01

Asks the hosting provider whether the client portal's custom domain is ready (ownership verified and the CNAME configured). When it is, the address is marked verified and starts serving the portal (fires branding.domain.verified, once); otherwise returns verified false with configured, the verification_record still to publish (if any) and message. Not found when the portal has no custom domain (subdomains need no verification). Owners and admins with edit access to Branding and to the Client Portal.

Alcance
branding:write
Permiso
Editar en el módulo · Solo owner, admin
Tool del MCP
branding_portal_domains_verifyEn la superficie completa; en la compacta, mb_execute_operation con id: "branding.portal_domains.verify".
Eventos que puede emitir
branding.domain.verified

Costo declarado: hasta 2 lecturas y 1 escrituras por llamada (cuentan en el cupo diario). Toca una plataforma externa (vercel): cuenta en el cupo de operaciones externas.

Parámetros

Sin parámetros.

Respuesta

domainobject
verifiedboolean
configuredboolean
verification_recordobject | null
messagestring | null

Errores

Ejemplo

curl -X POST "https://api.mb-suite.com/v1/branding/portal-domains/verify" \
  -H "Authorization: Bearer $MB_API_KEY"

Probar con tu API key de prueba

Con una API key de prueba el pedido va siempre a tu organización de práctica: datos de ejemplo que puedes reiniciar. En la práctica esta operación no se simula (toca otra plataforma): responde 409 sandbox_external_unavailable.

DELETE/v1/branding/portal-domains/{domain}

Remove a client portal address

branding.portal_domains.remove

IrreversibleDesde 2026-11-01

Removes one of the client portal's addresses (domain is the full hostname, exactly as branding.domains.get lists it): it stops opening the portal, it is released from the hosting provider (released_from_hosting false if another organization also has it or the provider failed: the organization is cleaned anyway) and cleared from the portal settings. An address that is not one of this organization's portal addresses is not found (nothing is ever released on someone else's behalf). The domain's DNS records are not touched. There is no trash: to undo, add it again. Outside the app it needs a dry run and its confirm_token. Fires branding.domain.removed. Owners and admins with edit access to Branding and to the Client Portal.

Pide confirmación: primero dry_run: true (vista previa y confirm_token, que vale 10 minutos y una sola vez), después el mismo cuerpo con confirm_token. En unas pocas, solo con ciertos datos: la descripción dice cuándo. Por qué y cómo: Vista previa y confirmación.

Alcance
branding:write y «Permitir eliminar» (branding:delete en OAuth)
Permiso
Editar en el módulo · Solo owner, admin
Tool del MCP
branding_portal_domains_removeEn la superficie completa; en la compacta, mb_execute_operation con id: "branding.portal_domains.remove".
Eventos que puede emitir
branding.domain.removed

Costo declarado: hasta 17 lecturas y 1 escrituras por llamada (cuentan en el cupo diario). Toca una plataforma externa (vercel): cuenta en el cupo de operaciones externas.

Parámetros

domainstringrutarequerido

The full hostname: portal.youragency.com (its own domain) or clients.mb-suite.com (an MB Suite subdomain).

Respuesta

removedtrue
domainobject
released_from_hostingboolean

Errores

Ejemplo

curl -X DELETE "https://api.mb-suite.com/v1/branding/portal-domains/{domain}" \
  -H "Authorization: Bearer $MB_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "dry_run": true
}'

Probar con tu API key de prueba

Con una API key de prueba el pedido va siempre a tu organización de práctica: datos de ejemplo que puedes reiniciar. En la práctica esta operación no se simula (toca otra plataforma): responde 409 sandbox_external_unavailable.