Skip to content

feat: show tunnel public url in connector popover - #8

Merged
aiedwardyi merged 2 commits into
mainfrom
feat/tunnel-url
Jul 19, 2026
Merged

aiedwardyi merged 2 commits into
mainfrom
feat/tunnel-url

Conversation

@aiedwardyi

@aiedwardyi aiedwardyi commented Jul 19, 2026

Copy link
Copy Markdown
Owner

Detect the local cloudflared quick tunnel and show its public URL with a copy button in the connector popover.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, you can upgrade your account or add credits to your account and enable them for code reviews in your settings.

@coderabbitai

coderabbitai Bot commented Jul 19, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

You’ve reached a temporary PR review limit under our Fair Usage Limits Policy.

Your recent review volume is higher than typical usage, so adaptive limits are currently applied.

Next review available in: 38 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 7641b9c4-f820-4488-930d-2c438186c4ec

📥 Commits

Reviewing files that changed from the base of the PR and between 39e143a and 01f8abf.

📒 Files selected for processing (2)
  • public/index.html
  • src/daemon.js
📝 Walkthrough

Walkthrough

The bridge API now detects quick-tunnel hostnames and returns a publicUrl. The connector UI tracks, conditionally displays, and copies that URL while resetting stale values during connector opening.

Changes

Public bridge URL

Layer / File(s) Summary
Discover public bridge URL
src/daemon.js
The daemon probes configured quick-tunnel ports, normalizes valid hostname responses, adds publicUrl to bridge details, and awaits the asynchronous response in /api/bridge.
Render and copy public URL
public/index.html
Connector state and rendering now support the public URL row, reset stale values during opening, and copy the displayed URL through the new button.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Sequence Diagram(s)

sequenceDiagram
  participant ConnectorUI
  participant BridgeAPI
  participant QuickTunnel
  ConnectorUI->>BridgeAPI: GET /api/bridge
  BridgeAPI->>QuickTunnel: Probe /quicktunnel on configured ports
  QuickTunnel-->>BridgeAPI: Return hostname
  BridgeAPI-->>ConnectorUI: Return bridge details with publicUrl
  ConnectorUI->>ConnectorUI: Render and copy public URL
Loading

Possibly related PRs


Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@public/index.html`:
- Line 641: Update the button element identified by id mcpPublicCopy to include
an explicit type="button" attribute, satisfying the button-type-require check
while preserving its existing Copy behavior.

In `@src/daemon.js`:
- Around line 288-332: The probeQuickTunnelPort function only enforces socket
inactivity, allowing trickling responses to remain pending indefinitely. Add a
wall-clock timer for each request using quickTunnelProbeMs, destroying the
request and resolving null when it expires; clear the timer when the request
completes or errors, and preserve the existing single-resolution behavior.
- Around line 307-317: Update the hostname resolution logic in the
`/quicktunnel` probing flow before `publicUrl` is constructed: authenticate the
reported hostname against the tunnel process started by AgentLoop, rather than
trusting any localhost response. Accept only the verified tunnel hostname;
otherwise resolve null and omit `publicUrl`, preventing credentials from being
sent to an attacker-controlled host.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 896a4c8d-986a-4d87-87f5-76548b4eb06b

📥 Commits

Reviewing files that changed from the base of the PR and between 572447c and 39e143a.

📒 Files selected for processing (2)
  • public/index.html
  • src/daemon.js
📜 Review details
🧰 Additional context used
🪛 HTMLHint (1.9.2)
public/index.html

[warning] 641-641: The type attribute must be present on elements.

(button-type-require)

🔇 Additional comments (1)
public/index.html (1)

910-914: LGTM!

Also applies to: 1081-1081, 1147-1149, 1160-1163, 1745-1745

Comment thread public/index.html Outdated
Comment thread src/daemon.js
Comment thread src/daemon.js Outdated
@aiedwardyi

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 39e143abf2

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread public/index.html Outdated
Comment thread src/daemon.js

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds support for detecting a local Cloudflared “quick tunnel” and surfacing its public MCP endpoint in the dashboard connector popover, alongside the existing local connector URL.

Changes:

  • Added localhost probing of Cloudflared quick-tunnel endpoints in the daemon and exposed a publicUrl field via /api/bridge.
  • Updated the dashboard connector popover to display a “Public URL” row with a copy action and token-masking behavior when the token is hidden.
  • Adjusted /api/bridge handler to await the now-async bridgeDetails() call.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
src/daemon.js Probes quick-tunnel ports and includes a derived public MCP URL in the bridge details API response.
public/index.html Renders the public tunnel URL in the connector popover and adds a copy button + masking logic in the UI.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/daemon.js
Comment thread public/index.html
@aiedwardyi
aiedwardyi merged commit f97fd74 into main Jul 19, 2026
2 checks passed
@aiedwardyi
aiedwardyi deleted the feat/tunnel-url branch July 19, 2026 12:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants