ngrok-api 0.15.0 → 0.16.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (266) hide show
  1. checksums.yaml +4 -4
  2. data/.rubocop.yml +1 -1
  3. data/doc/NgrokAPI/Client.html +140 -172
  4. data/doc/NgrokAPI/Error.html +3 -3
  5. data/doc/NgrokAPI/Errors/NotFoundError.html +3 -3
  6. data/doc/NgrokAPI/Errors.html +3 -3
  7. data/doc/NgrokAPI/HttpClient.html +30 -36
  8. data/doc/NgrokAPI/Models/APIKey.html +3 -3
  9. data/doc/NgrokAPI/Models/AWSAuth.html +3 -3
  10. data/doc/NgrokAPI/Models/AWSCredentials.html +3 -3
  11. data/doc/NgrokAPI/Models/AWSRole.html +3 -3
  12. data/doc/NgrokAPI/Models/AbuseReport.html +3 -3
  13. data/doc/NgrokAPI/Models/AbuseReportHostname.html +3 -3
  14. data/doc/NgrokAPI/Models/{IPWhitelistEntry.html → AgentIngress.html} +216 -68
  15. data/doc/NgrokAPI/Models/CertificateAuthority.html +3 -3
  16. data/doc/NgrokAPI/Models/Credential.html +3 -3
  17. data/doc/NgrokAPI/Models/EndpointCircuitBreaker.html +3 -3
  18. data/doc/NgrokAPI/Models/EndpointCompression.html +3 -3
  19. data/doc/NgrokAPI/Models/EndpointConfiguration.html +3 -3
  20. data/doc/NgrokAPI/Models/EndpointIPPolicy.html +3 -3
  21. data/doc/NgrokAPI/Models/EndpointIPPolicyMutate.html +3 -3
  22. data/doc/NgrokAPI/Models/EndpointLogging.html +3 -3
  23. data/doc/NgrokAPI/Models/EndpointLoggingMutate.html +3 -3
  24. data/doc/NgrokAPI/Models/EndpointMutualTLS.html +3 -3
  25. data/doc/NgrokAPI/Models/EndpointMutualTLSMutate.html +3 -3
  26. data/doc/NgrokAPI/Models/EndpointOAuth.html +3 -3
  27. data/doc/NgrokAPI/Models/EndpointOAuthFacebook.html +3 -3
  28. data/doc/NgrokAPI/Models/EndpointOAuthGitHub.html +3 -3
  29. data/doc/NgrokAPI/Models/EndpointOAuthGoogle.html +3 -3
  30. data/doc/NgrokAPI/Models/EndpointOAuthMicrosoft.html +3 -3
  31. data/doc/NgrokAPI/Models/EndpointOAuthProvider.html +3 -3
  32. data/doc/NgrokAPI/Models/EndpointOIDC.html +3 -3
  33. data/doc/NgrokAPI/Models/EndpointRequestHeaders.html +3 -3
  34. data/doc/NgrokAPI/Models/EndpointResponseHeaders.html +3 -3
  35. data/doc/NgrokAPI/Models/EndpointSAML.html +3 -3
  36. data/doc/NgrokAPI/Models/EndpointSAMLMutate.html +3 -3
  37. data/doc/NgrokAPI/Models/EndpointTLSTermination.html +3 -3
  38. data/doc/NgrokAPI/Models/EndpointWebhookValidation.html +3 -3
  39. data/doc/NgrokAPI/Models/EventDestination.html +3 -3
  40. data/doc/NgrokAPI/Models/EventSource.html +3 -3
  41. data/doc/NgrokAPI/Models/EventSourceList.html +3 -3
  42. data/doc/NgrokAPI/Models/EventSourceReplace.html +3 -3
  43. data/doc/NgrokAPI/Models/EventStream.html +3 -3
  44. data/doc/NgrokAPI/Models/EventSubscription.html +3 -3
  45. data/doc/NgrokAPI/Models/EventTarget.html +3 -3
  46. data/doc/NgrokAPI/Models/EventTargetCloudwatchLogs.html +3 -3
  47. data/doc/NgrokAPI/Models/EventTargetFirehose.html +3 -3
  48. data/doc/NgrokAPI/Models/EventTargetKinesis.html +3 -3
  49. data/doc/NgrokAPI/Models/IPPolicy.html +3 -3
  50. data/doc/NgrokAPI/Models/IPPolicyRule.html +3 -3
  51. data/doc/NgrokAPI/Models/IPRestriction.html +3 -3
  52. data/doc/NgrokAPI/Models/Listable.html +3 -3
  53. data/doc/NgrokAPI/Models/Ref.html +3 -3
  54. data/doc/NgrokAPI/Models/ReservedAddr.html +3 -3
  55. data/doc/NgrokAPI/Models/ReservedDomain.html +3 -3
  56. data/doc/NgrokAPI/Models/ReservedDomainCertJob.html +3 -3
  57. data/doc/NgrokAPI/Models/ReservedDomainCertPolicy.html +3 -3
  58. data/doc/NgrokAPI/Models/ReservedDomainCertStatus.html +3 -3
  59. data/doc/NgrokAPI/Models/SSHCertificateAuthority.html +3 -3
  60. data/doc/NgrokAPI/Models/SSHCredential.html +3 -3
  61. data/doc/NgrokAPI/Models/SSHHostCertificate.html +3 -3
  62. data/doc/NgrokAPI/Models/SSHUserCertificate.html +3 -3
  63. data/doc/NgrokAPI/Models/TLSCertificate.html +3 -3
  64. data/doc/NgrokAPI/Models/TLSCertificateSANs.html +3 -3
  65. data/doc/NgrokAPI/Models/Tunnel.html +3 -3
  66. data/doc/NgrokAPI/Models/TunnelSession.html +3 -3
  67. data/doc/NgrokAPI/Models.html +5 -5
  68. data/doc/NgrokAPI/PagedIterator.html +3 -3
  69. data/doc/NgrokAPI/Services/APIKeysClient.html +99 -149
  70. data/doc/NgrokAPI/Services/AbuseReportsClient.html +19 -33
  71. data/doc/NgrokAPI/Services/{IPWhitelistClient.html → AgentIngressesClient.html} +209 -265
  72. data/doc/NgrokAPI/Services/CertificateAuthoritiesClient.html +104 -156
  73. data/doc/NgrokAPI/Services/CredentialsClient.html +108 -164
  74. data/doc/NgrokAPI/Services/EndpointCircuitBreakerModuleClient.html +49 -77
  75. data/doc/NgrokAPI/Services/EndpointCompressionModuleClient.html +49 -77
  76. data/doc/NgrokAPI/Services/EndpointConfigurationsClient.html +137 -273
  77. data/doc/NgrokAPI/Services/EndpointIPPolicyModuleClient.html +49 -77
  78. data/doc/NgrokAPI/Services/EndpointLoggingModuleClient.html +49 -77
  79. data/doc/NgrokAPI/Services/EndpointMutualTLSModuleClient.html +49 -77
  80. data/doc/NgrokAPI/Services/EndpointOAuthModuleClient.html +49 -77
  81. data/doc/NgrokAPI/Services/EndpointOIDCModuleClient.html +49 -77
  82. data/doc/NgrokAPI/Services/EndpointRequestHeadersModuleClient.html +49 -77
  83. data/doc/NgrokAPI/Services/EndpointResponseHeadersModuleClient.html +49 -77
  84. data/doc/NgrokAPI/Services/EndpointSAMLModuleClient.html +49 -77
  85. data/doc/NgrokAPI/Services/EndpointTLSTerminationModuleClient.html +49 -77
  86. data/doc/NgrokAPI/Services/EndpointWebhookValidationModuleClient.html +49 -77
  87. data/doc/NgrokAPI/Services/EventDestinationsClient.html +116 -184
  88. data/doc/NgrokAPI/Services/EventSourcesClient.html +95 -157
  89. data/doc/NgrokAPI/Services/EventStreamsClient.html +119 -189
  90. data/doc/NgrokAPI/Services/EventSubscriptionsClient.html +113 -175
  91. data/doc/NgrokAPI/Services/IPPoliciesClient.html +104 -156
  92. data/doc/NgrokAPI/Services/IPPolicyRulesClient.html +111 -169
  93. data/doc/NgrokAPI/Services/IPRestrictionsClient.html +116 -180
  94. data/doc/NgrokAPI/Services/ReservedAddrsClient.html +132 -198
  95. data/doc/NgrokAPI/Services/ReservedDomainsClient.html +193 -303
  96. data/doc/NgrokAPI/Services/SSHCertificateAuthoritiesClient.html +110 -166
  97. data/doc/NgrokAPI/Services/SSHCredentialsClient.html +111 -169
  98. data/doc/NgrokAPI/Services/SSHHostCertificatesClient.html +111 -171
  99. data/doc/NgrokAPI/Services/SSHUserCertificatesClient.html +111 -175
  100. data/doc/NgrokAPI/Services/TLSCertificatesClient.html +107 -161
  101. data/doc/NgrokAPI/Services/TunnelSessionsClient.html +87 -135
  102. data/doc/NgrokAPI/Services/TunnelsClient.html +13 -25
  103. data/doc/NgrokAPI/Services.html +5 -5
  104. data/doc/NgrokAPI.html +4 -4
  105. data/doc/_index.html +18 -18
  106. data/doc/class_list.html +1 -1
  107. data/doc/file.README.html +3 -3
  108. data/doc/frames.html +1 -1
  109. data/doc/index.html +3 -3
  110. data/doc/method_list.html +574 -558
  111. data/doc/top-level-namespace.html +3 -3
  112. data/docs/NgrokAPI/Client.html +140 -172
  113. data/docs/NgrokAPI/Error.html +3 -3
  114. data/docs/NgrokAPI/Errors/NotFoundError.html +3 -3
  115. data/docs/NgrokAPI/Errors.html +3 -3
  116. data/docs/NgrokAPI/HttpClient.html +30 -36
  117. data/docs/NgrokAPI/Models/APIKey.html +3 -3
  118. data/docs/NgrokAPI/Models/AWSAuth.html +3 -3
  119. data/docs/NgrokAPI/Models/AWSCredentials.html +3 -3
  120. data/docs/NgrokAPI/Models/AWSRole.html +3 -3
  121. data/docs/NgrokAPI/Models/AbuseReport.html +3 -3
  122. data/docs/NgrokAPI/Models/AbuseReportHostname.html +3 -3
  123. data/docs/NgrokAPI/Models/{IPWhitelistEntry.html → AgentIngress.html} +216 -68
  124. data/docs/NgrokAPI/Models/CertificateAuthority.html +3 -3
  125. data/docs/NgrokAPI/Models/Credential.html +3 -3
  126. data/docs/NgrokAPI/Models/EndpointCircuitBreaker.html +3 -3
  127. data/docs/NgrokAPI/Models/EndpointCompression.html +3 -3
  128. data/docs/NgrokAPI/Models/EndpointConfiguration.html +3 -3
  129. data/docs/NgrokAPI/Models/EndpointIPPolicy.html +3 -3
  130. data/docs/NgrokAPI/Models/EndpointIPPolicyMutate.html +3 -3
  131. data/docs/NgrokAPI/Models/EndpointLogging.html +3 -3
  132. data/docs/NgrokAPI/Models/EndpointLoggingMutate.html +3 -3
  133. data/docs/NgrokAPI/Models/EndpointMutualTLS.html +3 -3
  134. data/docs/NgrokAPI/Models/EndpointMutualTLSMutate.html +3 -3
  135. data/docs/NgrokAPI/Models/EndpointOAuth.html +3 -3
  136. data/docs/NgrokAPI/Models/EndpointOAuthFacebook.html +3 -3
  137. data/docs/NgrokAPI/Models/EndpointOAuthGitHub.html +3 -3
  138. data/docs/NgrokAPI/Models/EndpointOAuthGoogle.html +3 -3
  139. data/docs/NgrokAPI/Models/EndpointOAuthMicrosoft.html +3 -3
  140. data/docs/NgrokAPI/Models/EndpointOAuthProvider.html +3 -3
  141. data/docs/NgrokAPI/Models/EndpointOIDC.html +3 -3
  142. data/docs/NgrokAPI/Models/EndpointRequestHeaders.html +3 -3
  143. data/docs/NgrokAPI/Models/EndpointResponseHeaders.html +3 -3
  144. data/docs/NgrokAPI/Models/EndpointSAML.html +3 -3
  145. data/docs/NgrokAPI/Models/EndpointSAMLMutate.html +3 -3
  146. data/docs/NgrokAPI/Models/EndpointTLSTermination.html +3 -3
  147. data/docs/NgrokAPI/Models/EndpointWebhookValidation.html +3 -3
  148. data/docs/NgrokAPI/Models/EventDestination.html +3 -3
  149. data/docs/NgrokAPI/Models/EventSource.html +3 -3
  150. data/docs/NgrokAPI/Models/EventSourceList.html +3 -3
  151. data/docs/NgrokAPI/Models/EventSourceReplace.html +3 -3
  152. data/docs/NgrokAPI/Models/EventStream.html +3 -3
  153. data/docs/NgrokAPI/Models/EventSubscription.html +3 -3
  154. data/docs/NgrokAPI/Models/EventTarget.html +3 -3
  155. data/docs/NgrokAPI/Models/EventTargetCloudwatchLogs.html +3 -3
  156. data/docs/NgrokAPI/Models/EventTargetFirehose.html +3 -3
  157. data/docs/NgrokAPI/Models/EventTargetKinesis.html +3 -3
  158. data/docs/NgrokAPI/Models/IPPolicy.html +3 -3
  159. data/docs/NgrokAPI/Models/IPPolicyRule.html +3 -3
  160. data/docs/NgrokAPI/Models/IPRestriction.html +3 -3
  161. data/docs/NgrokAPI/Models/Listable.html +3 -3
  162. data/docs/NgrokAPI/Models/Ref.html +3 -3
  163. data/docs/NgrokAPI/Models/ReservedAddr.html +3 -3
  164. data/docs/NgrokAPI/Models/ReservedDomain.html +3 -3
  165. data/docs/NgrokAPI/Models/ReservedDomainCertJob.html +3 -3
  166. data/docs/NgrokAPI/Models/ReservedDomainCertPolicy.html +3 -3
  167. data/docs/NgrokAPI/Models/ReservedDomainCertStatus.html +3 -3
  168. data/docs/NgrokAPI/Models/SSHCertificateAuthority.html +3 -3
  169. data/docs/NgrokAPI/Models/SSHCredential.html +3 -3
  170. data/docs/NgrokAPI/Models/SSHHostCertificate.html +3 -3
  171. data/docs/NgrokAPI/Models/SSHUserCertificate.html +3 -3
  172. data/docs/NgrokAPI/Models/TLSCertificate.html +3 -3
  173. data/docs/NgrokAPI/Models/TLSCertificateSANs.html +3 -3
  174. data/docs/NgrokAPI/Models/Tunnel.html +3 -3
  175. data/docs/NgrokAPI/Models/TunnelSession.html +3 -3
  176. data/docs/NgrokAPI/Models.html +5 -5
  177. data/docs/NgrokAPI/PagedIterator.html +3 -3
  178. data/docs/NgrokAPI/Services/APIKeysClient.html +99 -149
  179. data/docs/NgrokAPI/Services/AbuseReportsClient.html +19 -33
  180. data/docs/NgrokAPI/Services/{IPWhitelistClient.html → AgentIngressesClient.html} +209 -265
  181. data/docs/NgrokAPI/Services/CertificateAuthoritiesClient.html +104 -156
  182. data/docs/NgrokAPI/Services/CredentialsClient.html +108 -164
  183. data/docs/NgrokAPI/Services/EndpointCircuitBreakerModuleClient.html +49 -77
  184. data/docs/NgrokAPI/Services/EndpointCompressionModuleClient.html +49 -77
  185. data/docs/NgrokAPI/Services/EndpointConfigurationsClient.html +137 -273
  186. data/docs/NgrokAPI/Services/EndpointIPPolicyModuleClient.html +49 -77
  187. data/docs/NgrokAPI/Services/EndpointLoggingModuleClient.html +49 -77
  188. data/docs/NgrokAPI/Services/EndpointMutualTLSModuleClient.html +49 -77
  189. data/docs/NgrokAPI/Services/EndpointOAuthModuleClient.html +49 -77
  190. data/docs/NgrokAPI/Services/EndpointOIDCModuleClient.html +49 -77
  191. data/docs/NgrokAPI/Services/EndpointRequestHeadersModuleClient.html +49 -77
  192. data/docs/NgrokAPI/Services/EndpointResponseHeadersModuleClient.html +49 -77
  193. data/docs/NgrokAPI/Services/EndpointSAMLModuleClient.html +49 -77
  194. data/docs/NgrokAPI/Services/EndpointTLSTerminationModuleClient.html +49 -77
  195. data/docs/NgrokAPI/Services/EndpointWebhookValidationModuleClient.html +49 -77
  196. data/docs/NgrokAPI/Services/EventDestinationsClient.html +116 -184
  197. data/docs/NgrokAPI/Services/EventSourcesClient.html +95 -157
  198. data/docs/NgrokAPI/Services/EventStreamsClient.html +119 -189
  199. data/docs/NgrokAPI/Services/EventSubscriptionsClient.html +113 -175
  200. data/docs/NgrokAPI/Services/IPPoliciesClient.html +104 -156
  201. data/docs/NgrokAPI/Services/IPPolicyRulesClient.html +111 -169
  202. data/docs/NgrokAPI/Services/IPRestrictionsClient.html +116 -180
  203. data/docs/NgrokAPI/Services/ReservedAddrsClient.html +132 -198
  204. data/docs/NgrokAPI/Services/ReservedDomainsClient.html +193 -303
  205. data/docs/NgrokAPI/Services/SSHCertificateAuthoritiesClient.html +110 -166
  206. data/docs/NgrokAPI/Services/SSHCredentialsClient.html +111 -169
  207. data/docs/NgrokAPI/Services/SSHHostCertificatesClient.html +111 -171
  208. data/docs/NgrokAPI/Services/SSHUserCertificatesClient.html +111 -175
  209. data/docs/NgrokAPI/Services/TLSCertificatesClient.html +107 -161
  210. data/docs/NgrokAPI/Services/TunnelSessionsClient.html +87 -135
  211. data/docs/NgrokAPI/Services/TunnelsClient.html +13 -25
  212. data/docs/NgrokAPI/Services.html +5 -5
  213. data/docs/NgrokAPI.html +4 -4
  214. data/docs/_index.html +18 -18
  215. data/docs/class_list.html +1 -1
  216. data/docs/file.README.html +3 -3
  217. data/docs/frames.html +1 -1
  218. data/docs/index.html +3 -3
  219. data/docs/method_list.html +574 -558
  220. data/docs/top-level-namespace.html +3 -3
  221. data/lib/ngrokapi/client.rb +5 -13
  222. data/lib/ngrokapi/http_client.rb +1 -4
  223. data/lib/ngrokapi/models/{ip_whitelist_entry.rb → agent_ingress.rb} +13 -9
  224. data/lib/ngrokapi/services/abuse_reports_client.rb +3 -10
  225. data/lib/ngrokapi/services/{ip_whitelist_client.rb → agent_ingresses_client.rb} +65 -94
  226. data/lib/ngrokapi/services/api_keys_client.rb +11 -36
  227. data/lib/ngrokapi/services/certificate_authorities_client.rb +11 -37
  228. data/lib/ngrokapi/services/credentials_client.rb +11 -39
  229. data/lib/ngrokapi/services/endpoint_circuit_breaker_module_client.rb +6 -20
  230. data/lib/ngrokapi/services/endpoint_compression_module_client.rb +6 -20
  231. data/lib/ngrokapi/services/endpoint_configurations_client.rb +11 -79
  232. data/lib/ngrokapi/services/endpoint_ip_policy_module_client.rb +6 -20
  233. data/lib/ngrokapi/services/endpoint_logging_module_client.rb +6 -20
  234. data/lib/ngrokapi/services/endpoint_mutual_tls_module_client.rb +6 -20
  235. data/lib/ngrokapi/services/endpoint_o_auth_module_client.rb +6 -20
  236. data/lib/ngrokapi/services/endpoint_oidc_module_client.rb +6 -20
  237. data/lib/ngrokapi/services/endpoint_request_headers_module_client.rb +6 -20
  238. data/lib/ngrokapi/services/endpoint_response_headers_module_client.rb +6 -20
  239. data/lib/ngrokapi/services/endpoint_saml_module_client.rb +6 -20
  240. data/lib/ngrokapi/services/endpoint_tls_termination_module_client.rb +6 -20
  241. data/lib/ngrokapi/services/endpoint_webhook_validation_module_client.rb +6 -20
  242. data/lib/ngrokapi/services/event_destinations_client.rb +11 -45
  243. data/lib/ngrokapi/services/event_sources_client.rb +9 -40
  244. data/lib/ngrokapi/services/event_streams_client.rb +11 -46
  245. data/lib/ngrokapi/services/event_subscriptions_client.rb +11 -42
  246. data/lib/ngrokapi/services/ip_policies_client.rb +11 -37
  247. data/lib/ngrokapi/services/ip_policy_rules_client.rb +11 -40
  248. data/lib/ngrokapi/services/ip_restrictions_client.rb +11 -43
  249. data/lib/ngrokapi/services/reserved_addrs_client.rb +13 -46
  250. data/lib/ngrokapi/services/reserved_domains_client.rb +19 -74
  251. data/lib/ngrokapi/services/ssh_certificate_authorities_client.rb +11 -39
  252. data/lib/ngrokapi/services/ssh_credentials_client.rb +11 -40
  253. data/lib/ngrokapi/services/ssh_host_certificates_client.rb +11 -41
  254. data/lib/ngrokapi/services/ssh_user_certificates_client.rb +11 -43
  255. data/lib/ngrokapi/services/tls_certificates_client.rb +11 -38
  256. data/lib/ngrokapi/services/tunnel_sessions_client.rb +12 -36
  257. data/lib/ngrokapi/services/tunnels_client.rb +4 -10
  258. data/lib/ngrokapi/version.rb +1 -1
  259. data/lib/ngrokapi.rb +1 -1
  260. data/ngrok-api.gemspec +1 -1
  261. data/spec/ngrokapi/client_spec.rb +6 -6
  262. data/spec/ngrokapi/models/agent_ingress_spec.rb +42 -0
  263. data/spec/ngrokapi/services/{ip_whitelist_client_spec.rb → agent_ingresses_client_spec.rb} +49 -49
  264. data/spec/spec_helper.rb +1096 -1045
  265. metadata +10 -10
  266. data/spec/ngrokapi/models/ip_whitelist_entry_spec.rb +0 -42
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Top Level Namespace
8
8
 
