Closed jimkring closed 6 months ago
Hello, thanks for your question! There is a labels
kwarg that can be used, here's an example:
ngrok.forward("localhost:8080", proto="labeled", labels="edge:edghts_2G...", authtoken_from_env=True)
We'll get the documentation updated to add it. Thanks again!
That's great it's already supported by the API!
A couple other points:
I created a suggestion to make this a named parameter.
It would probably make sense to add an option to the ngrok dashboard for creating a tunnel using the Python (Rust, Go, etc.) APIs, as described in the screenshot below:
@bobzilladev another thought:
labels="edge:edghts_2G..."
shows a truncated string. What's the format for passing multiple labels? e.g. is it a comma-delimited list like labels="key1:value1,key2:value2"
?Will try to answer these questions here:
labels=["key1:value1", "key2:value2"]
Hopefully that's useful, thanks for the feedback!
Yes, thanks!
In the parameters for
ngrok.forward()
(see full configuration param's list) I don't see any option to specify anedge
or otherlabel
for the tunnel.Is this possible from the python api?