Access and gates
set_gate_access
Choose the site's primary gate: public, email_capture, allowlist, password, or paid. Classic modes take only the credentials their mode allows; 'paid' selects an existing site-wide paid offer and takes no credentials and no expiry. Switching is non-destructive: the unselected side is preserved and dormant. The gate password is a DIFFERENT secret from an offer's purchase password, and the gate allowlist is separate from an offer's approved-email list (set_paid_access_requirements). Takes effect on the next publish_site. Changes no design: use set_gate_draft_design. Editor role.
Behaviour
- Effect
- Destructive. It can remove or overwrite existing data.
- Repeat calls
- Idempotent. Repeating the same call produces the same result.
- Plan
- Available on every plan, including free.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| request_id | string | Yes | Unique mutation ID. Reuse only to replay identical arguments. |
| site_id | uuid | Yes | Site UUID from list_sites. |
| mode | enum public | email_capture | allowlist | password | paid | Yes | Gate visitors meet: public, email_capture (soft gate), allowlist (verified email against a typed list), password (one shared password), or paid (buy access via a site-wide offer, which must already exist). Switching is non-destructive. |
| expires_at | timestamp or null | No | Future ISO-8601 timestamp when the room closes for everyone; null clears, omit keeps. |
| lead_fields | array of object | No | FULL REPLACEMENT of the lead-capture fields; omit keeps, [] clears. Max 6; email is implicit. |
| require_email_verification | boolean | No | email_capture only: require a magic-link click before access. |
| allowlist | array of object | No | FULL REPLACEMENT of the allowlist, lowercased server-side; domain matches exactly (no subdomains). [] clears. |
| password | string | No | Plaintext classic gate password, hashed server-side, never returned. Not the offer purchase password. |
Returns
| Name | Type |
|---|---|
| site_id | uuid |
| mode | enum public | email_capture | allowlist | password |
| primary_gate | enum public | email_capture | allowlist | password | paid |
| paid_site_scope | enum or null entire_site | except_homepage |
| publish_required | boolean |
| has_password | boolean |
| allowlist_count | integer |
| lead_fields_count | integer |
| require_email_verification | boolean or null |
| expires_at | timestamp or null |
| idempotency_replay | false |
Using it
set_gate_access is called by an AI assistant connected to Sentway over MCP, not by hand. Point the assistant at the Sentway MCP endpoint and complete the OAuth flow, and the tool becomes available in the same session as the other 56 Sentway tools. See connecting over MCP.