9
- &mdash; Documentation by YARD 0.9.26
9
+ &mdash; Documentation by YARD 0.9.27
10
10
 
11
11
  </title>
12
12
 
@@ -100,9 +100,9 @@
100
100
  </div>
101
101
 
102
102
  <div id="footer">
103
- Generated on Tue Oct 19 23:01:32 2021 by
103
+ Generated on Thu Dec 2 18:48:49 2021 by
104
104
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
105
- 0.9.26 (ruby-3.0.1).
105
+ 0.9.27 (ruby-3.0.1).
106
106
  </div>
107
107
 
108
108
  </div>
@@ -7,10 +7,7 @@ module NgrokAPI
7
7
  # Low-level api client for communicating with Ngrok's HTTP API.
8
8
  # Use this object to instantiate your clients.
9
9
  class Client
10
- def initialize(
11
- api_key:,
12
- base_url: 'https://api.ngrok.com'
13
- )
10
+ def initialize(api_key:, base_url: 'https://api.ngrok.com')
14
11
  @client = NgrokAPI::HttpClient.new(api_key: api_key, base_url: base_url)
15
12
  end
16
13
 
@@ -23,6 +20,10 @@ module NgrokAPI
23
20
  @_abuse_reports ||= NgrokAPI::Services::AbuseReportsClient.new(client: @client)
