ngrok-api 0.9.0 → 0.12.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rubocop.yml +1 -1
- data/doc/.gitkeep +0 -0
- data/doc/NgrokAPI/Client.html +1499 -125
- data/doc/NgrokAPI/Error.html +1 -1
- data/doc/NgrokAPI/Errors/NotFoundError.html +1 -1
- data/doc/NgrokAPI/Errors.html +1 -1
- data/doc/NgrokAPI/HttpClient.html +1 -1
- data/doc/NgrokAPI/Models/{ApiKey.html → APIKey.html} +108 -177
- data/doc/NgrokAPI/Models/AWSAuth.html +617 -0
- data/doc/NgrokAPI/Models/AWSCredentials.html +617 -0
- data/doc/NgrokAPI/Models/AWSRole.html +543 -0
- data/doc/NgrokAPI/Models/AbuseReport.html +987 -0
- data/doc/NgrokAPI/Models/AbuseReportHostname.html +617 -0
- data/doc/NgrokAPI/Models/CertificateAuthority.html +1439 -0
- data/doc/NgrokAPI/Models/Credential.html +1149 -0
- data/doc/NgrokAPI/Models/EndpointCircuitBreaker.html +913 -0
- data/doc/NgrokAPI/Models/EndpointCompression.html +543 -0
- data/doc/NgrokAPI/Models/EndpointConfiguration.html +1321 -510
- data/doc/NgrokAPI/Models/EndpointIPPolicy.html +617 -0
- data/doc/NgrokAPI/Models/EndpointIPPolicyMutate.html +617 -0
- data/doc/NgrokAPI/Models/EndpointLogging.html +617 -0
- data/doc/NgrokAPI/Models/EndpointLoggingMutate.html +617 -0
- data/doc/NgrokAPI/Models/EndpointMutualTLS.html +617 -0
- data/doc/NgrokAPI/Models/EndpointMutualTLSMutate.html +617 -0
- data/doc/NgrokAPI/Models/EndpointOAuth.html +987 -0
- data/doc/NgrokAPI/Models/EndpointOAuthFacebook.html +839 -0
- data/doc/NgrokAPI/Models/EndpointOAuthGitHub.html +987 -0
- data/doc/NgrokAPI/Models/EndpointOAuthGoogle.html +839 -0
- data/doc/NgrokAPI/Models/EndpointOAuthMicrosoft.html +839 -0
- data/doc/NgrokAPI/Models/EndpointOAuthProvider.html +765 -0
- data/doc/NgrokAPI/Models/EndpointOIDC.html +1135 -0
- data/doc/NgrokAPI/Models/EndpointRequestHeaders.html +691 -0
- data/doc/NgrokAPI/Models/EndpointResponseHeaders.html +691 -0
- data/doc/NgrokAPI/Models/EndpointSAML.html +1653 -0
- data/doc/NgrokAPI/Models/EndpointSAMLMutate.html +1283 -0
- data/doc/NgrokAPI/Models/EndpointTLSTermination.html +691 -0
- data/doc/NgrokAPI/Models/EndpointWebhookValidation.html +691 -0
- data/doc/NgrokAPI/Models/EventDestination.html +1058 -0
- data/doc/NgrokAPI/Models/EventSource.html +765 -0
- data/doc/NgrokAPI/Models/EventSourceReplace.html +691 -0
- data/doc/NgrokAPI/Models/EventStream.html +1309 -0
- data/doc/NgrokAPI/Models/EventSubscription.html +1058 -0
- data/doc/NgrokAPI/Models/EventTarget.html +765 -0
- data/doc/NgrokAPI/Models/EventTargetCloudwatchLogs.html +617 -0
- data/doc/NgrokAPI/Models/EventTargetFirehose.html +617 -0
- data/doc/NgrokAPI/Models/EventTargetKinesis.html +617 -0
- data/doc/NgrokAPI/Models/IPPolicy.html +1069 -0
- data/doc/NgrokAPI/Models/IPPolicyRule.html +1149 -0
- data/doc/NgrokAPI/Models/IPRestriction.html +1132 -0
- data/doc/NgrokAPI/Models/{TlsCertificate.html → IPWhitelistEntry.html} +168 -163
- data/doc/NgrokAPI/Models/Listable.html +1 -1
- data/doc/NgrokAPI/Models/Ref.html +617 -0
- data/doc/NgrokAPI/Models/ReservedAddr.html +1132 -0
- data/doc/NgrokAPI/Models/ReservedDomain.html +111 -1107
- data/doc/NgrokAPI/Models/ReservedDomainCertJob.html +839 -0
- data/doc/NgrokAPI/Models/ReservedDomainCertNSTarget.html +617 -0
- data/doc/NgrokAPI/Models/ReservedDomainCertPolicy.html +617 -0
- data/doc/NgrokAPI/Models/ReservedDomainCertStatus.html +617 -0
- data/doc/NgrokAPI/Models/SSHCertificateAuthority.html +1143 -0
- data/doc/NgrokAPI/Models/SSHCredential.html +1149 -0
- data/doc/NgrokAPI/Models/SSHHostCertificate.html +1513 -0
- data/doc/NgrokAPI/Models/SSHUserCertificate.html +1661 -0
- data/doc/NgrokAPI/Models/TLSCertificate.html +2179 -0
- data/doc/NgrokAPI/Models/TLSCertificateSANs.html +617 -0
- data/doc/NgrokAPI/Models/Tunnel.html +987 -0
- data/doc/NgrokAPI/Models/TunnelSession.html +1209 -0
- data/doc/NgrokAPI/Models.html +4 -4
- data/doc/NgrokAPI/PagedIterator.html +1 -1
- data/{docs/NgrokAPI/Services/ApiKeysClient.html → doc/NgrokAPI/Services/APIKeysClient.html} +287 -151
- data/doc/NgrokAPI/Services/AbuseReportsClient.html +723 -0
- data/doc/NgrokAPI/Services/CertificateAuthoritiesClient.html +1489 -0
- data/doc/NgrokAPI/Services/CredentialsClient.html +1534 -0
- data/doc/NgrokAPI/Services/EndpointCircuitBreakerModuleClient.html +1071 -0
- data/doc/NgrokAPI/Services/EndpointCompressionModuleClient.html +1071 -0
- data/doc/NgrokAPI/Services/EndpointConfigurationsClient.html +473 -371
- data/doc/NgrokAPI/Services/EndpointIPPolicyModuleClient.html +1071 -0
- data/doc/NgrokAPI/Services/EndpointLoggingModuleClient.html +1071 -0
- data/doc/NgrokAPI/Services/EndpointMutualTLSModuleClient.html +1071 -0
- data/doc/NgrokAPI/Services/EndpointOAuthModuleClient.html +1071 -0
- data/doc/NgrokAPI/Services/EndpointOIDCModuleClient.html +1071 -0
- data/doc/NgrokAPI/Services/EndpointRequestHeadersModuleClient.html +1071 -0
- data/doc/NgrokAPI/Services/EndpointResponseHeadersModuleClient.html +1071 -0
- data/doc/NgrokAPI/Services/EndpointSAMLModuleClient.html +1071 -0
- data/doc/NgrokAPI/Services/EndpointTLSTerminationModuleClient.html +1071 -0
- data/doc/NgrokAPI/Services/EndpointWebhookValidationModuleClient.html +1071 -0
- data/doc/NgrokAPI/Services/EventDestinationsClient.html +1609 -0
- data/doc/NgrokAPI/Services/EventSourcesClient.html +1348 -0
- data/doc/NgrokAPI/Services/EventStreamsClient.html +1691 -0
- data/doc/NgrokAPI/Services/EventSubscriptionsClient.html +1603 -0
- data/doc/NgrokAPI/Services/IPPoliciesClient.html +1488 -0
- data/doc/NgrokAPI/Services/IPPolicyRulesClient.html +1550 -0
- data/doc/NgrokAPI/Services/IPRestrictionsClient.html +1620 -0
- data/doc/NgrokAPI/Services/IPWhitelistClient.html +1488 -0
- data/doc/NgrokAPI/Services/ReservedAddrsClient.html +1793 -0
- data/doc/NgrokAPI/Services/ReservedDomainsClient.html +518 -333
- data/doc/NgrokAPI/Services/SSHCertificateAuthoritiesClient.html +1532 -0
- data/doc/NgrokAPI/Services/SSHCredentialsClient.html +1552 -0
- data/doc/NgrokAPI/Services/SSHHostCertificatesClient.html +1573 -0
- data/doc/NgrokAPI/Services/SSHUserCertificatesClient.html +1617 -0
- data/{docs/NgrokAPI/Services/TlsCertificatesClient.html → doc/NgrokAPI/Services/TLSCertificatesClient.html} +290 -198
- data/doc/NgrokAPI/Services/TunnelSessionsClient.html +1468 -0
- data/doc/NgrokAPI/Services/TunnelsClient.html +513 -0
- data/doc/NgrokAPI/Services.html +4 -4
- data/doc/NgrokAPI.html +3 -3
- data/doc/_index.html +624 -28
- data/doc/class_list.html +1 -1
- data/doc/file.README.html +1 -1
- data/doc/index.html +1 -1
- data/doc/method_list.html +7318 -286
- data/doc/top-level-namespace.html +1 -1
- data/docs/.gitkeep +0 -0
- data/docs/NgrokAPI/Client.html +1499 -125
- data/docs/NgrokAPI/Error.html +1 -1
- data/docs/NgrokAPI/Errors/NotFoundError.html +1 -1
- data/docs/NgrokAPI/Errors.html +1 -1
- data/docs/NgrokAPI/HttpClient.html +1 -1
- data/docs/NgrokAPI/Models/{ApiKey.html → APIKey.html} +108 -177
- data/docs/NgrokAPI/Models/AWSAuth.html +617 -0
- data/docs/NgrokAPI/Models/AWSCredentials.html +617 -0
- data/docs/NgrokAPI/Models/AWSRole.html +543 -0
- data/docs/NgrokAPI/Models/AbuseReport.html +987 -0
- data/docs/NgrokAPI/Models/AbuseReportHostname.html +617 -0
- data/docs/NgrokAPI/Models/CertificateAuthority.html +1439 -0
- data/docs/NgrokAPI/Models/Credential.html +1149 -0
- data/docs/NgrokAPI/Models/EndpointCircuitBreaker.html +913 -0
- data/docs/NgrokAPI/Models/EndpointCompression.html +543 -0
- data/docs/NgrokAPI/Models/EndpointConfiguration.html +1321 -510
- data/docs/NgrokAPI/Models/EndpointIPPolicy.html +617 -0
- data/docs/NgrokAPI/Models/EndpointIPPolicyMutate.html +617 -0
- data/docs/NgrokAPI/Models/EndpointLogging.html +617 -0
- data/docs/NgrokAPI/Models/EndpointLoggingMutate.html +617 -0
- data/docs/NgrokAPI/Models/EndpointMutualTLS.html +617 -0
- data/docs/NgrokAPI/Models/EndpointMutualTLSMutate.html +617 -0
- data/docs/NgrokAPI/Models/EndpointOAuth.html +987 -0
- data/docs/NgrokAPI/Models/EndpointOAuthFacebook.html +839 -0
- data/docs/NgrokAPI/Models/EndpointOAuthGitHub.html +987 -0
- data/docs/NgrokAPI/Models/EndpointOAuthGoogle.html +839 -0
- data/docs/NgrokAPI/Models/EndpointOAuthMicrosoft.html +839 -0
- data/docs/NgrokAPI/Models/EndpointOAuthProvider.html +765 -0
- data/docs/NgrokAPI/Models/EndpointOIDC.html +1135 -0
- data/docs/NgrokAPI/Models/EndpointRequestHeaders.html +691 -0
- data/docs/NgrokAPI/Models/EndpointResponseHeaders.html +691 -0
- data/docs/NgrokAPI/Models/EndpointSAML.html +1653 -0
- data/docs/NgrokAPI/Models/EndpointSAMLMutate.html +1283 -0
- data/docs/NgrokAPI/Models/EndpointTLSTermination.html +691 -0
- data/docs/NgrokAPI/Models/EndpointWebhookValidation.html +691 -0
- data/docs/NgrokAPI/Models/EventDestination.html +1058 -0
- data/docs/NgrokAPI/Models/EventSource.html +765 -0
- data/docs/NgrokAPI/Models/EventSourceReplace.html +691 -0
- data/docs/NgrokAPI/Models/EventStream.html +1309 -0
- data/docs/NgrokAPI/Models/EventSubscription.html +1058 -0
- data/docs/NgrokAPI/Models/EventTarget.html +765 -0
- data/docs/NgrokAPI/Models/EventTargetCloudwatchLogs.html +617 -0
- data/docs/NgrokAPI/Models/EventTargetFirehose.html +617 -0
- data/docs/NgrokAPI/Models/EventTargetKinesis.html +617 -0
- data/docs/NgrokAPI/Models/IPPolicy.html +1069 -0
- data/docs/NgrokAPI/Models/IPPolicyRule.html +1149 -0
- data/docs/NgrokAPI/Models/IPRestriction.html +1132 -0
- data/docs/NgrokAPI/Models/{TlsCertificate.html → IPWhitelistEntry.html} +168 -163
- data/docs/NgrokAPI/Models/Listable.html +1 -1
- data/docs/NgrokAPI/Models/Ref.html +617 -0
- data/docs/NgrokAPI/Models/ReservedAddr.html +1132 -0
- data/docs/NgrokAPI/Models/ReservedDomain.html +111 -1107
- data/docs/NgrokAPI/Models/ReservedDomainCertJob.html +839 -0
- data/docs/NgrokAPI/Models/ReservedDomainCertNSTarget.html +617 -0
- data/docs/NgrokAPI/Models/ReservedDomainCertPolicy.html +617 -0
- data/docs/NgrokAPI/Models/ReservedDomainCertStatus.html +617 -0
- data/docs/NgrokAPI/Models/SSHCertificateAuthority.html +1143 -0
- data/docs/NgrokAPI/Models/SSHCredential.html +1149 -0
- data/docs/NgrokAPI/Models/SSHHostCertificate.html +1513 -0
- data/docs/NgrokAPI/Models/SSHUserCertificate.html +1661 -0
- data/docs/NgrokAPI/Models/TLSCertificate.html +2179 -0
- data/docs/NgrokAPI/Models/TLSCertificateSANs.html +617 -0
- data/docs/NgrokAPI/Models/Tunnel.html +987 -0
- data/docs/NgrokAPI/Models/TunnelSession.html +1209 -0
- data/docs/NgrokAPI/Models.html +4 -4
- data/docs/NgrokAPI/PagedIterator.html +1 -1
- data/{doc/NgrokAPI/Services/ApiKeysClient.html → docs/NgrokAPI/Services/APIKeysClient.html} +287 -151
- data/docs/NgrokAPI/Services/AbuseReportsClient.html +723 -0
- data/docs/NgrokAPI/Services/CertificateAuthoritiesClient.html +1489 -0
- data/docs/NgrokAPI/Services/CredentialsClient.html +1534 -0
- data/docs/NgrokAPI/Services/EndpointCircuitBreakerModuleClient.html +1071 -0
- data/docs/NgrokAPI/Services/EndpointCompressionModuleClient.html +1071 -0
- data/docs/NgrokAPI/Services/EndpointConfigurationsClient.html +473 -371
- data/docs/NgrokAPI/Services/EndpointIPPolicyModuleClient.html +1071 -0
- data/docs/NgrokAPI/Services/EndpointLoggingModuleClient.html +1071 -0
- data/docs/NgrokAPI/Services/EndpointMutualTLSModuleClient.html +1071 -0
- data/docs/NgrokAPI/Services/EndpointOAuthModuleClient.html +1071 -0
- data/docs/NgrokAPI/Services/EndpointOIDCModuleClient.html +1071 -0
- data/docs/NgrokAPI/Services/EndpointRequestHeadersModuleClient.html +1071 -0
- data/docs/NgrokAPI/Services/EndpointResponseHeadersModuleClient.html +1071 -0
- data/docs/NgrokAPI/Services/EndpointSAMLModuleClient.html +1071 -0
- data/docs/NgrokAPI/Services/EndpointTLSTerminationModuleClient.html +1071 -0
- data/docs/NgrokAPI/Services/EndpointWebhookValidationModuleClient.html +1071 -0
- data/docs/NgrokAPI/Services/EventDestinationsClient.html +1609 -0
- data/docs/NgrokAPI/Services/EventSourcesClient.html +1348 -0
- data/docs/NgrokAPI/Services/EventStreamsClient.html +1691 -0
- data/docs/NgrokAPI/Services/EventSubscriptionsClient.html +1603 -0
- data/docs/NgrokAPI/Services/IPPoliciesClient.html +1488 -0
- data/docs/NgrokAPI/Services/IPPolicyRulesClient.html +1550 -0
- data/docs/NgrokAPI/Services/IPRestrictionsClient.html +1620 -0
- data/docs/NgrokAPI/Services/IPWhitelistClient.html +1488 -0
- data/docs/NgrokAPI/Services/ReservedAddrsClient.html +1793 -0
- data/docs/NgrokAPI/Services/ReservedDomainsClient.html +518 -333
- data/docs/NgrokAPI/Services/SSHCertificateAuthoritiesClient.html +1532 -0
- data/docs/NgrokAPI/Services/SSHCredentialsClient.html +1552 -0
- data/docs/NgrokAPI/Services/SSHHostCertificatesClient.html +1573 -0
- data/docs/NgrokAPI/Services/SSHUserCertificatesClient.html +1617 -0
- data/{doc/NgrokAPI/Services/TlsCertificatesClient.html → docs/NgrokAPI/Services/TLSCertificatesClient.html} +290 -198
- data/docs/NgrokAPI/Services/TunnelSessionsClient.html +1468 -0
- data/docs/NgrokAPI/Services/TunnelsClient.html +513 -0
- data/docs/NgrokAPI/Services.html +4 -4
- data/docs/NgrokAPI.html +3 -3
- data/docs/_index.html +624 -28
- data/docs/class_list.html +1 -1
- data/docs/file.README.html +1 -1
- data/docs/index.html +1 -1
- data/docs/method_list.html +7318 -286
- data/docs/top-level-namespace.html +1 -1
- data/lib/ngrokapi/client.rb +218 -49
- data/lib/ngrokapi/models/abuse_report.rb +37 -0
- data/lib/ngrokapi/models/abuse_report_hostname.rb +27 -0
- data/lib/ngrokapi/models/api_key.rb +62 -64
- data/lib/ngrokapi/models/aws_auth.rb +27 -0
- data/lib/ngrokapi/models/aws_credentials.rb +27 -0
- data/lib/ngrokapi/models/aws_role.rb +25 -0
- data/lib/ngrokapi/models/certificate_authority.rb +72 -0
- data/lib/ngrokapi/models/credential.rb +67 -0
- data/lib/ngrokapi/models/endpoint_circuit_breaker.rb +35 -0
- data/lib/ngrokapi/models/endpoint_compression.rb +25 -0
- data/lib/ngrokapi/models/endpoint_configuration.rb +130 -119
- data/lib/ngrokapi/models/endpoint_ip_policy.rb +27 -0
- data/lib/ngrokapi/models/endpoint_ip_policy_mutate.rb +27 -0
- data/lib/ngrokapi/models/endpoint_logging.rb +27 -0
- data/lib/ngrokapi/models/endpoint_logging_mutate.rb +27 -0
- data/lib/ngrokapi/models/endpoint_mutual_tls.rb +27 -0
- data/lib/ngrokapi/models/endpoint_mutual_tls_mutate.rb +27 -0
- data/lib/ngrokapi/models/endpoint_o_auth.rb +37 -0
- data/lib/ngrokapi/models/endpoint_o_auth_facebook.rb +33 -0
- data/lib/ngrokapi/models/endpoint_o_auth_git_hub.rb +37 -0
- data/lib/ngrokapi/models/endpoint_o_auth_google.rb +33 -0
- data/lib/ngrokapi/models/endpoint_o_auth_microsoft.rb +33 -0
- data/lib/ngrokapi/models/endpoint_o_auth_provider.rb +31 -0
- data/lib/ngrokapi/models/endpoint_oidc.rb +41 -0
- data/lib/ngrokapi/models/endpoint_request_headers.rb +29 -0
- data/lib/ngrokapi/models/endpoint_response_headers.rb +29 -0
- data/lib/ngrokapi/models/endpoint_saml.rb +55 -0
- data/lib/ngrokapi/models/endpoint_saml_mutate.rb +45 -0
- data/lib/ngrokapi/models/endpoint_tls_termination.rb +29 -0
- data/lib/ngrokapi/models/endpoint_webhook_validation.rb +29 -0
- data/lib/ngrokapi/models/event_destination.rb +49 -0
- data/lib/ngrokapi/models/event_source.rb +31 -0
- data/lib/ngrokapi/models/event_source_replace.rb +29 -0
- data/lib/ngrokapi/models/event_stream.rb +77 -0
- data/lib/ngrokapi/models/event_subscription.rb +47 -0
- data/lib/ngrokapi/models/event_target.rb +31 -0
- data/lib/ngrokapi/models/event_target_cloudwatch_logs.rb +27 -0
- data/lib/ngrokapi/models/event_target_firehose.rb +27 -0
- data/lib/ngrokapi/models/event_target_kinesis.rb +27 -0
- data/lib/ngrokapi/models/ip_policy.rb +64 -0
- data/lib/ngrokapi/models/ip_policy_rule.rb +67 -0
- data/lib/ngrokapi/models/ip_restriction.rb +49 -0
- data/lib/ngrokapi/models/ip_whitelist_entry.rb +62 -0
- data/lib/ngrokapi/models/ref.rb +27 -0
- data/lib/ngrokapi/models/reserved_addr.rb +49 -0
- data/lib/ngrokapi/models/reserved_domain.rb +59 -211
- data/lib/ngrokapi/models/reserved_domain_cert_job.rb +33 -0
- data/lib/ngrokapi/models/reserved_domain_cert_ns_target.rb +27 -0
- data/lib/ngrokapi/models/reserved_domain_cert_policy.rb +27 -0
- data/lib/ngrokapi/models/reserved_domain_cert_status.rb +27 -0
- data/lib/ngrokapi/models/ssh_certificate_authority.rb +64 -0
- data/lib/ngrokapi/models/ssh_credential.rb +67 -0
- data/lib/ngrokapi/models/ssh_host_certificate.rb +74 -0
- data/lib/ngrokapi/models/ssh_user_certificate.rb +78 -0
- data/lib/ngrokapi/models/tls_certificate.rb +92 -62
- data/lib/ngrokapi/models/tls_certificate_sa_ns.rb +27 -0
- data/lib/ngrokapi/models/tunnel.rb +37 -0
- data/lib/ngrokapi/models/tunnel_session.rb +43 -0
- data/lib/ngrokapi/services/.gitkeep +0 -0
- data/lib/ngrokapi/services/abuse_reports_client.rb +84 -0
- data/lib/ngrokapi/services/api_keys_client.rb +203 -144
- data/lib/ngrokapi/services/certificate_authorities_client.rb +204 -0
- data/lib/ngrokapi/services/credentials_client.rb +212 -0
- data/lib/ngrokapi/services/endpoint_circuit_breaker_module_client.rb +122 -0
- data/lib/ngrokapi/services/endpoint_compression_module_client.rb +122 -0
- data/lib/ngrokapi/services/endpoint_configurations_client.rb +324 -313
- data/lib/ngrokapi/services/endpoint_ip_policy_module_client.rb +122 -0
- data/lib/ngrokapi/services/endpoint_logging_module_client.rb +122 -0
- data/lib/ngrokapi/services/endpoint_mutual_tls_module_client.rb +122 -0
- data/lib/ngrokapi/services/endpoint_o_auth_module_client.rb +122 -0
- data/lib/ngrokapi/services/endpoint_oidc_module_client.rb +122 -0
- data/lib/ngrokapi/services/endpoint_request_headers_module_client.rb +122 -0
- data/lib/ngrokapi/services/endpoint_response_headers_module_client.rb +122 -0
- data/lib/ngrokapi/services/endpoint_saml_module_client.rb +122 -0
- data/lib/ngrokapi/services/endpoint_tls_termination_module_client.rb +122 -0
- data/lib/ngrokapi/services/endpoint_webhook_validation_module_client.rb +122 -0
- data/lib/ngrokapi/services/event_destinations_client.rb +222 -0
- data/lib/ngrokapi/services/event_sources_client.rb +177 -0
- data/lib/ngrokapi/services/event_streams_client.rb +226 -0
- data/lib/ngrokapi/services/event_subscriptions_client.rb +213 -0
- data/lib/ngrokapi/services/ip_policies_client.rb +208 -0
- data/lib/ngrokapi/services/ip_policy_rules_client.rb +210 -0
- data/lib/ngrokapi/services/ip_restrictions_client.rb +223 -0
- data/lib/ngrokapi/services/ip_whitelist_client.rb +202 -0
- data/lib/ngrokapi/services/reserved_addrs_client.rb +246 -0
- data/lib/ngrokapi/services/reserved_domains_client.rb +382 -313
- data/lib/ngrokapi/services/ssh_certificate_authorities_client.rb +207 -0
- data/lib/ngrokapi/services/ssh_credentials_client.rb +211 -0
- data/lib/ngrokapi/services/ssh_host_certificates_client.rb +214 -0
- data/lib/ngrokapi/services/ssh_user_certificates_client.rb +220 -0
- data/lib/ngrokapi/services/tls_certificates_client.rb +207 -161
- data/lib/ngrokapi/services/tunnel_sessions_client.rb +228 -0
- data/lib/ngrokapi/services/tunnels_client.rb +51 -0
- data/lib/ngrokapi/version.rb +1 -1
- data/spec/ngrokapi/client_spec.rb +139 -33
- data/spec/ngrokapi/models/abuse_report_hostname_spec.rb +21 -0
- data/spec/ngrokapi/models/abuse_report_spec.rb +21 -0
- data/spec/ngrokapi/models/api_key_spec.rb +42 -43
- data/spec/ngrokapi/models/aws_auth_spec.rb +21 -0
- data/spec/ngrokapi/models/aws_credentials_spec.rb +21 -0
- data/spec/ngrokapi/models/aws_role_spec.rb +21 -0
- data/spec/ngrokapi/models/certificate_authority_spec.rb +42 -0
- data/spec/ngrokapi/models/credential_spec.rb +45 -0
- data/spec/ngrokapi/models/endpoint_circuit_breaker_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_compression_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_configuration_spec.rb +78 -0
- data/spec/ngrokapi/models/endpoint_ip_policy_mutate_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_ip_policy_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_logging_mutate_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_logging_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_mutual_tls_mutate_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_mutual_tls_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_o_auth_facebook_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_o_auth_git_hub_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_o_auth_google_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_o_auth_microsoft_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_o_auth_provider_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_o_auth_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_oidc_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_request_headers_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_response_headers_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_saml_mutate_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_saml_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_tls_termination_spec.rb +21 -0
- data/spec/ngrokapi/models/endpoint_webhook_validation_spec.rb +21 -0
- data/spec/ngrokapi/models/event_destination_spec.rb +28 -0
- data/spec/ngrokapi/models/event_source_replace_spec.rb +21 -0
- data/spec/ngrokapi/models/event_source_spec.rb +21 -0
- data/spec/ngrokapi/models/event_stream_spec.rb +51 -0
- data/spec/ngrokapi/models/event_subscription_spec.rb +28 -0
- data/spec/ngrokapi/models/event_target_cloudwatch_logs_spec.rb +21 -0
- data/spec/ngrokapi/models/event_target_firehose_spec.rb +21 -0
- data/spec/ngrokapi/models/event_target_kinesis_spec.rb +21 -0
- data/spec/ngrokapi/models/event_target_spec.rb +21 -0
- data/spec/ngrokapi/models/ip_policy_rule_spec.rb +45 -0
- data/spec/ngrokapi/models/ip_policy_spec.rb +42 -0
- data/spec/ngrokapi/models/ip_restriction_spec.rb +28 -0
- data/spec/ngrokapi/models/ip_whitelist_entry_spec.rb +42 -0
- data/spec/ngrokapi/models/listable_spec.rb +4 -4
- data/spec/ngrokapi/models/ref_spec.rb +21 -0
- data/spec/ngrokapi/models/reserved_addr_spec.rb +28 -0
- data/spec/ngrokapi/models/reserved_domain_cert_job_spec.rb +21 -0
- data/spec/ngrokapi/models/reserved_domain_cert_ns_target_spec.rb +21 -0
- data/spec/ngrokapi/models/reserved_domain_cert_policy_spec.rb +21 -0
- data/spec/ngrokapi/models/reserved_domain_cert_status_spec.rb +21 -0
- data/spec/ngrokapi/models/reserved_domain_spec.rb +28 -100
- data/spec/ngrokapi/models/ssh_certificate_authority_spec.rb +42 -0
- data/spec/ngrokapi/models/ssh_credential_spec.rb +45 -0
- data/spec/ngrokapi/models/ssh_host_certificate_spec.rb +42 -0
- data/spec/ngrokapi/models/ssh_user_certificate_spec.rb +42 -0
- data/spec/ngrokapi/models/tls_certificate_sa_ns_spec.rb +21 -0
- data/spec/ngrokapi/models/tls_certificate_spec.rb +42 -0
- data/spec/ngrokapi/models/tunnel_session_spec.rb +21 -0
- data/spec/ngrokapi/models/tunnel_spec.rb +21 -0
- data/spec/ngrokapi/paged_iterator_spec.rb +5 -5
- data/spec/ngrokapi/services/.gitkeep +0 -0
- data/spec/ngrokapi/services/abuse_reports_client_spec.rb +67 -0
- data/spec/ngrokapi/services/api_keys_client_spec.rb +160 -127
- data/spec/ngrokapi/services/certificate_authorities_client_spec.rb +162 -0
- data/spec/ngrokapi/services/credentials_client_spec.rb +166 -0
- data/spec/ngrokapi/services/endpoint_circuit_breaker_module_client_spec.rb +127 -0
- data/spec/ngrokapi/services/endpoint_compression_module_client_spec.rb +127 -0
- data/spec/ngrokapi/services/endpoint_configurations_client_spec.rb +240 -0
- data/spec/ngrokapi/services/endpoint_ip_policy_module_client_spec.rb +127 -0
- data/spec/ngrokapi/services/endpoint_logging_module_client_spec.rb +127 -0
- data/spec/ngrokapi/services/endpoint_mutual_tls_module_client_spec.rb +127 -0
- data/spec/ngrokapi/services/endpoint_o_auth_module_client_spec.rb +127 -0
- data/spec/ngrokapi/services/endpoint_oidc_module_client_spec.rb +127 -0
- data/spec/ngrokapi/services/endpoint_request_headers_module_client_spec.rb +127 -0
- data/spec/ngrokapi/services/endpoint_response_headers_module_client_spec.rb +127 -0
- data/spec/ngrokapi/services/endpoint_saml_module_client_spec.rb +127 -0
- data/spec/ngrokapi/services/endpoint_tls_termination_module_client_spec.rb +127 -0
- data/spec/ngrokapi/services/endpoint_webhook_validation_module_client_spec.rb +127 -0
- data/spec/ngrokapi/services/event_destinations_client_spec.rb +175 -0
- data/spec/ngrokapi/services/event_sources_client_spec.rb +162 -0
- data/spec/ngrokapi/services/event_streams_client_spec.rb +180 -0
- data/spec/ngrokapi/services/event_subscriptions_client_spec.rb +172 -0
- data/spec/ngrokapi/services/ip_policies_client_spec.rb +162 -0
- data/spec/ngrokapi/services/ip_policy_rules_client_spec.rb +168 -0
- data/spec/ngrokapi/services/ip_restrictions_client_spec.rb +174 -0
- data/spec/ngrokapi/services/ip_whitelist_client_spec.rb +162 -0
- data/spec/ngrokapi/services/reserved_addrs_client_spec.rb +209 -0
- data/spec/ngrokapi/services/reserved_domains_client_spec.rb +352 -0
- data/spec/ngrokapi/services/ssh_certificate_authorities_client_spec.rb +166 -0
- data/spec/ngrokapi/services/ssh_credentials_client_spec.rb +168 -0
- data/spec/ngrokapi/services/ssh_host_certificates_client_spec.rb +170 -0
- data/spec/ngrokapi/services/ssh_user_certificates_client_spec.rb +174 -0
- data/spec/ngrokapi/services/tls_certificates_client_spec.rb +164 -0
- data/spec/ngrokapi/services/tunnel_sessions_client_spec.rb +184 -0
- data/spec/ngrokapi/services/tunnels_client_spec.rb +21 -0
- data/spec/spec_helper.rb +958 -0
- metadata +355 -10
@@ -0,0 +1,212 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module NgrokAPI
|
4
|
+
module Services
|
5
|
+
##
|
6
|
+
# Tunnel Credentials are ngrok agent authtokens. They authorize the ngrok
|
7
|
+
# agent to connect the ngrok service as your account. They are installed with
|
8
|
+
# the ngrok authtoken command or by specifying it in the ngrok.yml
|
9
|
+
# configuration file with the authtoken property.
|
10
|
+
#
|
11
|
+
# https://ngrok.com/docs/api#api-credentials
|
12
|
+
class CredentialsClient
|
13
|
+
# The API path for the requests
|
14
|
+
PATH = '/credentials'
|
15
|
+
# The List Property from the resulting API for list calls
|
16
|
+
LIST_PROPERTY = 'credentials'
|
17
|
+
|
18
|
+
attr_reader :client
|
19
|
+
|
20
|
+
def initialize(client:)
|
21
|
+
@client = client
|
22
|
+
end
|
23
|
+
|
24
|
+
##
|
25
|
+
# Create a new tunnel authtoken credential. This authtoken credential can be used
|
26
|
+
# to start a new tunnel session. The response to this API call is the only time
|
27
|
+
# the generated token is available. If you need it for future use, you must save
|
28
|
+
# it securely yourself.
|
29
|
+
#
|
30
|
+
# @param [string] description human-readable description of who or what will use the credential to authenticate. Optional, max 255 bytes.
|
31
|
+
# @param [string] metadata arbitrary user-defined machine-readable data of this credential. Optional, max 4096 bytes.
|
32
|
+
# @param [List<string>] acl optional list of ACL rules. If unspecified, the credential will have no restrictions. The only allowed ACL rule at this time is the ``bind`` rule. The ``bind`` rule allows the caller to restrict what domains and addresses the token is allowed to bind. For example, to allow the token to open a tunnel on example.ngrok.io your ACL would include the rule ``bind:example.ngrok.io``. Bind rules may specify a leading wildcard to match multiple domains with a common suffix. For example, you may specify a rule of ``bind:*.example.com`` which will allow ``x.example.com``, ``y.example.com``, ``*.example.com``, etc. A rule of ``'*'`` is equivalent to no acl at all and will explicitly permit all actions.
|
33
|
+
# @return [NgrokAPI::Models::Credential] result from the API request
|
34
|
+
#
|
35
|
+
# https://ngrok.com/docs/api#api-credentials-create
|
36
|
+
def create(
|
37
|
+
description: "",
|
38
|
+
metadata: "",
|
39
|
+
acl: []
|
40
|
+
)
|
41
|
+
path = '/credentials'
|
42
|
+
replacements = {
|
43
|
+
}
|
44
|
+
data = {}
|
45
|
+
data[:description] = description if description
|
46
|
+
data[:metadata] = metadata if metadata
|
47
|
+
data[:acl] = acl if acl
|
48
|
+
result = @client.post(path % replacements, data: data)
|
49
|
+
NgrokAPI::Models::Credential.new(client: self, result: result)
|
50
|
+
end
|
51
|
+
|
52
|
+
##
|
53
|
+
# Delete a tunnel authtoken credential by ID
|
54
|
+
#
|
55
|
+
# @param [string] id a resource identifier
|
56
|
+
# @return [NgrokAPI::Models::Empty] result from the API request
|
57
|
+
#
|
58
|
+
# https://ngrok.com/docs/api#api-credentials-delete
|
59
|
+
def delete(
|
60
|
+
id: ""
|
61
|
+
)
|
62
|
+
path = '/credentials/%{id}'
|
63
|
+
replacements = {
|
64
|
+
id: id,
|
65
|
+
}
|
66
|
+
@client.delete(path % replacements)
|
67
|
+
end
|
68
|
+
|
69
|
+
##
|
70
|
+
# Delete a tunnel authtoken credential by ID
|
71
|
+
# Throws an exception if API error.
|
72
|
+
#
|
73
|
+
# @param [string] id a resource identifier
|
74
|
+
# @return [NgrokAPI::Models::Empty] result from the API request
|
75
|
+
#
|
76
|
+
# https://ngrok.com/docs/api#api-credentials-delete
|
77
|
+
def delete!(
|
78
|
+
id: ""
|
79
|
+
)
|
80
|
+
path = '/credentials/%{id}'
|
81
|
+
replacements = {
|
82
|
+
id: id,
|
83
|
+
}
|
84
|
+
@client.delete(path % replacements, danger: true)
|
85
|
+
end
|
86
|
+
|
87
|
+
##
|
88
|
+
# Get detailed information about a tunnel authtoken credential
|
89
|
+
#
|
90
|
+
# @param [string] id a resource identifier
|
91
|
+
# @return [NgrokAPI::Models::Credential] result from the API request
|
92
|
+
#
|
93
|
+
# https://ngrok.com/docs/api#api-credentials-get
|
94
|
+
def get(
|
95
|
+
id: ""
|
96
|
+
)
|
97
|
+
path = '/credentials/%{id}'
|
98
|
+
replacements = {
|
99
|
+
id: id,
|
100
|
+
}
|
101
|
+
data = {}
|
102
|
+
result = @client.get(path % replacements, data: data)
|
103
|
+
NgrokAPI::Models::Credential.new(client: self, result: result)
|
104
|
+
end
|
105
|
+
|
106
|
+
##
|
107
|
+
# Get detailed information about a tunnel authtoken credential
|
108
|
+
# Throws an exception if API error.
|
109
|
+
#
|
110
|
+
# @param [string] id a resource identifier
|
111
|
+
# @return [NgrokAPI::Models::Credential] result from the API request
|
112
|
+
#
|
113
|
+
# https://ngrok.com/docs/api#api-credentials-get
|
114
|
+
def get!(
|
115
|
+
id: ""
|
116
|
+
)
|
117
|
+
path = '/credentials/%{id}'
|
118
|
+
replacements = {
|
119
|
+
id: id,
|
120
|
+
}
|
121
|
+
data = {}
|
122
|
+
result = @client.get(path % replacements, data: data, danger: true)
|
123
|
+
NgrokAPI::Models::Credential.new(client: self, result: result)
|
124
|
+
end
|
125
|
+
|
126
|
+
##
|
127
|
+
# List all tunnel authtoken credentials on this account
|
128
|
+
#
|
129
|
+
# @param [string] before_id
|
130
|
+
# @param [string] limit
|
131
|
+
# @param [string] url optional and mutually exclusive from before_id and limit
|
132
|
+
# @return [NgrokAPI::Models::Listable] result from the API request
|
133
|
+
#
|
134
|
+
# https://ngrok.com/docs/api#api-credentials-list
|
135
|
+
def list(
|
136
|
+
before_id: nil,
|
137
|
+
limit: nil,
|
138
|
+
url: nil
|
139
|
+
)
|
140
|
+
result = @client.list(
|
141
|
+
before_id: before_id,
|
142
|
+
limit: limit,
|
143
|
+
url: url,
|
144
|
+
path: PATH
|
145
|
+
)
|
146
|
+
NgrokAPI::Models::Listable.new(
|
147
|
+
client: self,
|
148
|
+
result: result,
|
149
|
+
list_property: LIST_PROPERTY,
|
150
|
+
klass: NgrokAPI::Models::Credential
|
151
|
+
)
|
152
|
+
end
|
153
|
+
|
154
|
+
##
|
155
|
+
# Update attributes of an tunnel authtoken credential by ID
|
156
|
+
#
|
157
|
+
# @param [string] id
|
158
|
+
# @param [string] description human-readable description of who or what will use the credential to authenticate. Optional, max 255 bytes.
|
159
|
+
# @param [string] metadata arbitrary user-defined machine-readable data of this credential. Optional, max 4096 bytes.
|
160
|
+
# @param [List<string>] acl optional list of ACL rules. If unspecified, the credential will have no restrictions. The only allowed ACL rule at this time is the ``bind`` rule. The ``bind`` rule allows the caller to restrict what domains and addresses the token is allowed to bind. For example, to allow the token to open a tunnel on example.ngrok.io your ACL would include the rule ``bind:example.ngrok.io``. Bind rules may specify a leading wildcard to match multiple domains with a common suffix. For example, you may specify a rule of ``bind:*.example.com`` which will allow ``x.example.com``, ``y.example.com``, ``*.example.com``, etc. A rule of ``'*'`` is equivalent to no acl at all and will explicitly permit all actions.
|
161
|
+
# @return [NgrokAPI::Models::Credential] result from the API request
|
162
|
+
#
|
163
|
+
# https://ngrok.com/docs/api#api-credentials-update
|
164
|
+
def update(
|
165
|
+
id: "",
|
166
|
+
description: nil,
|
167
|
+
metadata: nil,
|
168
|
+
acl: nil
|
169
|
+
)
|
170
|
+
path = '/credentials/%{id}'
|
171
|
+
replacements = {
|
172
|
+
id: id,
|
173
|
+
}
|
174
|
+
data = {}
|
175
|
+
data[:description] = description if description
|
176
|
+
data[:metadata] = metadata if metadata
|
177
|
+
data[:acl] = acl if acl
|
178
|
+
result = @client.patch(path % replacements, data: data)
|
179
|
+
NgrokAPI::Models::Credential.new(client: self, result: result)
|
180
|
+
end
|
181
|
+
|
182
|
+
##
|
183
|
+
# Update attributes of an tunnel authtoken credential by ID
|
184
|
+
# Throws an exception if API error.
|
185
|
+
#
|
186
|
+
# @param [string] id
|
187
|
+
# @param [string] description human-readable description of who or what will use the credential to authenticate. Optional, max 255 bytes.
|
188
|
+
# @param [string] metadata arbitrary user-defined machine-readable data of this credential. Optional, max 4096 bytes.
|
189
|
+
# @param [List<string>] acl optional list of ACL rules. If unspecified, the credential will have no restrictions. The only allowed ACL rule at this time is the ``bind`` rule. The ``bind`` rule allows the caller to restrict what domains and addresses the token is allowed to bind. For example, to allow the token to open a tunnel on example.ngrok.io your ACL would include the rule ``bind:example.ngrok.io``. Bind rules may specify a leading wildcard to match multiple domains with a common suffix. For example, you may specify a rule of ``bind:*.example.com`` which will allow ``x.example.com``, ``y.example.com``, ``*.example.com``, etc. A rule of ``'*'`` is equivalent to no acl at all and will explicitly permit all actions.
|
190
|
+
# @return [NgrokAPI::Models::Credential] result from the API request
|
191
|
+
#
|
192
|
+
# https://ngrok.com/docs/api#api-credentials-update
|
193
|
+
def update!(
|
194
|
+
id: "",
|
195
|
+
description: nil,
|
196
|
+
metadata: nil,
|
197
|
+
acl: nil
|
198
|
+
)
|
199
|
+
path = '/credentials/%{id}'
|
200
|
+
replacements = {
|
201
|
+
id: id,
|
202
|
+
}
|
203
|
+
data = {}
|
204
|
+
data[:description] = description if description
|
205
|
+
data[:metadata] = metadata if metadata
|
206
|
+
data[:acl] = acl if acl
|
207
|
+
result = @client.patch(path % replacements, data: data, danger: true)
|
208
|
+
NgrokAPI::Models::Credential.new(client: self, result: result)
|
209
|
+
end
|
210
|
+
end
|
211
|
+
end
|
212
|
+
end
|
@@ -0,0 +1,122 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module NgrokAPI
|
4
|
+
module Services
|
5
|
+
##
|
6
|
+
# https://ngrok.com/docs/api#api-endpoint-circuit-breaker-module
|
7
|
+
class EndpointCircuitBreakerModuleClient
|
8
|
+
# The API path for the requests
|
9
|
+
PATH = '/endpoint_configurations/%{id}/circuit_breaker'
|
10
|
+
|
11
|
+
attr_reader :client
|
12
|
+
|
13
|
+
def initialize(client:)
|
14
|
+
@client = client
|
15
|
+
end
|
16
|
+
|
17
|
+
##
|
18
|
+
# @param [string] id
|
19
|
+
# @param [EndpointCircuitBreaker] a_module
|
20
|
+
# @return [NgrokAPI::Models::EndpointCircuitBreaker] result from the API request
|
21
|
+
#
|
22
|
+
# https://ngrok.com/docs/api#api-endpoint-circuit-breaker-module-replace
|
23
|
+
def replace(
|
24
|
+
id: "",
|
25
|
+
a_module: nil
|
26
|
+
)
|
27
|
+
path = '/endpoint_configurations/%{id}/circuit_breaker'
|
28
|
+
replacements = {
|
29
|
+
id: id,
|
30
|
+
}
|
31
|
+
data = {}
|
32
|
+
data[:module] = a_module if a_module
|
33
|
+
result = @client.put(path % replacements, data: data)
|
34
|
+
NgrokAPI::Models::EndpointCircuitBreaker.new(client: self, result: result)
|
35
|
+
end
|
36
|
+
|
37
|
+
##
|
38
|
+
# @param [string] id
|
39
|
+
# @param [EndpointCircuitBreaker] a_module
|
40
|
+
# @return [NgrokAPI::Models::EndpointCircuitBreaker] result from the API request
|
41
|
+
#
|
42
|
+
# https://ngrok.com/docs/api#api-endpoint-circuit-breaker-module-replace
|
43
|
+
def replace!(
|
44
|
+
id: "",
|
45
|
+
a_module: nil
|
46
|
+
)
|
47
|
+
path = '/endpoint_configurations/%{id}/circuit_breaker'
|
48
|
+
replacements = {
|
49
|
+
id: id,
|
50
|
+
}
|
51
|
+
data = {}
|
52
|
+
data[:module] = a_module if a_module
|
53
|
+
result = @client.put(path % replacements, data: data, danger: true)
|
54
|
+
NgrokAPI::Models::EndpointCircuitBreaker.new(client: self, result: result)
|
55
|
+
end
|
56
|
+
|
57
|
+
##
|
58
|
+
# @param [string] id a resource identifier
|
59
|
+
# @return [NgrokAPI::Models::EndpointCircuitBreaker] result from the API request
|
60
|
+
#
|
61
|
+
# https://ngrok.com/docs/api#api-endpoint-circuit-breaker-module-get
|
62
|
+
def get(
|
63
|
+
id: ""
|
64
|
+
)
|
65
|
+
path = '/endpoint_configurations/%{id}/circuit_breaker'
|
66
|
+
replacements = {
|
67
|
+
id: id,
|
68
|
+
}
|
69
|
+
data = {}
|
70
|
+
result = @client.get(path % replacements, data: data)
|
71
|
+
NgrokAPI::Models::EndpointCircuitBreaker.new(client: self, result: result)
|
72
|
+
end
|
73
|
+
|
74
|
+
##
|
75
|
+
# @param [string] id a resource identifier
|
76
|
+
# @return [NgrokAPI::Models::EndpointCircuitBreaker] result from the API request
|
77
|
+
#
|
78
|
+
# https://ngrok.com/docs/api#api-endpoint-circuit-breaker-module-get
|
79
|
+
def get!(
|
80
|
+
id: ""
|
81
|
+
)
|
82
|
+
path = '/endpoint_configurations/%{id}/circuit_breaker'
|
83
|
+
replacements = {
|
84
|
+
id: id,
|
85
|
+
}
|
86
|
+
data = {}
|
87
|
+
result = @client.get(path % replacements, data: data, danger: true)
|
88
|
+
NgrokAPI::Models::EndpointCircuitBreaker.new(client: self, result: result)
|
89
|
+
end
|
90
|
+
|
91
|
+
##
|
92
|
+
# @param [string] id a resource identifier
|
93
|
+
# @return [NgrokAPI::Models::Empty] result from the API request
|
94
|
+
#
|
95
|
+
# https://ngrok.com/docs/api#api-endpoint-circuit-breaker-module-delete
|
96
|
+
def delete(
|
97
|
+
id: ""
|
98
|
+
)
|
99
|
+
path = '/endpoint_configurations/%{id}/circuit_breaker'
|
100
|
+
replacements = {
|
101
|
+
id: id,
|
102
|
+
}
|
103
|
+
@client.delete(path % replacements)
|
104
|
+
end
|
105
|
+
|
106
|
+
##
|
107
|
+
# @param [string] id a resource identifier
|
108
|
+
# @return [NgrokAPI::Models::Empty] result from the API request
|
109
|
+
#
|
110
|
+
# https://ngrok.com/docs/api#api-endpoint-circuit-breaker-module-delete
|
111
|
+
def delete!(
|
112
|
+
id: ""
|
113
|
+
)
|
114
|
+
path = '/endpoint_configurations/%{id}/circuit_breaker'
|
115
|
+
replacements = {
|
116
|
+
id: id,
|
117
|
+
}
|
118
|
+
@client.delete(path % replacements, danger: true)
|
119
|
+
end
|
120
|
+
end
|
121
|
+
end
|
122
|
+
end
|
@@ -0,0 +1,122 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module NgrokAPI
|
4
|
+
module Services
|
5
|
+
##
|
6
|
+
# https://ngrok.com/docs/api#api-endpoint-compression-module
|
7
|
+
class EndpointCompressionModuleClient
|
8
|
+
# The API path for the requests
|
9
|
+
PATH = '/endpoint_configurations/%{id}/compression'
|
10
|
+
|
11
|
+
attr_reader :client
|
12
|
+
|
13
|
+
def initialize(client:)
|
14
|
+
@client = client
|
15
|
+
end
|
16
|
+
|
17
|
+
##
|
18
|
+
# @param [string] id
|
19
|
+
# @param [EndpointCompression] a_module
|
20
|
+
# @return [NgrokAPI::Models::EndpointCompression] result from the API request
|
21
|
+
#
|
22
|
+
# https://ngrok.com/docs/api#api-endpoint-compression-module-replace
|
23
|
+
def replace(
|
24
|
+
id: "",
|
25
|
+
a_module: nil
|
26
|
+
)
|
27
|
+
path = '/endpoint_configurations/%{id}/compression'
|
28
|
+
replacements = {
|
29
|
+
id: id,
|
30
|
+
}
|
31
|
+
data = {}
|
32
|
+
data[:module] = a_module if a_module
|
33
|
+
result = @client.put(path % replacements, data: data)
|
34
|
+
NgrokAPI::Models::EndpointCompression.new(client: self, result: result)
|
35
|
+
end
|
36
|
+
|
37
|
+
##
|
38
|
+
# @param [string] id
|
39
|
+
# @param [EndpointCompression] a_module
|
40
|
+
# @return [NgrokAPI::Models::EndpointCompression] result from the API request
|
41
|
+
#
|
42
|
+
# https://ngrok.com/docs/api#api-endpoint-compression-module-replace
|
43
|
+
def replace!(
|
44
|
+
id: "",
|
45
|
+
a_module: nil
|
46
|
+
)
|
47
|
+
path = '/endpoint_configurations/%{id}/compression'
|
48
|
+
replacements = {
|
49
|
+
id: id,
|
50
|
+
}
|
51
|
+
data = {}
|
52
|
+
data[:module] = a_module if a_module
|
53
|
+
result = @client.put(path % replacements, data: data, danger: true)
|
54
|
+
NgrokAPI::Models::EndpointCompression.new(client: self, result: result)
|
55
|
+
end
|
56
|
+
|
57
|
+
##
|
58
|
+
# @param [string] id a resource identifier
|
59
|
+
# @return [NgrokAPI::Models::EndpointCompression] result from the API request
|
60
|
+
#
|
61
|
+
# https://ngrok.com/docs/api#api-endpoint-compression-module-get
|
62
|
+
def get(
|
63
|
+
id: ""
|
64
|
+
)
|
65
|
+
path = '/endpoint_configurations/%{id}/compression'
|
66
|
+
replacements = {
|
67
|
+
id: id,
|
68
|
+
}
|
69
|
+
data = {}
|
70
|
+
result = @client.get(path % replacements, data: data)
|
71
|
+
NgrokAPI::Models::EndpointCompression.new(client: self, result: result)
|
72
|
+
end
|
73
|
+
|
74
|
+
##
|
75
|
+
# @param [string] id a resource identifier
|
76
|
+
# @return [NgrokAPI::Models::EndpointCompression] result from the API request
|
77
|
+
#
|
78
|
+
# https://ngrok.com/docs/api#api-endpoint-compression-module-get
|
79
|
+
def get!(
|
80
|
+
id: ""
|
81
|
+
)
|
82
|
+
path = '/endpoint_configurations/%{id}/compression'
|
83
|
+
replacements = {
|
84
|
+
id: id,
|
85
|
+
}
|
86
|
+
data = {}
|
87
|
+
result = @client.get(path % replacements, data: data, danger: true)
|
88
|
+
NgrokAPI::Models::EndpointCompression.new(client: self, result: result)
|
89
|
+
end
|
90
|
+
|
91
|
+
##
|
92
|
+
# @param [string] id a resource identifier
|
93
|
+
# @return [NgrokAPI::Models::Empty] result from the API request
|
94
|
+
#
|
95
|
+
# https://ngrok.com/docs/api#api-endpoint-compression-module-delete
|
96
|
+
def delete(
|
97
|
+
id: ""
|
98
|
+
)
|
99
|
+
path = '/endpoint_configurations/%{id}/compression'
|
100
|
+
replacements = {
|
101
|
+
id: id,
|
102
|
+
}
|
103
|
+
@client.delete(path % replacements)
|
104
|
+
end
|
105
|
+
|
106
|
+
##
|
107
|
+
# @param [string] id a resource identifier
|
108
|
+
# @return [NgrokAPI::Models::Empty] result from the API request
|
109
|
+
#
|
110
|
+
# https://ngrok.com/docs/api#api-endpoint-compression-module-delete
|
111
|
+
def delete!(
|
112
|
+
id: ""
|
113
|
+
)
|
114
|
+
path = '/endpoint_configurations/%{id}/compression'
|
115
|
+
replacements = {
|
116
|
+
id: id,
|
117
|
+
}
|
118
|
+
@client.delete(path % replacements, danger: true)
|
119
|
+
end
|
120
|
+
end
|
121
|
+
end
|
122
|
+
end
|