@ngrok/ngrok 0.0.6 → 0.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/CONTRIBUTING.md +4 -4
  3. package/Cargo.toml +5 -2
  4. package/README.md +11 -11
  5. package/docs/.nojekyll +1 -0
  6. package/docs/assets/highlight.css +71 -0
  7. package/docs/assets/main.js +58 -0
  8. package/docs/assets/search.js +1 -0
  9. package/docs/assets/style.css +1280 -0
  10. package/docs/classes/NgrokHttpTunnel.html +189 -0
  11. package/docs/classes/NgrokHttpTunnelBuilder.html +440 -0
  12. package/docs/classes/NgrokLabeledTunnel.html +177 -0
  13. package/docs/classes/NgrokLabeledTunnelBuilder.html +130 -0
  14. package/docs/classes/NgrokSession.html +142 -0
  15. package/docs/classes/NgrokSessionBuilder.html +303 -0
  16. package/docs/classes/NgrokTcpTunnel.html +189 -0
  17. package/docs/classes/NgrokTcpTunnelBuilder.html +199 -0
  18. package/docs/classes/NgrokTlsTunnel.html +189 -0
  19. package/docs/classes/NgrokTlsTunnelBuilder.html +235 -0
  20. package/docs/classes/UpdateRequest.html +92 -0
  21. package/docs/functions/consoleLog.html +73 -0
  22. package/docs/functions/listen.html +74 -0
  23. package/docs/functions/listenable.html +72 -0
  24. package/docs/functions/loggingCallback.html +91 -0
  25. package/docs/index.html +129 -0
  26. package/docs/modules.html +79 -0
  27. package/examples/ngrok-http-full.js +18 -8
  28. package/examples/ngrok-http-minimum.js +1 -3
  29. package/examples/ngrok-labeled.js +2 -4
  30. package/examples/ngrok-tcp.js +4 -6
  31. package/examples/ngrok-tls.js +6 -8
  32. package/examples/ngrok-typescript.ts +64 -0
  33. package/examples/ngrok-winston.js +24 -0
  34. package/index.d.ts +193 -41
  35. package/index.js +114 -27
  36. package/package.json +25 -17
  37. package/post-build.js +23 -16
  38. package/scripts/gc-node-drop.js +42 -0
  39. package/scripts/gc-rust-drop.js +47 -0
  40. package/src/http.rs +64 -42
  41. package/src/lib.rs +10 -0
  42. package/src/logging.rs +134 -0
  43. package/src/session.rs +239 -63
  44. package/src/tcp.rs +2 -1
  45. package/src/tls.rs +10 -18
  46. package/src/tunnel.rs +146 -22
  47. package/src/tunnel_builder.rs +46 -28
  48. package/trailer.d.ts +9 -0
  49. package/trailer.js +111 -25
  50. package/tsconfig.json +6 -0
  51. package/examples/ngrok-get-socket.js +0 -13
