unjs / untun

🚇 Tunnel your local HTTP(s) server to the world! powered by Cloudflare Quick Tunnels.
Other
1.01k stars 16 forks source link

api mode cannot get url #33

Closed allmors closed 8 months ago

allmors commented 8 months ago

Environment

Reproduction

// ESM
import { startTunnel } from "untun";

const tunnel = await startTunnel({ port: 3000 });

Describe the bug

Unable to display tun url using api call image

Additional context

No response

Logs

No response

Additional notes:

I saw in the source code that getURL returned an asynchronous one. Generally speaking, it is not a bug. It should be that the key method is not explained in the document. https://github.com/unjs/untun/blob/f7e80e3c1157ed38368d5ee6e19855458c229ba1/src/tunnel.ts#L69