name: html-portal description: Use when the user needs to preview a single HTML file generated on a remote machine, especially from Codex, SSH, iOS, or Windows app workflows. Creates a temporary token-protected preview URL with HTML Portal, verifies it, reports expiry and cleanup commands, and avoids exposing directories or sensitive HTML.
HTML Portal
Use this skill when an HTML file exists on a remote/dev machine and the user needs to view it from another device, Codex App, or a mobile browser.
Rules
- Only preview a single
.htmlfile. - Never serve a project root or directory.
- Prefer local preview unless the user asks for phone, Codex App, remote viewing, or
--share. - For public sharing, use HTML Portal's random path, query token, and TTL.
- Do not share if secret scan fails unless the user explicitly accepts the risk.
- For public preview,
<script>requires explicit user approval and--allow-scripts. - Always report the stop command and expiration time.
- Clean up preview processes when the user asks or when the preview is no longer needed.
Workflow
- Check the tool and input:
html-portal doctor
html-portal inspect <file.html> --json
- For local-only preview:
html-portal <file.html> --json
- For phone / Codex App preview:
html-portal <file.html> --share --ttl 30m --json
- Verify the URL:
curl -I '<preview-url>'
- Report:
Preview URL: ...
Expires: ...
Stop: html-portal stop <id>
Security: secret scan pass/fail, scripts none/detected, public true/false
- Cleanup:
html-portal stop <id>
html-portal cleanup
Ask First
Ask before sharing publicly if:
- The file appears to contain secrets, credentials, customer data, logs, or private reports.
- The HTML contains
<script>or external scripts. - The user asks to expose a directory.
- TTL is longer than the safe default.