24
21
  end
25
22
 
23
+ def agent_ingresses
24
+ @_agent_ingresses ||= NgrokAPI::Services::AgentIngressesClient.new(client: @client)
25
+ end
26
+
26
27
  ##
27
28
  # API Keys are used to authenticate to the [ngrok
28
29
  # API](https://ngrok.com/docs/api#authentication). You may use the API itself
@@ -117,15 +118,6 @@ module NgrokAPI
117
118
  @_ip_restrictions ||= NgrokAPI::Services::IPRestrictionsClient.new(client: @client)
118
119
  end
119
120
 
120
- ##
121
- # The IP Whitelist is deprecated and will be removed. Use an IP Restriction
122
- # with an `endpoints` type instead.
123
- #
124
- # @return [NgrokAPI::Services::IPWhitelistClient]
125
- def ip_whitelist
126
- @_ip_whitelist ||= NgrokAPI::Services::IPWhitelistClient.new(client: @client)
127
- end
128
-
129
121
  ##
130
122
  # Reserved Addresses are TCP addresses that can be used to listen for traffic.
131
123
  # TCP address hostnames and ports are assigned by ngrok, they cannot be
@@ -8,10 +8,7 @@ module NgrokAPI
8
8
  attr_reader :api_key,
9
9
  :base_url
