К содержанию
TelegaFirst

Для AI-агентов: markdown этой страницы — /docs/mcp-site.mdиндекс документации — /llms.txt

MCP: site

Обновлено

Определения инструментов. Обновляйте tools/list после изменения прав. required_scopes: ALL.

check_direct_app

Check the Telegram Direct Link of the business bot: the mini app with short name `miniapp` that the owner creates in @BotFather (Mini Apps → Create Direct Link) so the launch window shows the «Allow messages» checkbox. Telegram is asked through a service account whether `miniapp` exists and whether it and the Main App open `web_app_url`. On a full match `has_direct_app` turns true and every Telegram mini-app link of the business becomes `t.me/{bot}/miniapp?startapp`; otherwise it is false and `fix` names the next step: create_direct_link, set_direct_link_url (paste `web_app_url`), set_main_app_url; no_bot / no_address / no_supergroup — nothing to check yet; check_unavailable — no service account answered, retry later; retry_later — Telegram is asked at most once a minute per business, the answer is the stored flag. Run it again after the owner changes the bot in @BotFather.

Scopes (ALL): ["site:write"]. Risk: "write".

Вход, результат и права

Get where the business main mini app opens: `web_app_url` (https://{origin}/miniapp — the address of the mini app home, the URL a bot menu button opens as a web app and the one @BotFather takes as the Main App; null while the business has no https address) and `launch` per channel (telegram / max / vk): the link that opens the main mini app inside that messenger. A channel the business has not connected has `url: null` and a `reason`. Take both from this tool: never build the address or a launch link yourself and never ask the operator for them. 0-cost read.

Scopes (ALL): ["site:read"]. Risk: "read".

Вход, результат и права

secret_delete

Delete a stored secret by name. REQUIRES THE OWNER'S CONFIRMATION — same two-call handshake as `secret_put`: once without `action_id` to ask, then again with the returned `action_id` once they confirm. Anything still configured to use that name stops working at once, and the value cannot be recovered — the name simply becomes free again.

Scopes (ALL): ["site:write"]. Risk: "destructive".

Вход, результат и права

secret_list

List the NAMES of the secrets stored for the business's hosted site, with when each was stored and last rotated. Values are never returned — there is no parameter that changes that. Use it to check whether a name exists before wiring a form handler or relay to it. 0-cost read.

Scopes (ALL): ["site:read"]. Risk: "read".

Вход, результат и права

secret_put

Store a NEW secret for the business's hosted site (an API token its pages or form handlers call out with). REQUIRES THE OWNER'S CONFIRMATION: call it once without `action_id` and you get back `pending_approval` with an `action_id` — the owner is asked in Telegram to confirm storing a secret under this name. Once they confirm, call again with the SAME `action_id` and the same value, and it is stored. Nothing is kept between the two calls. The value is encrypted at rest and is NEVER returned by any tool — not by this one, not by `secret_list`. A name that already holds a live secret is a conflict: use `secret_rotate` to change a value, or `secret_delete` first to re-use the name.

Scopes (ALL): ["site:write"]. Risk: "write".

Вход, результат и права

secret_rotate

Replace the value stored under an existing secret name. REQUIRES THE OWNER'S CONFIRMATION — same two-call handshake as `secret_put`: once without `action_id` to ask, then again with the returned `action_id` and the value once they confirm. The name does not change (it cannot — it is bound into the encryption of the value). Everything already wired to this name picks up the new value on its next use, so rotate only when the old credential is being retired.

Scopes (ALL): ["site:write"]. Risk: "write".

Вход, результат и права

site_checkout_key

Get the PUBLIC key the business's checkout page uses to start an order from its own website. Paste the returned key into the page — it is designed to sit in page source where every visitor can read it, and it can do exactly one thing: start a checkout for a form the business configured. It can read nothing. Calling this again REPLACES the key: the previous one keeps working for 24 hours so an already-published page does not break before you redeploy it. The key is shown ONCE — it cannot be retrieved later, only replaced. Which website addresses may use it is set per form (`allowed_origins`), not here.

Scopes (ALL): ["site:write"]. Risk: "write".

Вход, результат и права

site_delete_page

Delete ONE page of the published site by its `id` (from `site_list_pages`) without re-uploading the site: the page stops being served and every other file stays exactly as deployed. Files the page used (images, styles) are kept; publish the bundle again to drop them. The page keeps its id, so publishing a file at the same path later brings it back under the same `id`. Repeating the call is safe and answers `already_deleted`. Deleting the home page `index.html` is allowed: the site address then opens the catalog. Refused for protected platform files and for a page another file declares in its upload `references`; to remove the whole site use `site_prepare_delete`. To take a page offline without deleting it, use `site_pages_set_visibility`.

Scopes (ALL): ["site:write"]. Risk: "destructive".

Вход, результат и права

site_egress_origin_list

List the exact origins (`https://<host>`) that form destinations of kind webhook or external_api may be delivered to. A destination whose origin is not listed is refused when the form is declared and is never sent. Returns `{ origins, missing_origins }`: `missing_origins` are origins your declared forms send to that the list lacks — those submissions are not sent until you add the origin with `site_egress_origin_set`. 0-cost read.

Scopes (ALL): ["site:read"]. Risk: "read".

Вход, результат и права

site_egress_origin_set

Replace the WHOLE list of exact origins form destinations may be delivered to (not a patch: send every origin to keep, at most 50). Each origin is `https://` plus a public DNS host, e.g. `https://crm.example.com\` — no other port, user, wildcard, path, query or fragment; it is stored lower-cased, IDN as punycode. Call it before `site_form_declare` names a webhook or external_api destination on a new origin. Dropping an origin a declared form still sends to is refused: redeclare that form without the destination first. Returns the stored list and `missing_origins`, as `site_egress_origin_list` does.

Scopes (ALL): ["site:write"]. Risk: "write".

Вход, результат и права

site_execute_delete

Delete the deployed site identified by a matching prepared scenario. Call this tool only after final human confirmation of the prepared scenario.

Scopes (ALL): ["site:write"]. Risk: "destructive".

Вход, результат и права

site_fetch_file

Read one UTF-8 file from a deployed site bundle. Use `site_get_manifest` first to discover its exact path and checksum. This returns page/source text for editing; platform access-policy configuration is intentionally not readable through this tool. After editing, request a default merge ticket through `site_request_upload` for the changed files, PUT them and call `site_publish`; omitted files are preserved. Use explicit replace only for an intentional complete snapshot.

Scopes (ALL): ["site:read"]. Risk: "read".

Вход, результат и права

site_form_declare

Declare a form BEFORE BUILDING PAGES; returns `client_slug`, `code`, `submit_snippet` (OFFICIAL: `<form data-tgf-form="{code}">` + your fields + `<script src="/widget/forms.v1.js" async>`) and `mini_app_links`. Paste it; NEVER hand-write the POST or use `no-cors` (opaque: no result shows). It runs `after_submit`, emits `tgf:submitted`/`tgf:failed`/`tgf:refused`. Keep its `tgf_consent_pd` box (unticked, required, absolute `/consent`, `/privacy` links): unticked, it sends nothing. `id` UPDATES (same address); omit for a NEW form. It sets the ENVELOPE, not fields. `destinations`: `{"kind":"telegram","topic_id":<id>}`, `{"kind":"webhook","url":"https://…"}`, `{"kind":"external_api","url":"https://…","method":"POST","header_name":"X-Api-Key","secret_name":"<secret name>"}`; first add its origin via `site_egress_origin_set`. `allowed_origins`: the site's addresses. Stop with `enabled: false`. `after_submit`: `{"mode":"auto"}` (your `title`/`text`, bot button, opt. `button_label`) or `{"mode":"redirect","redirect_url":"https://…"}` (own hosts or `allowed_origins`). `variants`: step `step_id` + exactly one of `when` (`funnel_mode: "deterministic"`, first by `sort`) or `hint` (`"ai_agent"`); `when`: non-empty ARRAY (≤20 predicates, all match): `[{"op":"eq","field":"band","value":"high"}]` (`op`: eq, neq, gt, gte, lt, lte, contains, in with `values`, exists, absent; OR = another entry); `default_step_id` if none matches. `manager_follow_up: true` adds an AI Manager reply; `call_operator_on_submit`/`calls_operator` call an operator. `funnel_outcome: "checkout"` + `catalog_id`: FREE item → order on submit; PAID or anything missing → bot-chat checkout; answers and `hidden` fields → operator-only order comment. NOT a patch: an omitted optional RESETS, except `order_mode`, `catalog_id` (kept). `submission_schema` (`[{"name":"phone","type":"tel","required":true,"label":"Phone"}]`) refuses a submission breaking it; names = your inputs. Give every field a human `label`; metadata → `hidden: true`.

Scopes (ALL): ["site:write"]. Risk: "write".

Вход, результат и права

site_gate_list

List the access rules of the business: `id`, `path`, `block` (null = the whole page), `mode`, `is_active`, `any_of` (conditions; a password shows its `password` name, never its value), `login_path` (null = the default sign-in page) and `revision`. The `id` is what `site_gate_remove` takes. 0-cost read.

Scopes (ALL): ["site:read"]. Risk: "read".

Вход, результат и права

site_gate_remove

Delete one access rule (`id` from `site_gate_list`). What it closed is open to everyone at once unless another rule still covers it. Returns `{id, removed, unprojected_hosts}`. To pause a rule and keep it, use `site_gate_set` with `is_active: false`.

Scopes (ALL): ["site:write"]. Risk: "destructive".

Вход, результат и права

site_gate_set

Open a page, or one block of it, only to part of the audience. Effective at once. One rule per TARGET: `path`, a mask of the served path (`/pricing.html`, `/lessons/`, `/lessons/*`; `*` only last; `/pricing` does not match `pricing.html`), plus optional `block` (lowercase letters, digits, -). Setting a target again updates it. A block is the bundle file `__telegafirst/blocks/{block}.html`; the page holds `<div data-tgf-block="{block}">teaser</div>` and `<script src="/widget/blocks.v1.js" async></script>`; a script inside a block does not run. Without `block` the whole page is closed and a visitor who fails goes to sign-in (`mode` ignored). `any_of` (1-10) = who gets in; ONE of the conditions opens it: `{"kind":"product","catalog_id":5}` (bought it; a 0-price product counts); `{"kind":"subscription"}` (any live paid subscription; with `catalog_id`: to that item, trial and 0-price too); `{"kind":"channel"}` (a member of the public channel, on the visitor's own messenger: Telegram, MAX or VK; none connected there = no way in from it); `{"kind":"signed_in"}` (any signed-in customer of this business); `{"kind":"segment","saved_segment_id":12}` or `{"kind":"segment","filter":{...}}` (filter of `describe_segment_axes`: include groups minus `exclude`; axes partner/referrals_of, inviter/invited_by, manual = user list); `{"kind":"password","password":"acme"}` (made with `site_password_set`). Where masks overlap, the most specific one decides and overrides the general (`/kp/acme/*` over `/kp/*`). The platform keeps passwords; never put one in HTML or JS. The sign-in page is ready; your own = `login_path` (open, outside every closed mask) + `/widget/gate.v1.js` (`tgf.gate.unlock(password)`). Recipes: several clients = nested masks, `/kp/*` [shared], `/kp/acme/*` [acme, shared]; data for the admitted = a JSON file under the closed mask; a third-party API key = `secret_put`. `mode`: `hide` (default) or `lock`. `is_active:false` pauses. `unprojected_hosts`>0: some edges catch up soon.

Scopes (ALL): ["site:write"]. Risk: "write".

Вход, результат и права

site_gate_tree

Show the access rules on the published pages of one host (`host` from `site_list_pages`): each page with the `rules` whose masks reach it (the most specific mask decides) and its `blocks`, each block with its `rules`; `unmatched` are rules that close no published page of THIS host. That does not make a rule useless: rules act on every host of the business and on any file, so an unmatched rule may close a page of another host or files that are not pages (video, PDF). Do not remove a rule because it is unmatched; the verdict for the whole business is the `SITE_ACCESS_RULE_PATH_GONE` warning of `site_publish`. Read this before `site_gate_set` to see what is already closed. 0-cost read.

Scopes (ALL): ["site:read"]. Risk: "read".

Вход, результат и права

site_get_analytics

Read the analytics for this business's own hosted site over a window of N UTC days, the last of which is TODAY. It returns total page views, tab sessions (the historical `views_unique` / `unique` names do NOT mean unique visitors), bot-link clicks, pages, referrer hostnames, UTM labels and click actions. Past days come from the nightly rollup; today is incomplete and is read from the live event buffer (`today` names that date; `live_stats: false` means the buffer could not be read, so today's zero is unknown, not "no visits"). `/x/` and `/x/index.html` are one page. Costs no tokens. Omit `days` for 7 days; requests above 30 days are bounded to 30. Optionally pass `page_path` to report one published page. There is intentionally no `host` argument: this call is scoped to the authenticated tenant's own site.

Scopes (ALL): ["site:read"]. Risk: "read".

Вход, результат и права

site_get_manifest

Read the deployed site bundle manifest for one site host (from `site_list_pages`). It returns every path with its MD5 checksum and byte size, plus `manifest_digest`. To edit one page, read this first, then use `site_fetch_file` for that page; when you publish, still declare and stage the COMPLETE bundle. The existing checksum Delta Sync writes only files whose bytes changed, so unchanged pages are not re-uploaded. 0-cost read.

Scopes (ALL): ["site:read"]. Risk: "read".

Вход, результат и права

site_list_pages

List the business's site pages and the addresses its site can be published at. `hosts` names every host the site tools accept as `host`: the platform site address (`kind: "platform"`, available without any setup) and each custom domain added with `domain_add_request` (`live: false` until it serves visitors). `pages` lists every page ever published (`kind: "site"`) followed by the storefront pages the platform serves on the platform host (`kind: "storefront"`: /shop, /events, /booking, /bio, /terms, /privacy and one page per active product, event, bookable resource and enabled form, each with its `section` and `title`; `id: null`, no visibility or delete controls; `storefront_truncated` names a section cut at its cap), each with its `id` — the number `site_pages_set_visibility`, `site_page_preview` and `site_delete_page` take — its host, bundle `path`, and `public_url`, the address visitors open; `public_url` is null while the page is not served, and `reason` then says why (`owner_hidden`, `moderation_blocked`, `domain_not_active`, `not_published`). Each `kind: "site"` page also carries `links` (`web`, `universal`, one `mini_app` per connected channel, each with a `description`): give the owner those links. While the page is not served `links` is empty and `links_recovery` says what to do. `mini_app_links` (per page, storefront pages included) and `mini_app_home` open the page or the home AS the Telegram/MAX/VK mini app, for a broadcast text; copy them, never build one yourself; `url: null` comes with a `reason`. `site_pages_set_visibility`, `site_delete_page` and `site_page_preview` take only `kind: "site"` pages. `protected` pages (platform files) cannot be hidden or deleted one by one; the home page `index.html` is an ordinary page. 0-cost read.

Scopes (ALL): ["site:read"]. Risk: "read".

Вход, результат и права

site_page_nudge_get

Read the nudge setting of one published, visible site page (`id` from `site_list_pages`). A nudge is a timed follow-up: a person opened the page as a mini app and `delay_minutes` later has reached no goal. Returns `is_enabled`, `delay_minutes`, `step_id` (the funnel step sent first), `ai_enabled` and `ai_prompt` (the AI Manager task that follows the step), `goal_link_codes` and `ai_available` (false: the plan has no AI Manager). A page with no setting reads as disabled defaults. The platform storefront pages (shop, events, booking) are not site pages and cannot carry a nudge. 0-cost read.

Scopes (ALL): ["site:read"]. Risk: "read".

Вход, результат и права

site_page_nudge_set

Replace the nudge setting of one published, visible site page (`id` from `site_list_pages`); the whole setting, not a patch. When a person opens the page as a mini app and reaches no goal within `delay_minutes` (5 to 10080, seven days), the business sends them the funnel step `step_id` (a step `id`, or null for none) and then, when `ai_enabled`, the AI Manager works on `ai_prompt` (1 to 2000 characters; the task for the AI, not a message to the person). One wait per person at a time: a second open of the page restarts the timer; another page replaces the wait only when its nudge is on with a step or AI and the person is not in the 30-day cooldown of that page. After a nudge the same person gets none on that page for 30 days. A goal ends the wait: any form submission of the person, any order, event registration or booking, and a tap on a goal link (`goal_link_codes`: codes of links the business owns, bare or `dl_…`, at most 50) set on any page of the business. A running wait uses the setting as it was when it started; but if the nudge is off or the page hidden or unpublished when the timer fires, the wait is cancelled (`superseded`, nothing sent). A live dialog does not block the step; the AI stays silent while an operator holds the chat and is skipped without tokens. `ai_enabled` needs a plan with the AI Manager. Refusals: SITE_NUDGE_PAGE_NOT_ELIGIBLE, SITE_NUDGE_DELAY_OUT_OF_RANGE, SITE_NUDGE_STEP_NOT_FOUND, SITE_NUDGE_GOAL_LINK_NOT_FOUND, SITE_NUDGE_AI_NOT_ON_PLAN, SITE_NUDGE_AI_PROMPT_REQUIRED. Stop with `is_enabled: false`: pending waits are cancelled when their timer fires.

Scopes (ALL): ["site:write"]. Risk: "write".

Вход, результат и права

site_page_nudge_stats

Read the nudge funnel of one site page (`id` from `site_list_pages`) over [`from`, `to`), ISO-8601 instants; default the 30 days ending now. Returns `visits` (mini-app opens of the page), `cooldown_visits` (opens inside the 30-day cooldown), `waits` started, `pending`, `goal_before_fire` (a goal reached before the timer: no nudge sent), `fired`, `goal_after_fire` (fired waits whose person reached a goal afterwards), `superseded` (replaced by a wait on another page, or cancelled because the nudge was turned off or the page hidden or unpublished), `failed` (the timer fired and the channel refused), and `step_outcomes` / `ai_outcomes`: what the step and the AI did for waits whose timer fired (fired or failed; superseded excluded): sent, skipped_*, not_configured, failed. 0-cost read.

Scopes (ALL): ["site:read"]. Risk: "read".

Вход, результат и права

site_page_preview

Open a private preview of a tenant page (`id` from `site_list_pages`). Returns a short-lived opaque URL on an isolated origin, using stored content without publishing it.

Scopes (ALL): ["site:write"]. Risk: "read".

Вход, результат и права

site_pages_set_visibility

Show or hide existing site pages by their tenant page ids (`ids`, each an `id` from `site_list_pages`). Root and system pages are protected. Returns one result per selected page. Hidden desire survives redeployment and tariff restore; showing does not override a moderation block. On the free plan, showing a page succeeds only while the public set stays within 10 pages and 10 MiB; otherwise the result is `free_tier_limit`: hide another page first.

Scopes (ALL): ["site:write"]. Risk: "write".

Вход, результат и права

site_password_list

List the passwords of the business: `id`, `name`, `note` (who it is for), `remember_days`, `changed_at`, `used_by_rules` (how many rules name it) and `sections` (the masks of those rules). Never the password itself: `site_password_reveal` shows one by `name`. A rule names the password, `site_password_remove` takes the `id`. 0-cost read.

Scopes (ALL): ["site:read"]. Risk: "read".

Вход, результат и права

site_password_remove

Delete a password by `id` (from `site_password_list`). Refused with `SITE_PASSWORD_IN_USE` while a rule names it: first change those rules with `site_gate_set` or remove them with `site_gate_remove`. Everyone who entered with it is signed out, and the value cannot be restored. Returns `{id, removed}`.

Scopes (ALL): ["site:write"]. Risk: "destructive".

Вход, результат и права

site_password_reveal

Show the value of one password of the business by `name` (from `site_password_list`): to remind a client of it, or to put it into a letter to the customer the section is for. Returns `{id, name, password}`. Every call is recorded in the audit log (who asked, which password; never the value). Send it to the person it is for, not into a page, a script, a bundle file or a broadcast. To change it, `site_password_set`.

Scopes (ALL): ["site:read"]. Risk: "read".

Вход, результат и права

site_password_set

Create a named password for closed sections of the site, or change it: the same `name` takes the new password and signs out everyone who entered with the old one. `name`: lowercase letters, digits, - (`acme`, `course-2026`); `password`: 8-128 characters; `remember_days`: 1-365 (default 30), how long a visitor stays signed in on a device; `note`: up to 200 characters, who it is for (`Acme LLC, Ivan`), absent keeps it, null clears it. A rule names it in `site_gate_set` `any_of`: `{"kind":"password","password":"acme"}`; one password can serve many rules, and signing in once opens every section that accepts it. The platform keeps the password: no listing shows it, `site_password_reveal` reads it back when the owner needs it. Pass it to the audience yourself and keep it out of HTML, JS and bundle files. Up to 100 per business, on every plan. Returns `{password:{id,name,note,remember_days,changed_at,used_by_rules,sections},created,unprojected_hosts}`.

Scopes (ALL): ["site:write"]. Risk: "write".

Вход, результат и права

site_prepare_delete

Prepare deletion of the whole deployed site at one site host (to remove a single page use `site_delete_page`). The preparation freezes the current manifest checksum for human review and does not delete anything. Show the returned scenario to a human, then call `site_execute_delete` only if they give final confirmation.

Scopes (ALL): ["site:write"]. Risk: "write".

Вход, результат и права

site_publish

Step 2 of publishing: after every upload PUT completed, make the files under `upload_id` live at the ticket's `host`. The ticket's mode and base apply: `merge` keeps omitted files, the bio page, assets and references; `replace` removes omitted files. Only changed files are written, `index.html` LAST, so no half-swapped site shows. A publish never changes access rules (`site_gate_set`). A changed base or access policy is 409 SITE_BUNDLE_STALE: request a new ticket; another host is refused. 409 SITE_SOURCE_FETCH_PENDING: files with a `source` are still being fetched; nothing is published and the ticket is kept: repeat this call with the same `upload_id` in a few seconds. Plan size limits are checked on the uploaded bytes; an HTML tag over the fixed size is SITE_HTML_TAG_TOO_LARGE (`path`, `tag`, `attr` in `details`): move the data into its own file and publish again. A refusal leaves the live site as it was. Returns written/removed/identical paths, `manifest_digest` and `page_urls` (HTML pages that went live): `url` and `links` (web, universal, mini_app, each with a `description`); give the owner every link. If empty, follow `page_urls_reason` and `page_urls_recovery`. Publishing consumes the upload: request a new ticket to publish again. `attribution_snippet` is a one-line <script>: paste it into every page that links to the business's bot, or visitors arrive anonymous and the business cannot tell which page brought them (links still work, nothing looks broken). `warnings` (never a refusal, the site is live) carry `code`, `path`, `message`, `recovery`, `found`: follow `recovery` (`FORM_POST_NO_CORS`, `FORM_WITHOUT_OFFICIAL_SCRIPT`, `FORM_WITHOUT_PD_CONSENT`); `KNOWN_TRACKER_GATED` is information only (held back until the visitor accepts the cookie banner); an access rule on a page that is gone: publish it again or `site_gate_remove`. A counter it cannot hold back refuses the publish: SITE_TRACKER_NOT_GATEABLE. Fix the other warnings and publish again; official form markup: `site_form_declare`.

Scopes (ALL): ["site:write"]. Risk: "write".

Вход, результат и права

site_request_upload

Step 1 of publishing a static site. `host`: one of `hosts` from `site_list_pages` (platform site address or a verified custom domain). Declare each file (path, size_bytes, content_type, optional `references`) for an upload URL per file and an `upload_id`. `mode: merge` (default) changes only the declared files; `replace` is a full snapshot that removes omitted files. Access rules: `site_gate_set`, never a bundle. PUT each file with exactly its declared byte length, then call `site_publish` with `host` and `upload_id`. A file with a `source` is fetched by the server (`status: fetching`): do not PUT it. `site_publish` is the status check: 409 SITE_SOURCE_FETCH_PENDING loses nothing, call it again; a failed source is named by file and code, fix it and request a new ticket. 409 SITE_BUNDLE_STALE: the site changed meanwhile; request a new ticket. Bundle = the HTML pages plus each file they use (image, video, font, CSS, JS) as its own file. A large `data:` URL in a tag is SITE_HTML_TAG_TOO_LARGE: move it into a file linked relatively and listed in the page's `references`. A video over the plan's size is SITE_VIDEO_TOO_LARGE: compress it or embed from a video host. The daily upload budget (MINT_QUOTA_EXCEEDED; MINT_QUOTA_UNAVAILABLE: retry after `retry_after`) and plan limits are checked before any URL. Platform-owned on every site address: /auth, /checkout, /cart, /account, /refund, /l, /f, /product, /events, /booking, /widget, /miniapp, /api, /__telegafirst, /_fragments/ (bar consent-banner.html) and all below. A file there or a service-worker script (sw.js, *-sw.js) refuses the whole bundle with SITE_PATH_RESERVED. A file at /, /shop, /bio, /privacy, /terms or /refunds replaces that platform page; /shop is always the catalog. Legal pages (/terms, /privacy, /legal, the consent documents) are the platform's: link the first three in every footer; never write your own offer, policy or consent pages. Add the `attribution_snippet` <script> from `site_publish` to pages that link to the bot.

Scopes (ALL): ["site:write"]. Risk: "write".

Вход, результат и права

site_widgets_list

List the platform scripts your site pages may load: forms.v1.js (submit your own HTML form), miniapp.v1.js (close the messenger window, remember the visitor's steps), referral.v1.js (buttons that open the business under the inviter), blocks.v1.js (gated blocks). Each item has file, path, purpose, embed (the smallest working inclusion), hooks (the attributes, globals and events the script reads or emits) and, when something must exist first, needs. Put the <script src> in the page and your own code in a FILE of the bundle: an inline <script> is reported by site_publish as a warning and is what a stricter page policy will block. The scripts are served by the site's own address under /widget/, so a relative src works on every host of the site. 0-cost read.

Scopes (ALL): ["site:read"]. Risk: "read".

Вход, результат и права