@@ -0,0 +1,142 @@
1
+ <!DOCTYPE html><html class="default" lang="en"><head><meta charSet="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>NgrokSession | @ngrok/ngrok</title><meta name="description" content="Documentation for @ngrok/ngrok"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script async src="../assets/search.js" id="search-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os"</script><header class="tsd-page-toolbar">
2
+ <div class="tsd-toolbar-contents container">
3
+ <div class="table-cell" id="tsd-search" data-base="..">
4
+ <div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><path d="M15.7824 13.833L12.6666 10.7177C12.5259 10.5771 12.3353 10.499 12.1353 10.499H11.6259C12.4884 9.39596 13.001 8.00859 13.001 6.49937C13.001 2.90909 10.0914 0 6.50048 0C2.90959 0 0 2.90909 0 6.49937C0 10.0896 2.90959 12.9987 6.50048 12.9987C8.00996 12.9987 9.39756 12.4863 10.5008 11.6239V12.1332C10.5008 12.3332 10.5789 12.5238 10.7195 12.6644L13.8354 15.7797C14.1292 16.0734 14.6042 16.0734 14.8948 15.7797L15.7793 14.8954C16.0731 14.6017 16.0731 14.1267 15.7824 13.833ZM6.50048 10.499C4.29094 10.499 2.50018 8.71165 2.50018 6.49937C2.50018 4.29021 4.28781 2.49976 6.50048 2.49976C8.71001 2.49976 10.5008 4.28708 10.5008 6.49937C10.5008 8.70852 8.71314 10.499 6.50048 10.499Z" fill="var(--color-text)"></path></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div>
5
+ <div class="field">
6
+ <div id="tsd-toolbar-links"></div></div>
7
+ <ul class="results">
8
+ <li class="state loading">Preparing search index...</li>
9
+ <li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">@ngrok/ngrok</a></div>
10
+ <div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><rect x="1" y="3" width="14" height="2" fill="var(--color-text)"></rect><rect x="1" y="7" width="14" height="2" fill="var(--color-text)"></rect><rect x="1" y="11" width="14" height="2" fill="var(--color-text)"></rect></svg></a></div></div></header>
11
+ <div class="container container-main">
12
+ <div class="col-8 col-content">
13
+ <div class="tsd-page-title">
14
+ <ul class="tsd-breadcrumb">
15
+ <li><a href="../modules.html">@ngrok/ngrok</a></li>
16
+ <li><a href="NgrokSession.html">NgrokSession</a></li></ul>
17
+ <h1>Class NgrokSession</h1></div>
18
+ <section class="tsd-panel tsd-comment">
19
+ <div class="tsd-comment tsd-typography"><p>An ngrok session.</p>
20
+ </div></section>
21
+ <section class="tsd-panel tsd-hierarchy">
22
+ <h4>Hierarchy</h4>
23
+ <ul class="tsd-hierarchy">
24
+ <li><span class="target">NgrokSession</span></li></ul></section><aside class="tsd-sources">
25
+ <ul>
26
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L118">index.d.ts:118</a></li></ul></aside>
27
+ <section class="tsd-panel-group tsd-index-group">
28
+ <section class="tsd-panel tsd-index-panel">
29
+ <details class="tsd-index-content tsd-index-accordion" open><summary class="tsd-accordion-summary tsd-index-summary">
30
+ <h5 class="tsd-index-heading uppercase" role="button" aria-expanded="false" tabIndex=0><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><path d="M1.5 5.50969L8 11.6609L14.5 5.50969L12.5466 3.66086L8 7.96494L3.45341 3.66086L1.5 5.50969Z" fill="var(--color-text)"></path></svg> Index</h5></summary>
31
+ <div class="tsd-accordion-details">
32
+ <section class="tsd-index-section">
33
+ <h3 class="tsd-index-heading">Constructors</h3>
34
+ <div class="tsd-index-list"><a href="NgrokSession.html#constructor" class="tsd-index-link tsd-kind-constructor tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><rect fill="var(--color-icon-background)" stroke="#4D7FFF" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12" id="icon-512-path"></rect><path d="M11.898 16.1201C11.098 16.1201 10.466 15.8961 10.002 15.4481C9.53803 15.0001 9.30603 14.3841 9.30603 13.6001V9.64012C9.30603 8.85612 9.53803 8.24012 10.002 7.79212C10.466 7.34412 11.098 7.12012 11.898 7.12012C12.682 7.12012 13.306 7.34812 13.77 7.80412C14.234 8.25212 14.466 8.86412 14.466 9.64012H13.386C13.386 9.14412 13.254 8.76412 12.99 8.50012C12.734 8.22812 12.37 8.09212 11.898 8.09212C11.426 8.09212 11.054 8.22412 10.782 8.48812C10.518 8.75212 10.386 9.13212 10.386 9.62812V13.6001C10.386 14.0961 10.518 14.4801 10.782 14.7521C11.054 15.0161 11.426 15.1481 11.898 15.1481C12.37 15.1481 12.734 15.0161 12.99 14.7521C13.254 14.4801 13.386 14.0961 13.386 13.6001H14.466C14.466 14.3761 14.234 14.9921 13.77 15.4481C13.306 15.8961 12.682 16.1201 11.898 16.1201Z" fill="var(--color-text)" id="icon-512-text"></path></svg><span>constructor</span></a>
35
+ </div></section>
36
+ <section class="tsd-index-section">
37
+ <h3 class="tsd-index-heading">Methods</h3>
38
+ <div class="tsd-index-list"><a href="NgrokSession.html#closeTunnel" class="tsd-index-link tsd-kind-method tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><rect fill="var(--color-icon-background)" stroke="#FF4DB8" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12" id="icon-2048-path"></rect><path d="M9.162 16V7.24H10.578L11.514 10.072C11.602 10.328 11.674 10.584 11.73 10.84C11.794 11.088 11.842 11.28 11.874 11.416C11.906 11.28 11.954 11.088 12.018 10.84C12.082 10.584 12.154 10.324 12.234 10.06L13.122 7.24H14.538V16H13.482V12.82C13.482 12.468 13.49 12.068 13.506 11.62C13.53 11.172 13.558 10.716 13.59 10.252C13.622 9.78 13.654 9.332 13.686 8.908C13.726 8.476 13.762 8.1 13.794 7.78L12.366 12.16H11.334L9.894 7.78C9.934 8.092 9.97 8.456 10.002 8.872C10.042 9.28 10.078 9.716 10.11 10.18C10.142 10.636 10.166 11.092 10.182 11.548C10.206 12.004 10.218 12.428 10.218 12.82V16H9.162Z" fill="var(--color-text)" id="icon-2048-text"></path></svg><span>close<wbr/>Tunnel</span></a>
39
+ <a href="NgrokSession.html#httpEndpoint" class="tsd-index-link tsd-kind-method tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>http<wbr/>Endpoint</span></a>
40
+ <a href="NgrokSession.html#labeledTunnel" class="tsd-index-link tsd-kind-method tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>labeled<wbr/>Tunnel</span></a>
41
+ <a href="NgrokSession.html#tcpEndpoint" class="tsd-index-link tsd-kind-method tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>tcp<wbr/>Endpoint</span></a>
42
+ <a href="NgrokSession.html#tlsEndpoint" class="tsd-index-link tsd-kind-method tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>tls<wbr/>Endpoint</span></a>
43
+ </div></section></div></details></section></section>
44
+ <section class="tsd-panel-group tsd-member-group">
45
+ <h2>Constructors</h2>
46
+ <section class="tsd-panel tsd-member tsd-kind-constructor tsd-parent-kind-class"><a id="constructor" class="tsd-anchor"></a>
47
+ <h3 class="tsd-anchor-link"><span>constructor</span><a href="#constructor" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none" id="icon-anchor-a"></path><path d="M10 14a3.5 3.5 0 0 0 5 0l4 -4a3.5 3.5 0 0 0 -5 -5l-.5 .5" id="icon-anchor-b"></path><path d="M14 10a3.5 3.5 0 0 0 -5 0l-4 4a3.5 3.5 0 0 0 5 5l.5 -.5" id="icon-anchor-c"></path></svg></a></h3>
48
+ <ul class="tsd-signatures tsd-kind-constructor tsd-parent-kind-class">
49
+ <li class="tsd-signature tsd-anchor-link" id="constructor.new_NgrokSession">new <wbr/>Ngrok<wbr/>Session<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="NgrokSession.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSession</a><a href="#constructor.new_NgrokSession" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
50
+ <li class="tsd-description">
51
+ <h4 class="tsd-returns-title">Returns <a href="NgrokSession.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSession</a></h4></li></ul></section></section>
52
+ <section class="tsd-panel-group tsd-member-group">
53
+ <h2>Methods</h2>
54
+ <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class"><a id="closeTunnel" class="tsd-anchor"></a>
55
+ <h3 class="tsd-anchor-link"><span>close<wbr/>Tunnel</span><a href="#closeTunnel" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
56
+ <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
57
+ <li class="tsd-signature tsd-anchor-link" id="closeTunnel.closeTunnel-1">close<wbr/>Tunnel<span class="tsd-signature-symbol">(</span>id<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#closeTunnel.closeTunnel-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
58
+ <li class="tsd-description">
59
+ <div class="tsd-comment tsd-typography"><p>Close a tunnel with the given ID.</p>
60
+ </div>
61
+ <div class="tsd-parameters">
62
+ <h4 class="tsd-parameters-title">Parameters</h4>
63
+ <ul class="tsd-parameter-list">
64
+ <li>
65
+ <h5>id: <span class="tsd-signature-type">string</span></h5></li></ul></div>
66
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources">
67
+ <ul>
68
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L128">index.d.ts:128</a></li></ul></aside></li></ul></section>
69
+ <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class"><a id="httpEndpoint" class="tsd-anchor"></a>
70
+ <h3 class="tsd-anchor-link"><span>http<wbr/>Endpoint</span><a href="#httpEndpoint" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
71
+ <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
72
+ <li class="tsd-signature tsd-anchor-link" id="httpEndpoint.httpEndpoint-1">http<wbr/>Endpoint<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="NgrokHttpTunnelBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokHttpTunnelBuilder</a><a href="#httpEndpoint.httpEndpoint-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
73
+ <li class="tsd-description">
74
+ <div class="tsd-comment tsd-typography"><p>Start building a tunnel backing an HTTP endpoint.</p>
75
+ </div>
76
+ <h4 class="tsd-returns-title">Returns <a href="NgrokHttpTunnelBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokHttpTunnelBuilder</a></h4><aside class="tsd-sources">
77
+ <ul>
78
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L120">index.d.ts:120</a></li></ul></aside></li></ul></section>
79
+ <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class"><a id="labeledTunnel" class="tsd-anchor"></a>
80
+ <h3 class="tsd-anchor-link"><span>labeled<wbr/>Tunnel</span><a href="#labeledTunnel" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
81
+ <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
82
+ <li class="tsd-signature tsd-anchor-link" id="labeledTunnel.labeledTunnel-1">labeled<wbr/>Tunnel<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="NgrokLabeledTunnelBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokLabeledTunnelBuilder</a><a href="#labeledTunnel.labeledTunnel-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
83
+ <li class="tsd-description">
84
+ <div class="tsd-comment tsd-typography"><p>Start building a labeled tunnel.</p>
85
+ </div>
86
+ <h4 class="tsd-returns-title">Returns <a href="NgrokLabeledTunnelBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokLabeledTunnelBuilder</a></h4><aside class="tsd-sources">
87
+ <ul>
88
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L126">index.d.ts:126</a></li></ul></aside></li></ul></section>
89
+ <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class"><a id="tcpEndpoint" class="tsd-anchor"></a>
90
+ <h3 class="tsd-anchor-link"><span>tcp<wbr/>Endpoint</span><a href="#tcpEndpoint" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
91
+ <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
92
+ <li class="tsd-signature tsd-anchor-link" id="tcpEndpoint.tcpEndpoint-1">tcp<wbr/>Endpoint<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="NgrokTcpTunnelBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokTcpTunnelBuilder</a><a href="#tcpEndpoint.tcpEndpoint-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
93
+ <li class="tsd-description">
94
+ <div class="tsd-comment tsd-typography"><p>Start building a tunnel backing a TCP endpoint.</p>
95
+ </div>
96
+ <h4 class="tsd-returns-title">Returns <a href="NgrokTcpTunnelBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokTcpTunnelBuilder</a></h4><aside class="tsd-sources">
97
+ <ul>
98
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L122">index.d.ts:122</a></li></ul></aside></li></ul></section>
99
+ <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class"><a id="tlsEndpoint" class="tsd-anchor"></a>
100
+ <h3 class="tsd-anchor-link"><span>tls<wbr/>Endpoint</span><a href="#tlsEndpoint" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
101
+ <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
102
+ <li class="tsd-signature tsd-anchor-link" id="tlsEndpoint.tlsEndpoint-1">tls<wbr/>Endpoint<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="NgrokTlsTunnelBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokTlsTunnelBuilder</a><a href="#tlsEndpoint.tlsEndpoint-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
103
+ <li class="tsd-description">
104
+ <div class="tsd-comment tsd-typography"><p>Start building a tunnel backing a TLS endpoint.</p>
105
+ </div>
106
+ <h4 class="tsd-returns-title">Returns <a href="NgrokTlsTunnelBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokTlsTunnelBuilder</a></h4><aside class="tsd-sources">
107
+ <ul>
108
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L124">index.d.ts:124</a></li></ul></aside></li></ul></section></section></div>
109
+ <div class="col-4 col-menu menu-sticky-wrap menu-highlight">
110
+ <div class="tsd-navigation settings">
111
+ <details class="tsd-index-accordion"><summary class="tsd-accordion-summary">
112
+ <h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><path d="M4.93896 8.531L12 15.591L19.061 8.531L16.939 6.409L12 11.349L7.06098 6.409L4.93896 8.531Z" fill="var(--color-text)"></path></svg> Settings</h3></summary>
113
+ <div class="tsd-accordion-details">
114
+ <div class="tsd-filter-visibility">
115
+ <h4 class="uppercase">Member Visibility</h4><form>
116
+ <ul id="tsd-filter-options">
117
+ <li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li>
118
+ <li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-private" name="private"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Private</span></label></li>
119
+ <li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li>
120
+ <li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></form></div>
121
+ <div class="tsd-theme-toggle">
122
+ <h4 class="uppercase">Theme</h4><select id="theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div>
123
+ <nav class="tsd-navigation primary">
124
+ <details class="tsd-index-accordion" open><summary class="tsd-accordion-summary">
125
+ <h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><path d="M4.93896 8.531L12 15.591L19.061 8.531L16.939 6.409L12 11.349L7.06098 6.409L4.93896 8.531Z" fill="var(--color-text)"></path></svg> Modules</h3></summary>
126
+ <div class="tsd-accordion-details">
127
+ <ul>
128
+ <li><a href="../modules.html">@ngrok/ngrok</a>
129
+ <ul></ul></li></ul></div></details></nav>
130
+ <nav class="tsd-navigation secondary menu-sticky">
131
+ <ul>
132
+ <li class="current tsd-kind-class"><a href="NgrokSession.html" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-class)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6" id="icon-128-path"></rect><path d="M11.898 16.1201C11.098 16.1201 10.466 15.8961 10.002 15.4481C9.53803 15.0001 9.30603 14.3841 9.30603 13.6001V9.64012C9.30603 8.85612 9.53803 8.24012 10.002 7.79212C10.466 7.34412 11.098 7.12012 11.898 7.12012C12.682 7.12012 13.306 7.34812 13.77 7.80412C14.234 8.25212 14.466 8.86412 14.466 9.64012H13.386C13.386 9.14412 13.254 8.76412 12.99 8.50012C12.734 8.22812 12.37 8.09212 11.898 8.09212C11.426 8.09212 11.054 8.22412 10.782 8.48812C10.518 8.75212 10.386 9.13212 10.386 9.62812V13.6001C10.386 14.0961 10.518 14.4801 10.782 14.7521C11.054 15.0161 11.426 15.1481 11.898 15.1481C12.37 15.1481 12.734 15.0161 12.99 14.7521C13.254 14.4801 13.386 14.0961 13.386 13.6001H14.466C14.466 14.3761 14.234 14.9921 13.77 15.4481C13.306 15.8961 12.682 16.1201 11.898 16.1201Z" fill="var(--color-text)" id="icon-128-text"></path></svg><span>Ngrok<wbr/>Session</span></a>
133
+ <ul>
134
+ <li class="tsd-kind-constructor tsd-parent-kind-class"><a href="NgrokSession.html#constructor" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-512-path"></use><use href="#icon-512-text"></use></svg>constructor</a></li>
135
+ <li class="tsd-kind-method tsd-parent-kind-class"><a href="NgrokSession.html#closeTunnel" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>close<wbr/>Tunnel</a></li>
136
+ <li class="tsd-kind-method tsd-parent-kind-class"><a href="NgrokSession.html#httpEndpoint" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>http<wbr/>Endpoint</a></li>
137
+ <li class="tsd-kind-method tsd-parent-kind-class"><a href="NgrokSession.html#labeledTunnel" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>labeled<wbr/>Tunnel</a></li>
138
+ <li class="tsd-kind-method tsd-parent-kind-class"><a href="NgrokSession.html#tcpEndpoint" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>tcp<wbr/>Endpoint</a></li>
139
+ <li class="tsd-kind-method tsd-parent-kind-class"><a href="NgrokSession.html#tlsEndpoint" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>tls<wbr/>Endpoint</a></li></ul></li></ul></nav></div></div>
140
+ <div class="container tsd-generator">
141
+ <p>Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></div>
142
+ <div class="overlay"></div><script src="../assets/main.js"></script></body></html>
@@ -0,0 +1,303 @@
1
+ <!DOCTYPE html><html class="default" lang="en"><head><meta charSet="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>NgrokSessionBuilder | @ngrok/ngrok</title><meta name="description" content="Documentation for @ngrok/ngrok"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script async src="../assets/search.js" id="search-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os"</script><header class="tsd-page-toolbar">
2
+ <div class="tsd-toolbar-contents container">
3
+ <div class="table-cell" id="tsd-search" data-base="..">
4
+ <div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><path d="M15.7824 13.833L12.6666 10.7177C12.5259 10.5771 12.3353 10.499 12.1353 10.499H11.6259C12.4884 9.39596 13.001 8.00859 13.001 6.49937C13.001 2.90909 10.0914 0 6.50048 0C2.90959 0 0 2.90909 0 6.49937C0 10.0896 2.90959 12.9987 6.50048 12.9987C8.00996 12.9987 9.39756 12.4863 10.5008 11.6239V12.1332C10.5008 12.3332 10.5789 12.5238 10.7195 12.6644L13.8354 15.7797C14.1292 16.0734 14.6042 16.0734 14.8948 15.7797L15.7793 14.8954C16.0731 14.6017 16.0731 14.1267 15.7824 13.833ZM6.50048 10.499C4.29094 10.499 2.50018 8.71165 2.50018 6.49937C2.50018 4.29021 4.28781 2.49976 6.50048 2.49976C8.71001 2.49976 10.5008 4.28708 10.5008 6.49937C10.5008 8.70852 8.71314 10.499 6.50048 10.499Z" fill="var(--color-text)"></path></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div>
5
+ <div class="field">
6
+ <div id="tsd-toolbar-links"></div></div>
7
+ <ul class="results">
8
+ <li class="state loading">Preparing search index...</li>
9
+ <li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">@ngrok/ngrok</a></div>
10
+ <div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><rect x="1" y="3" width="14" height="2" fill="var(--color-text)"></rect><rect x="1" y="7" width="14" height="2" fill="var(--color-text)"></rect><rect x="1" y="11" width="14" height="2" fill="var(--color-text)"></rect></svg></a></div></div></header>
11
+ <div class="container container-main">
12
+ <div class="col-8 col-content">
13
+ <div class="tsd-page-title">
14
+ <ul class="tsd-breadcrumb">
15
+ <li><a href="../modules.html">@ngrok/ngrok</a></li>
16
+ <li><a href="NgrokSessionBuilder.html">NgrokSessionBuilder</a></li></ul>
17
+ <h1>Class NgrokSessionBuilder</h1></div>
18
+ <section class="tsd-panel tsd-comment">
19
+ <div class="tsd-comment tsd-typography"><p>The builder for an ngrok session.</p>
20
+ </div></section>
21
+ <section class="tsd-panel tsd-hierarchy">
22
+ <h4>Hierarchy</h4>
23
+ <ul class="tsd-hierarchy">
24
+ <li><span class="target">NgrokSessionBuilder</span></li></ul></section><aside class="tsd-sources">
25
+ <ul>
26
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L13">index.d.ts:13</a></li></ul></aside>
27
+ <section class="tsd-panel-group tsd-index-group">
28
+ <section class="tsd-panel tsd-index-panel">
29
+ <details class="tsd-index-content tsd-index-accordion" open><summary class="tsd-accordion-summary tsd-index-summary">
30
+ <h5 class="tsd-index-heading uppercase" role="button" aria-expanded="false" tabIndex=0><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><path d="M1.5 5.50969L8 11.6609L14.5 5.50969L12.5466 3.66086L8 7.96494L3.45341 3.66086L1.5 5.50969Z" fill="var(--color-text)"></path></svg> Index</h5></summary>
31
+ <div class="tsd-accordion-details">
32
+ <section class="tsd-index-section">
33
+ <h3 class="tsd-index-heading">Constructors</h3>
34
+ <div class="tsd-index-list"><a href="NgrokSessionBuilder.html#constructor" class="tsd-index-link tsd-kind-constructor tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><rect fill="var(--color-icon-background)" stroke="#4D7FFF" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12" id="icon-512-path"></rect><path d="M11.898 16.1201C11.098 16.1201 10.466 15.8961 10.002 15.4481C9.53803 15.0001 9.30603 14.3841 9.30603 13.6001V9.64012C9.30603 8.85612 9.53803 8.24012 10.002 7.79212C10.466 7.34412 11.098 7.12012 11.898 7.12012C12.682 7.12012 13.306 7.34812 13.77 7.80412C14.234 8.25212 14.466 8.86412 14.466 9.64012H13.386C13.386 9.14412 13.254 8.76412 12.99 8.50012C12.734 8.22812 12.37 8.09212 11.898 8.09212C11.426 8.09212 11.054 8.22412 10.782 8.48812C10.518 8.75212 10.386 9.13212 10.386 9.62812V13.6001C10.386 14.0961 10.518 14.4801 10.782 14.7521C11.054 15.0161 11.426 15.1481 11.898 15.1481C12.37 15.1481 12.734 15.0161 12.99 14.7521C13.254 14.4801 13.386 14.0961 13.386 13.6001H14.466C14.466 14.3761 14.234 14.9921 13.77 15.4481C13.306 15.8961 12.682 16.1201 11.898 16.1201Z" fill="var(--color-text)" id="icon-512-text"></path></svg><span>constructor</span></a>
35
+ </div></section>
36
+ <section class="tsd-index-section">
37
+ <h3 class="tsd-index-heading">Methods</h3>
38
+ <div class="tsd-index-list"><a href="NgrokSessionBuilder.html#authtoken" class="tsd-index-link tsd-kind-method tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><rect fill="var(--color-icon-background)" stroke="#FF4DB8" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12" id="icon-2048-path"></rect><path d="M9.162 16V7.24H10.578L11.514 10.072C11.602 10.328 11.674 10.584 11.73 10.84C11.794 11.088 11.842 11.28 11.874 11.416C11.906 11.28 11.954 11.088 12.018 10.84C12.082 10.584 12.154 10.324 12.234 10.06L13.122 7.24H14.538V16H13.482V12.82C13.482 12.468 13.49 12.068 13.506 11.62C13.53 11.172 13.558 10.716 13.59 10.252C13.622 9.78 13.654 9.332 13.686 8.908C13.726 8.476 13.762 8.1 13.794 7.78L12.366 12.16H11.334L9.894 7.78C9.934 8.092 9.97 8.456 10.002 8.872C10.042 9.28 10.078 9.716 10.11 10.18C10.142 10.636 10.166 11.092 10.182 11.548C10.206 12.004 10.218 12.428 10.218 12.82V16H9.162Z" fill="var(--color-text)" id="icon-2048-text"></path></svg><span>authtoken</span></a>
39
+ <a href="NgrokSessionBuilder.html#authtokenFromEnv" class="tsd-index-link tsd-kind-method tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>authtoken<wbr/>From<wbr/>Env</span></a>
40
+ <a href="NgrokSessionBuilder.html#connect" class="tsd-index-link tsd-kind-method tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>connect</span></a>
41
+ <a href="NgrokSessionBuilder.html#handleRestartCommand" class="tsd-index-link tsd-kind-method tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>handle<wbr/>Restart<wbr/>Command</span></a>
42
+ <a href="NgrokSessionBuilder.html#handleStopCommand" class="tsd-index-link tsd-kind-method tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>handle<wbr/>Stop<wbr/>Command</span></a>
43
+ <a href="NgrokSessionBuilder.html#handleUpdateCommand" class="tsd-index-link tsd-kind-method tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>handle<wbr/>Update<wbr/>Command</span></a>
44
+ <a href="NgrokSessionBuilder.html#heartbeatInterval" class="tsd-index-link tsd-kind-method tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>heartbeat<wbr/>Interval</span></a>
45
+ <a href="NgrokSessionBuilder.html#heartbeatTolerance" class="tsd-index-link tsd-kind-method tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>heartbeat<wbr/>Tolerance</span></a>
46
+ <a href="NgrokSessionBuilder.html#metadata" class="tsd-index-link tsd-kind-method tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>metadata</span></a>
47
+ <a href="NgrokSessionBuilder.html#serverAddr" class="tsd-index-link tsd-kind-method tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>server<wbr/>Addr</span></a>
48
+ </div></section></div></details></section></section>
49
+ <section class="tsd-panel-group tsd-member-group">
50
+ <h2>Constructors</h2>
51
+ <section class="tsd-panel tsd-member tsd-kind-constructor tsd-parent-kind-class"><a id="constructor" class="tsd-anchor"></a>
52
+ <h3 class="tsd-anchor-link"><span>constructor</span><a href="#constructor" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none" id="icon-anchor-a"></path><path d="M10 14a3.5 3.5 0 0 0 5 0l4 -4a3.5 3.5 0 0 0 -5 -5l-.5 .5" id="icon-anchor-b"></path><path d="M14 10a3.5 3.5 0 0 0 -5 0l-4 4a3.5 3.5 0 0 0 5 5l.5 -.5" id="icon-anchor-c"></path></svg></a></h3>
53
+ <ul class="tsd-signatures tsd-kind-constructor tsd-parent-kind-class">
54
+ <li class="tsd-signature tsd-anchor-link" id="constructor.new_NgrokSessionBuilder">new <wbr/>Ngrok<wbr/>Session<wbr/>Builder<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a><a href="#constructor.new_NgrokSessionBuilder" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
55
+ <li class="tsd-description">
56
+ <div class="tsd-comment tsd-typography"><p>Create a new session builder</p>
57
+ </div>
58
+ <h4 class="tsd-returns-title">Returns <a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a></h4><aside class="tsd-sources">
59
+ <ul>
60
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L15">index.d.ts:15</a></li></ul></aside></li></ul></section></section>
61
+ <section class="tsd-panel-group tsd-member-group">
62
+ <h2>Methods</h2>
63
+ <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class"><a id="authtoken" class="tsd-anchor"></a>
64
+ <h3 class="tsd-anchor-link"><span>authtoken</span><a href="#authtoken" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
65
+ <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
66
+ <li class="tsd-signature tsd-anchor-link" id="authtoken.authtoken-1">authtoken<span class="tsd-signature-symbol">(</span>authtoken<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a><a href="#authtoken.authtoken-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
67
+ <li class="tsd-description">
68
+ <div class="tsd-comment tsd-typography"><p>Configures the session to authenticate with the provided authtoken. You
69
+ can <a href="https://dashboard.ngrok.com/get-started/your-authtoken">find your existing authtoken</a> or <a href="https://dashboard.ngrok.com/tunnels/authtokens">create a new one</a> in the ngrok
70
+ dashboard.</p>
71
+ <p>See the <a href="https://ngrok.com/docs/ngrok-agent/config#authtoken">authtoken parameter in the ngrok docs</a> for additional details.</p>
72
+ </div>
73
+ <div class="tsd-parameters">
74
+ <h4 class="tsd-parameters-title">Parameters</h4>
75
+ <ul class="tsd-parameter-list">
76
+ <li>
77
+ <h5>authtoken: <span class="tsd-signature-type">string</span></h5></li></ul></div>
78
+ <h4 class="tsd-returns-title">Returns <a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a></h4><aside class="tsd-sources">
79
+ <ul>
80
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L27">index.d.ts:27</a></li></ul></aside></li></ul></section>
81
+ <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class"><a id="authtokenFromEnv" class="tsd-anchor"></a>
82
+ <h3 class="tsd-anchor-link"><span>authtoken<wbr/>From<wbr/>Env</span><a href="#authtokenFromEnv" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
83
+ <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
84
+ <li class="tsd-signature tsd-anchor-link" id="authtokenFromEnv.authtokenFromEnv-1">authtoken<wbr/>From<wbr/>Env<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a><a href="#authtokenFromEnv.authtokenFromEnv-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
85
+ <li class="tsd-description">
86
+ <div class="tsd-comment tsd-typography"><p>Shortcut for calling [SessionBuilder::authtoken] with the value of the
87
+ NGROK_AUTHTOKEN environment variable.</p>
88
+ </div>
89
+ <h4 class="tsd-returns-title">Returns <a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a></h4><aside class="tsd-sources">
90
+ <ul>
91
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L32">index.d.ts:32</a></li></ul></aside></li></ul></section>
92
+ <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class"><a id="connect" class="tsd-anchor"></a>
93
+ <h3 class="tsd-anchor-link"><span>connect</span><a href="#connect" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
94
+ <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
95
+ <li class="tsd-signature tsd-anchor-link" id="connect.connect-1">connect<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="NgrokSession.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSession</a><span class="tsd-signature-symbol">&gt;</span><a href="#connect.connect-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
96
+ <li class="tsd-description">
97
+ <div class="tsd-comment tsd-typography"><p>Attempt to establish an ngrok session using the current configuration.</p>
98
+ </div>
99
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="NgrokSession.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSession</a><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources">
100
+ <ul>
101
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L115">index.d.ts:115</a></li></ul></aside></li></ul></section>
102
+ <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class"><a id="handleRestartCommand" class="tsd-anchor"></a>
103
+ <h3 class="tsd-anchor-link"><span>handle<wbr/>Restart<wbr/>Command</span><a href="#handleRestartCommand" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
104
+ <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
105
+ <li class="tsd-signature tsd-anchor-link" id="handleRestartCommand.handleRestartCommand-1">handle<wbr/>Restart<wbr/>Command<span class="tsd-signature-symbol">(</span>handler<span class="tsd-signature-symbol">: </span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol"> =&gt; </span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a><a href="#handleRestartCommand.handleRestartCommand-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
106
+ <li class="tsd-description">
107
+ <div class="tsd-comment tsd-typography"><p>Configures a function which is called when the ngrok service requests
108
+ that this [Session] updates. Your application may choose to interpret
109
+ this callback as a request to restart the [Session] or the entire
110
+ process.</p>
111
+ <p>Errors returned by this function will be visible to the ngrok dashboard or
112
+ API as the response to the Restart operation.</p>
113
+ <p>Do not block inside this callback. It will cause the Dashboard or API
114
+ stop operation to time out. Do not call [std::process::exit] inside this
115
+ callback, it will also cause the operation to time out.</p>
116
+ </div>
117
+ <div class="tsd-parameters">
118
+ <h4 class="tsd-parameters-title">Parameters</h4>
119
+ <ul class="tsd-parameter-list">
120
+ <li>
121
+ <h5>handler: <span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol"> =&gt; </span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">)</span></h5>
122
+ <ul class="tsd-parameters">
123
+ <li class="tsd-parameter-signature">
124
+ <ul class="tsd-signatures tsd-kind-type-literal">
125
+ <li class="tsd-signature"><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
126
+ <li class="tsd-description">
127
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4></li></ul></li></ul></li></ul></div>
128
+ <h4 class="tsd-returns-title">Returns <a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a></h4><aside class="tsd-sources">
129
+ <ul>
130
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L99">index.d.ts:99</a></li></ul></aside></li></ul></section>
131
+ <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class"><a id="handleStopCommand" class="tsd-anchor"></a>
132
+ <h3 class="tsd-anchor-link"><span>handle<wbr/>Stop<wbr/>Command</span><a href="#handleStopCommand" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
133
+ <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
134
+ <li class="tsd-signature tsd-anchor-link" id="handleStopCommand.handleStopCommand-1">handle<wbr/>Stop<wbr/>Command<span class="tsd-signature-symbol">(</span>handler<span class="tsd-signature-symbol">: </span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol"> =&gt; </span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a><a href="#handleStopCommand.handleStopCommand-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
135
+ <li class="tsd-description">
136
+ <div class="tsd-comment tsd-typography"><p>Configures a function which is called when the ngrok service requests that
137
+ this [Session] stops. Your application may choose to interpret this callback
138
+ as a request to terminate the [Session] or the entire process.</p>
139
+ <p>Errors returned by this function will be visible to the ngrok dashboard or
140
+ API as the response to the Stop operation.</p>
141
+ <p>Do not block inside this callback. It will cause the Dashboard or API
142
+ stop operation to time out. Do not call [std::process::exit] inside this
143
+ callback, it will also cause the operation to time out.</p>
144
+ </div>
145
+ <div class="tsd-parameters">
146
+ <h4 class="tsd-parameters-title">Parameters</h4>
147
+ <ul class="tsd-parameter-list">
148
+ <li>
149
+ <h5>handler: <span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol"> =&gt; </span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">)</span></h5>
150
+ <ul class="tsd-parameters">
151
+ <li class="tsd-parameter-signature">
152
+ <ul class="tsd-signatures tsd-kind-type-literal">
153
+ <li class="tsd-signature"><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
154
+ <li class="tsd-description">
155
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4></li></ul></li></ul></li></ul></div>
156
+ <h4 class="tsd-returns-title">Returns <a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a></h4><aside class="tsd-sources">
157
+ <ul>
158
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L85">index.d.ts:85</a></li></ul></aside></li></ul></section>
159
+ <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class"><a id="handleUpdateCommand" class="tsd-anchor"></a>
160
+ <h3 class="tsd-anchor-link"><span>handle<wbr/>Update<wbr/>Command</span><a href="#handleUpdateCommand" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
161
+ <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
162
+ <li class="tsd-signature tsd-anchor-link" id="handleUpdateCommand.handleUpdateCommand-1">handle<wbr/>Update<wbr/>Command<span class="tsd-signature-symbol">(</span>handler<span class="tsd-signature-symbol">: </span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">(</span>update<span class="tsd-signature-symbol">: </span><a href="UpdateRequest.html" class="tsd-signature-type" data-tsd-kind="Class">UpdateRequest</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol"> =&gt; </span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a><a href="#handleUpdateCommand.handleUpdateCommand-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
163
+ <li class="tsd-description">
164
+ <div class="tsd-comment tsd-typography"><p>Configures a function which is called when the ngrok service requests
165
+ that this [Session] updates. Your application may choose to interpret
166
+ this callback as a request to update its configuration, itself, or to
167
+ invoke some other application-specific behavior.</p>
168
+ <p>Errors returned by this function will be visible to the ngrok dashboard or
169
+ API as the response to the Restart operation.</p>
170
+ <p>Do not block inside this callback. It will cause the Dashboard or API
171
+ stop operation to time out. Do not call [std::process::exit] inside this
172
+ callback, it will also cause the operation to time out.</p>
173
+ </div>
174
+ <div class="tsd-parameters">
175
+ <h4 class="tsd-parameters-title">Parameters</h4>
176
+ <ul class="tsd-parameter-list">
177
+ <li>
178
+ <h5>handler: <span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">(</span>update<span class="tsd-signature-symbol">: </span><a href="UpdateRequest.html" class="tsd-signature-type" data-tsd-kind="Class">UpdateRequest</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol"> =&gt; </span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">)</span></h5>
179
+ <ul class="tsd-parameters">
180
+ <li class="tsd-parameter-signature">
181
+ <ul class="tsd-signatures tsd-kind-type-literal">
182
+ <li class="tsd-signature"><span class="tsd-signature-symbol">(</span>update<span class="tsd-signature-symbol">: </span><a href="UpdateRequest.html" class="tsd-signature-type" data-tsd-kind="Class">UpdateRequest</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
183
+ <li class="tsd-description">
184
+ <div class="tsd-parameters">
185
+ <h4 class="tsd-parameters-title">Parameters</h4>
186
+ <ul class="tsd-parameter-list">
187
+ <li>
188
+ <h5>update: <a href="UpdateRequest.html" class="tsd-signature-type" data-tsd-kind="Class">UpdateRequest</a></h5></li></ul></div>
189
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4></li></ul></li></ul></li></ul></div>
190
+ <h4 class="tsd-returns-title">Returns <a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a></h4><aside class="tsd-sources">
191
+ <ul>
192
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L113">index.d.ts:113</a></li></ul></aside></li></ul></section>
193
+ <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class"><a id="heartbeatInterval" class="tsd-anchor"></a>
194
+ <h3 class="tsd-anchor-link"><span>heartbeat<wbr/>Interval</span><a href="#heartbeatInterval" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
195
+ <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
196
+ <li class="tsd-signature tsd-anchor-link" id="heartbeatInterval.heartbeatInterval-1">heartbeat<wbr/>Interval<span class="tsd-signature-symbol">(</span>heartbeatInterval<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a><a href="#heartbeatInterval.heartbeatInterval-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
197
+ <li class="tsd-description">
198
+ <div class="tsd-comment tsd-typography"><p>Configures how often the session will send heartbeat messages to the ngrok
199
+ service to check session liveness.</p>
200
+ <p>See the <a href="https://ngrok.com/docs/ngrok-agent/config#heartbeat_interval">heartbeat_interval parameter in the ngrok docs</a> for additional
201
+ details.</p>
202
+ </div>
203
+ <div class="tsd-parameters">
204
+ <h4 class="tsd-parameters-title">Parameters</h4>
205
+ <ul class="tsd-parameter-list">
206
+ <li>
207
+ <h5>heartbeatInterval: <span class="tsd-signature-type">number</span></h5></li></ul></div>
208
+ <h4 class="tsd-returns-title">Returns <a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a></h4><aside class="tsd-sources">
209
+ <ul>
210
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L42">index.d.ts:42</a></li></ul></aside></li></ul></section>
211
+ <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class"><a id="heartbeatTolerance" class="tsd-anchor"></a>
212
+ <h3 class="tsd-anchor-link"><span>heartbeat<wbr/>Tolerance</span><a href="#heartbeatTolerance" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
213
+ <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
214
+ <li class="tsd-signature tsd-anchor-link" id="heartbeatTolerance.heartbeatTolerance-1">heartbeat<wbr/>Tolerance<span class="tsd-signature-symbol">(</span>heartbeatTolerance<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a><a href="#heartbeatTolerance.heartbeatTolerance-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
215
+ <li class="tsd-description">
216
+ <div class="tsd-comment tsd-typography"><p>Configures the duration to wait for a response to a heartbeat before
217
+ assuming the session connection is dead and attempting to reconnect.</p>
218
+ <p>See the <a href="https://ngrok.com/docs/ngrok-agent/config#heartbeat_tolerance">heartbeat_tolerance parameter in the ngrok docs</a> for additional
219
+ details.</p>
220
+ </div>
221
+ <div class="tsd-parameters">
222
+ <h4 class="tsd-parameters-title">Parameters</h4>
223
+ <ul class="tsd-parameter-list">
224
+ <li>
225
+ <h5>heartbeatTolerance: <span class="tsd-signature-type">number</span></h5></li></ul></div>
226
+ <h4 class="tsd-returns-title">Returns <a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a></h4><aside class="tsd-sources">
227
+ <ul>
228
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L52">index.d.ts:52</a></li></ul></aside></li></ul></section>
229
+ <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class"><a id="metadata" class="tsd-anchor"></a>
230
+ <h3 class="tsd-anchor-link"><span>metadata</span><a href="#metadata" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
231
+ <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
232
+ <li class="tsd-signature tsd-anchor-link" id="metadata.metadata-1">metadata<span class="tsd-signature-symbol">(</span>metadata<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a><a href="#metadata.metadata-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
233
+ <li class="tsd-description">
234
+ <div class="tsd-comment tsd-typography"><p>Configures the opaque, machine-readable metadata string for this session.
235
+ Metadata is made available to you in the ngrok dashboard and the Agents API
236
+ resource. It is a useful way to allow you to uniquely identify sessions. We
237
+ suggest encoding the value in a structured format like JSON.</p>
238
+ <p>See the <a href="https://ngrok.com/docs/ngrok-agent/config#metadata">metdata parameter in the ngrok docs</a> for additional details.</p>
239
+ </div>
240
+ <div class="tsd-parameters">
241
+ <h4 class="tsd-parameters-title">Parameters</h4>
242
+ <ul class="tsd-parameter-list">
243
+ <li>
244
+ <h5>metadata: <span class="tsd-signature-type">string</span></h5></li></ul></div>
245
+ <h4 class="tsd-returns-title">Returns <a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a></h4><aside class="tsd-sources">
246
+ <ul>
247
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L63">index.d.ts:63</a></li></ul></aside></li></ul></section>
248
+ <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class"><a id="serverAddr" class="tsd-anchor"></a>
249
+ <h3 class="tsd-anchor-link"><span>server<wbr/>Addr</span><a href="#serverAddr" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
250
+ <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
251
+ <li class="tsd-signature tsd-anchor-link" id="serverAddr.serverAddr-1">server<wbr/>Addr<span class="tsd-signature-symbol">(</span>addr<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a><a href="#serverAddr.serverAddr-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li>
252
+ <li class="tsd-description">
253
+ <div class="tsd-comment tsd-typography"><p>Configures the network address to dial to connect to the ngrok service.
254
+ Use this option only if you are connecting to a custom agent ingress.</p>
255
+ <p>See the <a href="https://ngrok.com/docs/ngrok-agent/config#server_addr">server_addr parameter in the ngrok docs</a> for additional details.</p>
256
+ </div>
257
+ <div class="tsd-parameters">
258
+ <h4 class="tsd-parameters-title">Parameters</h4>
259
+ <ul class="tsd-parameter-list">
260
+ <li>
261
+ <h5>addr: <span class="tsd-signature-type">string</span></h5></li></ul></div>
262
+ <h4 class="tsd-returns-title">Returns <a href="NgrokSessionBuilder.html" class="tsd-signature-type" data-tsd-kind="Class">NgrokSessionBuilder</a></h4><aside class="tsd-sources">
263
+ <ul>
264
+ <li>Defined in <a href="https://github.com/ngrok/ngrok-js/blob/d73a841/index.d.ts#L72">index.d.ts:72</a></li></ul></aside></li></ul></section></section></div>
265
+ <div class="col-4 col-menu menu-sticky-wrap menu-highlight">
266
+ <div class="tsd-navigation settings">
267
+ <details class="tsd-index-accordion"><summary class="tsd-accordion-summary">
268
+ <h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><path d="M4.93896 8.531L12 15.591L19.061 8.531L16.939 6.409L12 11.349L7.06098 6.409L4.93896 8.531Z" fill="var(--color-text)"></path></svg> Settings</h3></summary>
269
+ <div class="tsd-accordion-details">
270
+ <div class="tsd-filter-visibility">
271
+ <h4 class="uppercase">Member Visibility</h4><form>
272
+ <ul id="tsd-filter-options">
273
+ <li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li>
274
+ <li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-private" name="private"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Private</span></label></li>
275
+ <li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li>
276
+ <li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></form></div>
277
+ <div class="tsd-theme-toggle">
278
+ <h4 class="uppercase">Theme</h4><select id="theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div>
279
+ <nav class="tsd-navigation primary">
280
+ <details class="tsd-index-accordion" open><summary class="tsd-accordion-summary">
281
+ <h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><path d="M4.93896 8.531L12 15.591L19.061 8.531L16.939 6.409L12 11.349L7.06098 6.409L4.93896 8.531Z" fill="var(--color-text)"></path></svg> Modules</h3></summary>
282
+ <div class="tsd-accordion-details">
283
+ <ul>
284
+ <li><a href="../modules.html">@ngrok/ngrok</a>
285
+ <ul></ul></li></ul></div></details></nav>
286
+ <nav class="tsd-navigation secondary menu-sticky">
287
+ <ul>
288
+ <li class="current tsd-kind-class"><a href="NgrokSessionBuilder.html" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-class)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6" id="icon-128-path"></rect><path d="M11.898 16.1201C11.098 16.1201 10.466 15.8961 10.002 15.4481C9.53803 15.0001 9.30603 14.3841 9.30603 13.6001V9.64012C9.30603 8.85612 9.53803 8.24012 10.002 7.79212C10.466 7.34412 11.098 7.12012 11.898 7.12012C12.682 7.12012 13.306 7.34812 13.77 7.80412C14.234 8.25212 14.466 8.86412 14.466 9.64012H13.386C13.386 9.14412 13.254 8.76412 12.99 8.50012C12.734 8.22812 12.37 8.09212 11.898 8.09212C11.426 8.09212 11.054 8.22412 10.782 8.48812C10.518 8.75212 10.386 9.13212 10.386 9.62812V13.6001C10.386 14.0961 10.518 14.4801 10.782 14.7521C11.054 15.0161 11.426 15.1481 11.898 15.1481C12.37 15.1481 12.734 15.0161 12.99 14.7521C13.254 14.4801 13.386 14.0961 13.386 13.6001H14.466C14.466 14.3761 14.234 14.9921 13.77 15.4481C13.306 15.8961 12.682 16.1201 11.898 16.1201Z" fill="var(--color-text)" id="icon-128-text"></path></svg><span>Ngrok<wbr/>Session<wbr/>Builder</span></a>
289
+ <ul>
290
+ <li class="tsd-kind-constructor tsd-parent-kind-class"><a href="NgrokSessionBuilder.html#constructor" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-512-path"></use><use href="#icon-512-text"></use></svg>constructor</a></li>
291
+ <li class="tsd-kind-method tsd-parent-kind-class"><a href="NgrokSessionBuilder.html#authtoken" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>authtoken</a></li>
292
+ <li class="tsd-kind-method tsd-parent-kind-class"><a href="NgrokSessionBuilder.html#authtokenFromEnv" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>authtoken<wbr/>From<wbr/>Env</a></li>
293
+ <li class="tsd-kind-method tsd-parent-kind-class"><a href="NgrokSessionBuilder.html#connect" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>connect</a></li>
294
+ <li class="tsd-kind-method tsd-parent-kind-class"><a href="NgrokSessionBuilder.html#handleRestartCommand" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>handle<wbr/>Restart<wbr/>Command</a></li>
295
+ <li class="tsd-kind-method tsd-parent-kind-class"><a href="NgrokSessionBuilder.html#handleStopCommand" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>handle<wbr/>Stop<wbr/>Command</a></li>
296
+ <li class="tsd-kind-method tsd-parent-kind-class"><a href="NgrokSessionBuilder.html#handleUpdateCommand" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>handle<wbr/>Update<wbr/>Command</a></li>
297
+ <li class="tsd-kind-method tsd-parent-kind-class"><a href="NgrokSessionBuilder.html#heartbeatInterval" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>heartbeat<wbr/>Interval</a></li>
298
+ <li class="tsd-kind-method tsd-parent-kind-class"><a href="NgrokSessionBuilder.html#heartbeatTolerance" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>heartbeat<wbr/>Tolerance</a></li>
299
+ <li class="tsd-kind-method tsd-parent-kind-class"><a href="NgrokSessionBuilder.html#metadata" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>metadata</a></li>
300
+ <li class="tsd-kind-method tsd-parent-kind-class"><a href="NgrokSessionBuilder.html#serverAddr" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>server<wbr/>Addr</a></li></ul></li></ul></nav></div></div>
301
+ <div class="container tsd-generator">
302
+ <p>Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></div>
303
+ <div class="overlay"></div><script src="../assets/main.js"></script></body></html>