10
10
 
11
- def initialize(
12
- api_key:,
13
- base_url: 'https://api.ngrok.com'
14
- )
11
+ def initialize(api_key:, base_url: 'https://api.ngrok.com')
15
12
  @api_key = api_key
16
13
  @base_url = base_url
17
14
  end
@@ -2,25 +2,29 @@
2
2
 
3
3
  module NgrokAPI
4
4
  module Models
5
- class IPWhitelistEntry
5
+ class AgentIngress
6
6
  attr_reader :client,
7
7
  :result,
8
8
  :id,
9
9
  :uri,
10
- :created_at,
11
10
  :description,
12
11
  :metadata,
13
- :ip_net
12
+ :domain,
13
+ :ns_targets,
14
+ :region_domains,
15
+ :created_at
14
16
 
15
17
  def initialize(client:, result:)
16
18
  @client = client
17
19
  @result = result
18
20
  @id = @result['id']
19
21
  @uri = @result['uri']
20
- @created_at = @result['created_at']
21
22
  @description = @result['description']
22
23
  @metadata = @result['metadata']
23
- @ip_net = @result['ip_net']
24
+ @domain = @result['domain']
25
+ @ns_targets = @result['ns_targets']
26
+ @region_domains = @result['region_domains']
27
+ @created_at = @result['created_at']
24
28
  end
