Code:
from pyngrok import ngrok
public_url = ngrok.connect(
log_stdout=True, log_file="ngrok.log", log_format="json", log_level="debug", proto="tcp", addr="8080"
)
print(public_url)
while True:
pass
I found this on the internet but it aint working, well its starting the server but its not logging anything, how do i make it log things?
thanks
I'm not familiar with that approach but in general, you probably want to do it a little bit differently. Check out the local ngrok API - https://ngrok.com/docs/ngrok-agent/api#list-captured-requests - which will let you capture all the requests in JSON for logging, replay, or whatever.
~ an ngrok employee