25
29
 
26
30
  def ==(other)
@@ -32,9 +36,9 @@ module NgrokAPI
32
36
  end
33
37
 
34
38
  ##
35
- # Delete an IP whitelist entry.
39
+ # Delete an Agent Ingress by ID
36
40
  #
37
- # https://ngrok.com/docs/api#api-ip-whitelist-delete
41
+ # https://ngrok.com/docs/api#api-agent-ingresses-delete
38
42
  def delete
39
43
  @client.delete(
40
44
  id: @id
@@ -42,9 +46,9 @@ module NgrokAPI
42
46
  end
43
47
 
44
48
  ##
45
- # Update attributes of an IP whitelist entry by ID
49
+ # Update attributes of an Agent Ingress by ID.
46
50
  #
47
- # https://ngrok.com/docs/api#api-ip-whitelist-update
51
+ # https://ngrok.com/docs/api#api-agent-ingresses-update
48
52
  def update(
49
53
  description: nil,
50
54
  metadata: nil
@@ -27,10 +27,7 @@ module NgrokAPI
27
27
  # @return [NgrokAPI::Models::AbuseReport] result from the API request
28
28
  #
29
29
  # https://ngrok.com/docs/api#api-abuse-reports-create
30
- def create(
31
- urls:,
32
- metadata: ""
33
- )
30
+ def create(urls:, metadata: "")
34
31
  path = '/abuse_reports'
35
32
  replacements = {
36
33
  }
@@ -48,9 +45,7 @@ module NgrokAPI
48
45
  # @return [NgrokAPI::Models::AbuseReport] result from the API request
49
46
  #
50
47
  # https://ngrok.com/docs/api#api-abuse-reports-get
51
- def get(
52
- id: ""
53
- )
48
+ def get(id: "")
54
49
  path = '/abuse_reports/%{id}'
55
50
  replacements = {
56
51
  id: id,
@@ -68,9 +63,7 @@ module NgrokAPI
68
63
  # @return [NgrokAPI::Models::AbuseReport] result from the API request
69
64
  #
70
65
  # https://ngrok.com/docs/api#api-abuse-reports-get
71
- def get!(
72
- id: ""
73
- )
66
+ def get!(id: "")
74
67
  path = '/abuse_reports/%{id}'
75
68
  replacements = {
76
69
  id: id,
@@ -3,15 +3,12 @@
3
3
  module NgrokAPI
4
4
  module Services
5
5
  ##
6
- # The IP Whitelist is deprecated and will be removed. Use an IP Restriction
7
- # with an `endpoints` type instead.
8
- #
9
- # https://ngrok.com/docs/api#api-ip-whitelist
10
- class IPWhitelistClient
6
+ # https://ngrok.com/docs/api#api-agent-ingresses
7
+ class AgentIngressesClient
11
8
  # The API path for the requests
12
- PATH = '/ip_whitelist'
9
+ PATH = '/agent_ingresses'
13
10
  # The List Property from the resulting API for list calls
14
- LIST_PROPERTY = 'whitelist'
11
+ LIST_PROPERTY = 'ingresses'
15
12
 
16
13
  attr_reader :client
17
14
 
@@ -20,42 +17,36 @@ module NgrokAPI
20
17
  end
21
18
 
22
19
  ##
23
- # Create a new IP whitelist entry that will restrict traffic to all tunnel
24
- # endpoints on the account.
25
- #
26
- # @param [string] description human-readable description of the source IPs for this IP whitelist entry. optional, max 255 bytes.
27
- # @param [string] metadata arbitrary user-defined machine-readable data of this IP whitelist entry. optional, max 4096 bytes.
28
- # @param [string] ip_net an IP address or IP network range in CIDR notation (e.g. 10.1.1.1 or 10.1.0.0/16) of addresses that will be whitelisted to communicate with your tunnel endpoints
29
- # @return [NgrokAPI::Models::IPWhitelistEntry] result from the API request
30
- #
31
- # https://ngrok.com/docs/api#api-ip-whitelist-create
32
- def create(
33
- description: "",
34
- metadata: "",
35
- ip_net: ""
36
- )
37
- path = '/ip_whitelist'
20
+ # Create a new Agent Ingress. The ngrok agent can be configured to connect to
21
+ # ngrok via the new set of addresses on the returned Agent Ingress.
22
+ #
23
+ # @param [string] description human-readable description of the use of this Agent Ingress. optional, max 255 bytes.
24
+ # @param [string] metadata arbitrary user-defined machine-readable data of this Agent Ingress. optional, max 4096 bytes
25
+ # @param [string] domain the domain that you own to be used as the base domain name to generate regional agent ingress domains.
26
+ # @return [NgrokAPI::Models::AgentIngress] result from the API request
27
+ #
28
+ # https://ngrok.com/docs/api#api-agent-ingresses-create
29
+ def create(description: "", metadata: "", domain:)
30
+ path = '/agent_ingresses'
38
31
  replacements = {
39
32
  }
40
33
  data = {}
41
34
  data[:description] = description if description
42
35
  data[:metadata] = metadata if metadata
43
- data[:ip_net] = ip_net if ip_net
36
+ data[:domain] = domain if domain
44
37
  result = @client.post(path % replacements, data: data)
45
- NgrokAPI::Models::IPWhitelistEntry.new(client: self, result: result)
38
+ NgrokAPI::Models::AgentIngress.new(client: self, result: result)
46
39
  end
47
40
 
48
41
  ##
49
- # Delete an IP whitelist entry.
42
+ # Delete an Agent Ingress by ID
50
43
  #
51
44
  # @param [string] id a resource identifier
52
45
  # @return [NgrokAPI::Models::Empty] result from the API request
53
46
  #
54
- # https://ngrok.com/docs/api#api-ip-whitelist-delete
55
- def delete(
56
- id: ""
57
- )
58
- path = '/ip_whitelist/%{id}'
47
+ # https://ngrok.com/docs/api#api-agent-ingresses-delete
48
+ def delete(id: "")
49
+ path = '/agent_ingresses/%{id}'
59
50
  replacements = {
60
51
  id: id,
61
52
  }
@@ -63,17 +54,15 @@ module NgrokAPI
63
54
  end
64
55
 
65
56
  ##
66
- # Delete an IP whitelist entry.
57
+ # Delete an Agent Ingress by ID
67
58
  # Throws an exception if API error.
68
59
  #
69
60
  # @param [string] id a resource identifier
70
61
  # @return [NgrokAPI::Models::Empty] result from the API request
71
62
  #
72
- # https://ngrok.com/docs/api#api-ip-whitelist-delete
73
- def delete!(
74
- id: ""
75
- )
76
- path = '/ip_whitelist/%{id}'
63
+ # https://ngrok.com/docs/api#api-agent-ingresses-delete
64
+ def delete!(id: "")
65
+ path = '/agent_ingresses/%{id}'
77
66
  replacements = {
78
67
  id: id,
79
68
  }
@@ -81,58 +70,51 @@ module NgrokAPI
81
70
  end
82
71
 
83
72
  ##
84
- # Get detailed information about an IP whitelist entry by ID.
73
+ # Get the details of an Agent Ingress by ID.
85
74
  #
86
75
  # @param [string] id a resource identifier
87
- # @return [NgrokAPI::Models::IPWhitelistEntry] result from the API request
76
+ # @return [NgrokAPI::Models::AgentIngress] result from the API request
88
77
  #
89
- # https://ngrok.com/docs/api#api-ip-whitelist-get
90
- def get(
91
- id: ""
92
- )
93
- path = '/ip_whitelist/%{id}'
78
+ # https://ngrok.com/docs/api#api-agent-ingresses-get
79
+ def get(id: "")
80
+ path = '/agent_ingresses/%{id}'
94
81
  replacements = {
95
82
  id: id,
96
83
  }
97
84
  data = {}
98
85
  result = @client.get(path % replacements, data: data)
99
- NgrokAPI::Models::IPWhitelistEntry.new(client: self, result: result)
86
+ NgrokAPI::Models::AgentIngress.new(client: self, result: result)
100
87
  end
101
88
 
102
89
  ##
103
- # Get detailed information about an IP whitelist entry by ID.
90
+ # Get the details of an Agent Ingress by ID.
104
91
  # Throws an exception if API error.
105
92
  #
106
93
  # @param [string] id a resource identifier
107
- # @return [NgrokAPI::Models::IPWhitelistEntry] result from the API request
94
+ # @return [NgrokAPI::Models::AgentIngress] result from the API request
108
95
  #
109
- # https://ngrok.com/docs/api#api-ip-whitelist-get
110
- def get!(
111
- id: ""
112
- )
113
- path = '/ip_whitelist/%{id}'
96
+ # https://ngrok.com/docs/api#api-agent-ingresses-get
97
+ def get!(id: "")
98
+ path = '/agent_ingresses/%{id}'
114
99
  replacements = {
115
100
  id: id,
116
101
  }
117
102
  data = {}
118
103
  result = @client.get(path % replacements, data: data, danger: true)
119
- NgrokAPI::Models::IPWhitelistEntry.new(client: self, result: result)
104
+ NgrokAPI::Models::AgentIngress.new(client: self, result: result)
120
105
  end
121
106
 
122
107
  ##
123
- # List all IP whitelist entries on this account
108
+ # List all Agent Ingresses owned by this account
124
109
  #
125
110
  # @param [string] before_id
126
111
  # @param [string] limit
127
112
  # @param [string] url optional and mutually exclusive from before_id and limit
128
113
  # @return [NgrokAPI::Models::Listable] result from the API request
129
114
  #
130
- # https://ngrok.com/docs/api#api-ip-whitelist-list
131
- def list(
132
- before_id: nil,
133
- limit: nil,
134
- url: nil
135
- )
115
+ # https://ngrok.com/docs/api#api-agent-ingresses-list
116
+ def list(before_id: nil, limit: nil,
117
+ url: nil)
136
118
  result = @client.list(
137
119
  before_id: before_id,
138
120
  limit: limit,
@@ -144,12 +126,12 @@ module NgrokAPI
144
126
  client: self,
145
127
  result: result,
146
128
  list_property: LIST_PROPERTY,
147
- klass: NgrokAPI::Models::IPWhitelistEntry
129
+ klass: NgrokAPI::Models::AgentIngress
148
130
  )
149
131
  end
150
132
 
151
133
  ##
152
- # List all IP whitelist entries on this account
134
+ # List all Agent Ingresses owned by this account
153
135
  # Throws an exception if API error.
154
136
  #
155
137
  # @param [string] before_id
@@ -157,12 +139,9 @@ module NgrokAPI
157
139
  # @param [string] url optional and mutually exclusive from before_id and limit
158
140
  # @return [NgrokAPI::Models::Listable] result from the API request
159
141
  #
160
- # https://ngrok.com/docs/api#api-ip-whitelist-list
161
- def list!(
162
- before_id: nil,
163
- limit: nil,
164
- url: nil
165
- )
142
+ # https://ngrok.com/docs/api#api-agent-ingresses-list
143
+ def list!(before_id: nil, limit: nil,
144
+ url: nil)
166
145
  result = @client.list(
167
146
  before_id: before_id,
168
147
  limit: limit,
@@ -175,26 +154,22 @@ module NgrokAPI
175
154
  client: self,
176
155
  result: result,
177
156
  list_property: LIST_PROPERTY,
178
- klass: NgrokAPI::Models::IPWhitelistEntry,
157
+ klass: NgrokAPI::Models::AgentIngress,
179
158
  danger: true
180
159
  )
181
160
  end
182
161
 
183
162
  ##
184
- # Update attributes of an IP whitelist entry by ID
163
+ # Update attributes of an Agent Ingress by ID.
185
164
  #
186
165
  # @param [string] id
187
- # @param [string] description human-readable description of the source IPs for this IP whitelist entry. optional, max 255 bytes.
188
- # @param [string] metadata arbitrary user-defined machine-readable data of this IP whitelist entry. optional, max 4096 bytes.
189
- # @return [NgrokAPI::Models::IPWhitelistEntry] result from the API request
190
- #
191
- # https://ngrok.com/docs/api#api-ip-whitelist-update
192
- def update(
193
- id: "",
194
- description: nil,
195
- metadata: nil
196
- )
197
- path = '/ip_whitelist/%{id}'
166
+ # @param [string] description human-readable description of the use of this Agent Ingress. optional, max 255 bytes.
167
+ # @param [string] metadata arbitrary user-defined machine-readable data of this Agent Ingress. optional, max 4096 bytes
168
+ # @return [NgrokAPI::Models::AgentIngress] result from the API request
169
+ #
170
+ # https://ngrok.com/docs/api#api-agent-ingresses-update
171
+ def update(id: "", description: nil, metadata: nil)
172
+ path = '/agent_ingresses/%{id}'
198
173
  replacements = {
199
174
  id: id,
200
175
  }
@@ -202,25 +177,21 @@ module NgrokAPI
202
177
  data[:description] = description if description
203
178
  data[:metadata] = metadata if metadata
204
179
  result = @client.patch(path % replacements, data: data)
205
- NgrokAPI::Models::IPWhitelistEntry.new(client: self, result: result)
180
+ NgrokAPI::Models::AgentIngress.new(client: self, result: result)
206
181
  end
207
182
 
208
183
  ##
209
- # Update attributes of an IP whitelist entry by ID
184
+ # Update attributes of an Agent Ingress by ID.
210
185
  # Throws an exception if API error.
211
186
  #
212
187
  # @param [string] id
213
- # @param [string] description human-readable description of the source IPs for this IP whitelist entry. optional, max 255 bytes.
214
- # @param [string] metadata arbitrary user-defined machine-readable data of this IP whitelist entry. optional, max 4096 bytes.
215
- # @return [NgrokAPI::Models::IPWhitelistEntry] result from the API request
216
- #
217
- # https://ngrok.com/docs/api#api-ip-whitelist-update
218
- def update!(
219
- id: "",
220
- description: nil,
221
- metadata: nil
222
- )
223
- path = '/ip_whitelist/%{id}'
188
+ # @param [string] description human-readable description of the use of this Agent Ingress. optional, max 255 bytes.
189
+ # @param [string] metadata arbitrary user-defined machine-readable data of this Agent Ingress. optional, max 4096 bytes
190
+ # @return [NgrokAPI::Models::AgentIngress] result from the API request
191
+ #
192
+ # https://ngrok.com/docs/api#api-agent-ingresses-update
193
+ def update!(id: "", description: nil, metadata: nil)
194
+ path = '/agent_ingresses/%{id}'
224
195
  replacements = {
225
196
  id: id,
226
197
  }
@@ -228,7 +199,7 @@ module NgrokAPI
228
199
  data[:description] = description if description
229
200
  data[:metadata] = metadata if metadata
230
201
  result = @client.patch(path % replacements, data: data, danger: true)
231
- NgrokAPI::Models::IPWhitelistEntry.new(client: self, result: result)
202
+ NgrokAPI::Models::AgentIngress.new(client: self, result: result)
232
203
  end
233
204
  end
234
205
  end
@@ -31,10 +31,7 @@ module NgrokAPI
31
31
  # @return [NgrokAPI::Models::APIKey] result from the API request
32
32
  #
33
33
  # https://ngrok.com/docs/api#api-api-keys-create
34
- def create(
35
- description: "",
36
- metadata: ""
37
- )
34
+ def create(description: "", metadata: "")
38
35
  path = '/api_keys'
39
36
  replacements = {
40
37
  }
@@ -52,9 +49,7 @@ module NgrokAPI
52
49
  # @return [NgrokAPI::Models::Empty] result from the API request
53
50
  #
54
51
  # https://ngrok.com/docs/api#api-api-keys-delete
55
- def delete(
56
- id: ""
57
- )
52
+ def delete(id: "")
58
53
  path = '/api_keys/%{id}'
59
54
  replacements = {
60
55
  id: id,
@@ -70,9 +65,7 @@ module NgrokAPI
70
65
  # @return [NgrokAPI::Models::Empty] result from the API request
71
66
  #
72
67
  # https://ngrok.com/docs/api#api-api-keys-delete
73
- def delete!(
74
- id: ""
75
- )
68
+ def delete!(id: "")
76
69
  path = '/api_keys/%{id}'
77
70
  replacements = {
78
71
  id: id,
@@ -87,9 +80,7 @@ module NgrokAPI
87
80
  # @return [NgrokAPI::Models::APIKey] result from the API request
88
81
  #
89
82
  # https://ngrok.com/docs/api#api-api-keys-get
90
- def get(
91
- id: ""
92
- )
83
+ def get(id: "")
93
84
  path = '/api_keys/%{id}'
94
85
  replacements = {
95
86
  id: id,
@@ -107,9 +98,7 @@ module NgrokAPI
107
98
  # @return [NgrokAPI::Models::APIKey] result from the API request
108
99
  #
109
100
  # https://ngrok.com/docs/api#api-api-keys-get
110
- def get!(
111
- id: ""
112
- )
101
+ def get!(id: "")
113
102
  path = '/api_keys/%{id}'
114
103
  replacements = {
115
104
  id: id,
@@ -128,11 +117,8 @@ module NgrokAPI
128
117
  # @return [NgrokAPI::Models::Listable] result from the API request
129
118
  #
130
119
  # https://ngrok.com/docs/api#api-api-keys-list
131
- def list(
132
- before_id: nil,
133
- limit: nil,
134
- url: nil
135
- )
120
+ def list(before_id: nil, limit: nil,
121
+ url: nil)
136
122
  result = @client.list(
137
123
  before_id: before_id,
138
124
  limit: limit,
@@ -158,11 +144,8 @@ module NgrokAPI
158
144
  # @return [NgrokAPI::Models::Listable] result from the API request
159
145
  #
160
146
  # https://ngrok.com/docs/api#api-api-keys-list
161
- def list!(
162
- before_id: nil,
163
- limit: nil,
164
- url: nil
165
- )
147
+ def list!(before_id: nil, limit: nil,
148
+ url: nil)
166
149
  result = @client.list(
167
150
  before_id: before_id,
168
151
  limit: limit,
@@ -189,11 +172,7 @@ module NgrokAPI
189
172
  # @return [NgrokAPI::Models::APIKey] result from the API request
190
173
  #
191
174
  # https://ngrok.com/docs/api#api-api-keys-update
192
- def update(
193
- id: "",
194
- description: nil,
195
- metadata: nil
196
- )
175
+ def update(id: "", description: nil, metadata: nil)
197
176
  path = '/api_keys/%{id}'
198
177
  replacements = {
199
178
  id: id,
@@ -215,11 +194,7 @@ module NgrokAPI
215
194
  # @return [NgrokAPI::Models::APIKey] result from the API request
216
195
  #
217
196
  # https://ngrok.com/docs/api#api-api-keys-update
218
- def update!(
219
- id: "",
220
- description: nil,
221
- metadata: nil
222
- )
197
+ def update!(id: "", description: nil, metadata: nil)
223
198
  path = '/api_keys/%{id}'
224
199
  replacements = {
225
200
  id: id,
@@ -31,11 +31,7 @@ module NgrokAPI
31
31
  # @return [NgrokAPI::Models::CertificateAuthority] result from the API request
32
32
  #
33
33
  # https://ngrok.com/docs/api#api-certificate-authorities-create
34
- def create(
35
- description: "",
36
- metadata: "",
37
- ca_pem:
38
- )
34
+ def create(description: "", metadata: "", ca_pem:)
39
35
  path = '/certificate_authorities'
40
36
  replacements = {
41
37
  }
@@ -54,9 +50,7 @@ module NgrokAPI
54
50
  # @return [NgrokAPI::Models::Empty] result from the API request
55
51
  #
56
52
  # https://ngrok.com/docs/api#api-certificate-authorities-delete
57
- def delete(
58
- id: ""
59
- )
53
+ def delete(id: "")
60
54
  path = '/certificate_authorities/%{id}'
61
55
  replacements = {
62
56
  id: id,
@@ -72,9 +66,7 @@ module NgrokAPI
72
66
  # @return [NgrokAPI::Models::Empty] result from the API request
73
67
  #
74
68
  # https://ngrok.com/docs/api#api-certificate-authorities-delete
75
- def delete!(
76
- id: ""
77
- )
69
+ def delete!(id: "")
78
70
  path = '/certificate_authorities/%{id}'
79
71
  replacements = {
80
72
  id: id,
@@ -89,9 +81,7 @@ module NgrokAPI
89
81
  # @return [NgrokAPI::Models::CertificateAuthority] result from the API request
90
82
  #
91
83
  # https://ngrok.com/docs/api#api-certificate-authorities-get
92
- def get(
93
- id: ""
94
- )
84
+ def get(id: "")
95
85
  path = '/certificate_authorities/%{id}'
96
86
  replacements = {
97
87
  id: id,
@@ -109,9 +99,7 @@ module NgrokAPI
109
99
  # @return [NgrokAPI::Models::CertificateAuthority] result from the API request
110
100
  #
111
101
  # https://ngrok.com/docs/api#api-certificate-authorities-get
112
- def get!(
113
- id: ""
114
- )
102
+ def get!(id: "")
115
103
  path = '/certificate_authorities/%{id}'
116
104
  replacements = {
117
105
  id: id,
@@ -130,11 +118,8 @@ module NgrokAPI
130
118
  # @return [NgrokAPI::Models::Listable] result from the API request
131
119
  #
132
120
  # https://ngrok.com/docs/api#api-certificate-authorities-list
133
- def list(
134
- before_id: nil,
135
- limit: nil,
136
- url: nil
137
- )
121
+ def list(before_id: nil, limit: nil,
122
+ url: nil)
138
123
  result = @client.list(
139
124
  before_id: before_id,
140
125
  limit: limit,
@@ -160,11 +145,8 @@ module NgrokAPI
160
145
  # @return [NgrokAPI::Models::Listable] result from the API request
161
146
  #
162
147
  # https://ngrok.com/docs/api#api-certificate-authorities-list
163
- def list!(
164
- before_id: nil,
165
- limit: nil,
166
- url: nil
167
- )
148
+ def list!(before_id: nil, limit: nil,
149
+ url: nil)
168
150
  result = @client.list(
169
151
  before_id: before_id,
170
152
  limit: limit,
@@ -191,11 +173,7 @@ module NgrokAPI
191
173
  # @return [NgrokAPI::Models::CertificateAuthority] result from the API request
192
174
  #
193
175
  # https://ngrok.com/docs/api#api-certificate-authorities-update
194
- def update(
195
- id: "",
196
- description: nil,
197
- metadata: nil
198
- )
176
+ def update(id: "", description: nil, metadata: nil)
199
177
  path = '/certificate_authorities/%{id}'
200
178
  replacements = {
201
179
  id: id,
@@ -217,11 +195,7 @@ module NgrokAPI
217
195
  # @return [NgrokAPI::Models::CertificateAuthority] result from the API request
218
196
  #
219
197
  # https://ngrok.com/docs/api#api-certificate-authorities-update
220
- def update!(
221
- id: "",
222
- description: nil,
223
- metadata: nil
224
- )
198
+ def update!(id: "", description: nil, metadata: nil)
225
199
  path = '/certificate_authorities/%{id}'
226
200
  replacements = {
227
201
  id: id,