ory-oathkeeper-client 0.0.0.alpha38
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/Gemfile +9 -0
- data/README.md +184 -0
- data/Rakefile +10 -0
- data/docs/ApiApi.md +450 -0
- data/docs/CreateRuleCreated.md +18 -0
- data/docs/CreateRuleForbidden.md +18 -0
- data/docs/CreateRuleForbiddenBody.md +28 -0
- data/docs/CreateRuleInternalServerError.md +18 -0
- data/docs/CreateRuleInternalServerErrorBody.md +28 -0
- data/docs/CreateRuleUnauthorized.md +18 -0
- data/docs/CreateRuleUnauthorizedBody.md +28 -0
- data/docs/DecisionsForbidden.md +18 -0
- data/docs/DecisionsForbiddenBody.md +28 -0
- data/docs/DecisionsInternalServerError.md +18 -0
- data/docs/DecisionsInternalServerErrorBody.md +28 -0
- data/docs/DecisionsNotFound.md +18 -0
- data/docs/DecisionsNotFoundBody.md +28 -0
- data/docs/DecisionsUnauthorized.md +18 -0
- data/docs/DecisionsUnauthorizedBody.md +28 -0
- data/docs/DeleteRuleForbidden.md +18 -0
- data/docs/DeleteRuleForbiddenBody.md +28 -0
- data/docs/DeleteRuleInternalServerError.md +18 -0
- data/docs/DeleteRuleInternalServerErrorBody.md +28 -0
- data/docs/DeleteRuleNotFound.md +18 -0
- data/docs/DeleteRuleNotFoundBody.md +28 -0
- data/docs/DeleteRuleUnauthorized.md +18 -0
- data/docs/DeleteRuleUnauthorizedBody.md +28 -0
- data/docs/GetRuleForbidden.md +18 -0
- data/docs/GetRuleForbiddenBody.md +28 -0
- data/docs/GetRuleInternalServerError.md +18 -0
- data/docs/GetRuleInternalServerErrorBody.md +28 -0
- data/docs/GetRuleNotFound.md +18 -0
- data/docs/GetRuleNotFoundBody.md +28 -0
- data/docs/GetRuleOK.md +18 -0
- data/docs/GetRuleUnauthorized.md +18 -0
- data/docs/GetRuleUnauthorizedBody.md +28 -0
- data/docs/GetWellKnownForbidden.md +18 -0
- data/docs/GetWellKnownForbiddenBody.md +28 -0
- data/docs/GetWellKnownJSONWebKeysInternalServerError.md +18 -0
- data/docs/GetWellKnownJSONWebKeysInternalServerErrorBody.md +28 -0
- data/docs/GetWellKnownJSONWebKeysOK.md +18 -0
- data/docs/GetWellKnownOK.md +18 -0
- data/docs/GetWellKnownUnauthorized.md +18 -0
- data/docs/GetWellKnownUnauthorizedBody.md +28 -0
- data/docs/HealthApi.md +96 -0
- data/docs/HealthNotReadyStatus.md +18 -0
- data/docs/HealthStatus.md +18 -0
- data/docs/InlineResponse500.md +28 -0
- data/docs/IsInstanceAliveInternalServerError.md +18 -0
- data/docs/IsInstanceAliveInternalServerErrorBody.md +28 -0
- data/docs/IsInstanceAliveOK.md +18 -0
- data/docs/JsonWebKey.md +50 -0
- data/docs/JsonWebKeySet.md +18 -0
- data/docs/JudgeForbidden.md +18 -0
- data/docs/JudgeForbiddenBody.md +28 -0
- data/docs/JudgeInternalServerError.md +18 -0
- data/docs/JudgeInternalServerErrorBody.md +28 -0
- data/docs/JudgeNotFound.md +18 -0
- data/docs/JudgeNotFoundBody.md +28 -0
- data/docs/JudgeUnauthorized.md +18 -0
- data/docs/JudgeUnauthorizedBody.md +28 -0
- data/docs/ListRulesForbidden.md +18 -0
- data/docs/ListRulesForbiddenBody.md +28 -0
- data/docs/ListRulesInternalServerError.md +18 -0
- data/docs/ListRulesInternalServerErrorBody.md +28 -0
- data/docs/ListRulesOK.md +18 -0
- data/docs/ListRulesUnauthorized.md +18 -0
- data/docs/ListRulesUnauthorizedBody.md +28 -0
- data/docs/Rule.md +30 -0
- data/docs/RuleHandler.md +20 -0
- data/docs/RuleMatch.md +20 -0
- data/docs/SwaggerCreateRuleParameters.md +18 -0
- data/docs/SwaggerGetRuleParameters.md +18 -0
- data/docs/SwaggerHealthStatus.md +18 -0
- data/docs/SwaggerJSONWebKey.md +50 -0
- data/docs/SwaggerJSONWebKeySet.md +18 -0
- data/docs/SwaggerListRulesParameters.md +20 -0
- data/docs/SwaggerNotReadyStatus.md +18 -0
- data/docs/SwaggerRule.md +30 -0
- data/docs/SwaggerRuleHandler.md +20 -0
- data/docs/SwaggerRuleMatch.md +20 -0
- data/docs/SwaggerRuleResponse.md +18 -0
- data/docs/SwaggerRulesResponse.md +18 -0
- data/docs/SwaggerUpdateRuleParameters.md +20 -0
- data/docs/SwaggerVersion.md +18 -0
- data/docs/UpdateRuleForbidden.md +18 -0
- data/docs/UpdateRuleForbiddenBody.md +28 -0
- data/docs/UpdateRuleInternalServerError.md +18 -0
- data/docs/UpdateRuleInternalServerErrorBody.md +28 -0
- data/docs/UpdateRuleNotFound.md +18 -0
- data/docs/UpdateRuleNotFoundBody.md +28 -0
- data/docs/UpdateRuleOK.md +18 -0
- data/docs/UpdateRuleUnauthorized.md +18 -0
- data/docs/UpdateRuleUnauthorizedBody.md +28 -0
- data/docs/Upstream.md +22 -0
- data/docs/Version.md +18 -0
- data/docs/VersionApi.md +52 -0
- data/lib/ory-oathkeeper-client.rb +131 -0
- data/lib/ory-oathkeeper-client/api/api_api.rb +433 -0
- data/lib/ory-oathkeeper-client/api/health_api.rb +134 -0
- data/lib/ory-oathkeeper-client/api/version_api.rb +78 -0
- data/lib/ory-oathkeeper-client/api_client.rb +389 -0
- data/lib/ory-oathkeeper-client/api_error.rb +57 -0
- data/lib/ory-oathkeeper-client/configuration.rb +270 -0
- data/lib/ory-oathkeeper-client/models/create_rule_created.rb +219 -0
- data/lib/ory-oathkeeper-client/models/create_rule_forbidden.rb +219 -0
- data/lib/ory-oathkeeper-client/models/create_rule_forbidden_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/create_rule_internal_server_error.rb +219 -0
- data/lib/ory-oathkeeper-client/models/create_rule_internal_server_error_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/create_rule_unauthorized.rb +219 -0
- data/lib/ory-oathkeeper-client/models/create_rule_unauthorized_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/decisions_forbidden.rb +219 -0
- data/lib/ory-oathkeeper-client/models/decisions_forbidden_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/decisions_internal_server_error.rb +219 -0
- data/lib/ory-oathkeeper-client/models/decisions_internal_server_error_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/decisions_not_found.rb +219 -0
- data/lib/ory-oathkeeper-client/models/decisions_not_found_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/decisions_unauthorized.rb +219 -0
- data/lib/ory-oathkeeper-client/models/decisions_unauthorized_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_forbidden.rb +219 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_forbidden_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_internal_server_error.rb +219 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_internal_server_error_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_not_found.rb +219 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_not_found_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_unauthorized.rb +219 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_unauthorized_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/get_rule_forbidden.rb +219 -0
- data/lib/ory-oathkeeper-client/models/get_rule_forbidden_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/get_rule_internal_server_error.rb +219 -0
- data/lib/ory-oathkeeper-client/models/get_rule_internal_server_error_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/get_rule_not_found.rb +219 -0
- data/lib/ory-oathkeeper-client/models/get_rule_not_found_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/get_rule_ok.rb +219 -0
- data/lib/ory-oathkeeper-client/models/get_rule_unauthorized.rb +219 -0
- data/lib/ory-oathkeeper-client/models/get_rule_unauthorized_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_forbidden.rb +219 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_forbidden_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_json_web_keys_internal_server_error.rb +219 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_json_web_keys_internal_server_error_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_json_web_keys_ok.rb +219 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_ok.rb +219 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_unauthorized.rb +219 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_unauthorized_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/health_not_ready_status.rb +221 -0
- data/lib/ory-oathkeeper-client/models/health_status.rb +219 -0
- data/lib/ory-oathkeeper-client/models/inline_response500.rb +265 -0
- data/lib/ory-oathkeeper-client/models/is_instance_alive_internal_server_error.rb +219 -0
- data/lib/ory-oathkeeper-client/models/is_instance_alive_internal_server_error_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/is_instance_alive_ok.rb +219 -0
- data/lib/ory-oathkeeper-client/models/json_web_key.rb +369 -0
- data/lib/ory-oathkeeper-client/models/json_web_key_set.rb +221 -0
- data/lib/ory-oathkeeper-client/models/judge_forbidden.rb +219 -0
- data/lib/ory-oathkeeper-client/models/judge_forbidden_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/judge_internal_server_error.rb +219 -0
- data/lib/ory-oathkeeper-client/models/judge_internal_server_error_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/judge_not_found.rb +219 -0
- data/lib/ory-oathkeeper-client/models/judge_not_found_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/judge_unauthorized.rb +219 -0
- data/lib/ory-oathkeeper-client/models/judge_unauthorized_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/list_rules_forbidden.rb +219 -0
- data/lib/ory-oathkeeper-client/models/list_rules_forbidden_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/list_rules_internal_server_error.rb +219 -0
- data/lib/ory-oathkeeper-client/models/list_rules_internal_server_error_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/list_rules_ok.rb +222 -0
- data/lib/ory-oathkeeper-client/models/list_rules_unauthorized.rb +219 -0
- data/lib/ory-oathkeeper-client/models/list_rules_unauthorized_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/rule.rb +280 -0
- data/lib/ory-oathkeeper-client/models/rule_handler.rb +229 -0
- data/lib/ory-oathkeeper-client/models/rule_match.rb +231 -0
- data/lib/ory-oathkeeper-client/models/swagger_create_rule_parameters.rb +219 -0
- data/lib/ory-oathkeeper-client/models/swagger_get_rule_parameters.rb +225 -0
- data/lib/ory-oathkeeper-client/models/swagger_health_status.rb +220 -0
- data/lib/ory-oathkeeper-client/models/swagger_json_web_key.rb +382 -0
- data/lib/ory-oathkeeper-client/models/swagger_json_web_key_set.rb +222 -0
- data/lib/ory-oathkeeper-client/models/swagger_list_rules_parameters.rb +230 -0
- data/lib/ory-oathkeeper-client/models/swagger_not_ready_status.rb +222 -0
- data/lib/ory-oathkeeper-client/models/swagger_rule.rb +280 -0
- data/lib/ory-oathkeeper-client/models/swagger_rule_handler.rb +230 -0
- data/lib/ory-oathkeeper-client/models/swagger_rule_match.rb +232 -0
- data/lib/ory-oathkeeper-client/models/swagger_rule_response.rb +219 -0
- data/lib/ory-oathkeeper-client/models/swagger_rules_response.rb +222 -0
- data/lib/ory-oathkeeper-client/models/swagger_update_rule_parameters.rb +234 -0
- data/lib/ory-oathkeeper-client/models/swagger_version.rb +220 -0
- data/lib/ory-oathkeeper-client/models/update_rule_forbidden.rb +219 -0
- data/lib/ory-oathkeeper-client/models/update_rule_forbidden_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/update_rule_internal_server_error.rb +219 -0
- data/lib/ory-oathkeeper-client/models/update_rule_internal_server_error_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/update_rule_not_found.rb +219 -0
- data/lib/ory-oathkeeper-client/models/update_rule_not_found_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/update_rule_ok.rb +219 -0
- data/lib/ory-oathkeeper-client/models/update_rule_unauthorized.rb +219 -0
- data/lib/ory-oathkeeper-client/models/update_rule_unauthorized_body.rb +272 -0
- data/lib/ory-oathkeeper-client/models/upstream.rb +240 -0
- data/lib/ory-oathkeeper-client/models/version.rb +219 -0
- data/lib/ory-oathkeeper-client/version.rb +15 -0
- data/ory-oathkeeper-client.gemspec +38 -0
- data/spec/api/api_api_spec.rb +115 -0
- data/spec/api/health_api_spec.rb +57 -0
- data/spec/api/version_api_spec.rb +46 -0
- data/spec/api_client_spec.rb +226 -0
- data/spec/configuration_spec.rb +42 -0
- data/spec/models/create_rule_created_spec.rb +41 -0
- data/spec/models/create_rule_forbidden_body_spec.rb +71 -0
- data/spec/models/create_rule_forbidden_spec.rb +41 -0
- data/spec/models/create_rule_internal_server_error_body_spec.rb +71 -0
- data/spec/models/create_rule_internal_server_error_spec.rb +41 -0
- data/spec/models/create_rule_unauthorized_body_spec.rb +71 -0
- data/spec/models/create_rule_unauthorized_spec.rb +41 -0
- data/spec/models/decisions_forbidden_body_spec.rb +71 -0
- data/spec/models/decisions_forbidden_spec.rb +41 -0
- data/spec/models/decisions_internal_server_error_body_spec.rb +71 -0
- data/spec/models/decisions_internal_server_error_spec.rb +41 -0
- data/spec/models/decisions_not_found_body_spec.rb +71 -0
- data/spec/models/decisions_not_found_spec.rb +41 -0
- data/spec/models/decisions_unauthorized_body_spec.rb +71 -0
- data/spec/models/decisions_unauthorized_spec.rb +41 -0
- data/spec/models/delete_rule_forbidden_body_spec.rb +71 -0
- data/spec/models/delete_rule_forbidden_spec.rb +41 -0
- data/spec/models/delete_rule_internal_server_error_body_spec.rb +71 -0
- data/spec/models/delete_rule_internal_server_error_spec.rb +41 -0
- data/spec/models/delete_rule_not_found_body_spec.rb +71 -0
- data/spec/models/delete_rule_not_found_spec.rb +41 -0
- data/spec/models/delete_rule_unauthorized_body_spec.rb +71 -0
- data/spec/models/delete_rule_unauthorized_spec.rb +41 -0
- data/spec/models/get_rule_forbidden_body_spec.rb +71 -0
- data/spec/models/get_rule_forbidden_spec.rb +41 -0
- data/spec/models/get_rule_internal_server_error_body_spec.rb +71 -0
- data/spec/models/get_rule_internal_server_error_spec.rb +41 -0
- data/spec/models/get_rule_not_found_body_spec.rb +71 -0
- data/spec/models/get_rule_not_found_spec.rb +41 -0
- data/spec/models/get_rule_ok_spec.rb +41 -0
- data/spec/models/get_rule_unauthorized_body_spec.rb +71 -0
- data/spec/models/get_rule_unauthorized_spec.rb +41 -0
- data/spec/models/get_well_known_forbidden_body_spec.rb +71 -0
- data/spec/models/get_well_known_forbidden_spec.rb +41 -0
- data/spec/models/get_well_known_json_web_keys_internal_server_error_body_spec.rb +71 -0
- data/spec/models/get_well_known_json_web_keys_internal_server_error_spec.rb +41 -0
- data/spec/models/get_well_known_json_web_keys_ok_spec.rb +41 -0
- data/spec/models/get_well_known_ok_spec.rb +41 -0
- data/spec/models/get_well_known_unauthorized_body_spec.rb +71 -0
- data/spec/models/get_well_known_unauthorized_spec.rb +41 -0
- data/spec/models/health_not_ready_status_spec.rb +41 -0
- data/spec/models/health_status_spec.rb +41 -0
- data/spec/models/inline_response500_spec.rb +71 -0
- data/spec/models/is_instance_alive_internal_server_error_body_spec.rb +71 -0
- data/spec/models/is_instance_alive_internal_server_error_spec.rb +41 -0
- data/spec/models/is_instance_alive_ok_spec.rb +41 -0
- data/spec/models/json_web_key_set_spec.rb +41 -0
- data/spec/models/json_web_key_spec.rb +137 -0
- data/spec/models/judge_forbidden_body_spec.rb +71 -0
- data/spec/models/judge_forbidden_spec.rb +41 -0
- data/spec/models/judge_internal_server_error_body_spec.rb +71 -0
- data/spec/models/judge_internal_server_error_spec.rb +41 -0
- data/spec/models/judge_not_found_body_spec.rb +71 -0
- data/spec/models/judge_not_found_spec.rb +41 -0
- data/spec/models/judge_unauthorized_body_spec.rb +71 -0
- data/spec/models/judge_unauthorized_spec.rb +41 -0
- data/spec/models/list_rules_forbidden_body_spec.rb +71 -0
- data/spec/models/list_rules_forbidden_spec.rb +41 -0
- data/spec/models/list_rules_internal_server_error_body_spec.rb +71 -0
- data/spec/models/list_rules_internal_server_error_spec.rb +41 -0
- data/spec/models/list_rules_ok_spec.rb +41 -0
- data/spec/models/list_rules_unauthorized_body_spec.rb +71 -0
- data/spec/models/list_rules_unauthorized_spec.rb +41 -0
- data/spec/models/rule_handler_spec.rb +47 -0
- data/spec/models/rule_match_spec.rb +47 -0
- data/spec/models/rule_spec.rb +77 -0
- data/spec/models/swagger_create_rule_parameters_spec.rb +41 -0
- data/spec/models/swagger_get_rule_parameters_spec.rb +41 -0
- data/spec/models/swagger_health_status_spec.rb +41 -0
- data/spec/models/swagger_json_web_key_set_spec.rb +41 -0
- data/spec/models/swagger_json_web_key_spec.rb +137 -0
- data/spec/models/swagger_list_rules_parameters_spec.rb +47 -0
- data/spec/models/swagger_not_ready_status_spec.rb +41 -0
- data/spec/models/swagger_rule_handler_spec.rb +47 -0
- data/spec/models/swagger_rule_match_spec.rb +47 -0
- data/spec/models/swagger_rule_response_spec.rb +41 -0
- data/spec/models/swagger_rule_spec.rb +77 -0
- data/spec/models/swagger_rules_response_spec.rb +41 -0
- data/spec/models/swagger_update_rule_parameters_spec.rb +47 -0
- data/spec/models/swagger_version_spec.rb +41 -0
- data/spec/models/update_rule_forbidden_body_spec.rb +71 -0
- data/spec/models/update_rule_forbidden_spec.rb +41 -0
- data/spec/models/update_rule_internal_server_error_body_spec.rb +71 -0
- data/spec/models/update_rule_internal_server_error_spec.rb +41 -0
- data/spec/models/update_rule_not_found_body_spec.rb +71 -0
- data/spec/models/update_rule_not_found_spec.rb +41 -0
- data/spec/models/update_rule_ok_spec.rb +41 -0
- data/spec/models/update_rule_unauthorized_body_spec.rb +71 -0
- data/spec/models/update_rule_unauthorized_spec.rb +41 -0
- data/spec/models/upstream_spec.rb +53 -0
- data/spec/models/version_spec.rb +41 -0
- data/spec/spec_helper.rb +111 -0
- metadata +477 -0
data/docs/Version.md
ADDED
@@ -0,0 +1,18 @@
|
|
1
|
+
# OryOathkeeperClient::Version
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **version** | **String** | Version is the service's version. | [optional] |
|
8
|
+
|
9
|
+
## Example
|
10
|
+
|
11
|
+
```ruby
|
12
|
+
require 'ory-oathkeeper-client'
|
13
|
+
|
14
|
+
instance = OryOathkeeperClient::Version.new(
|
15
|
+
version: null
|
16
|
+
)
|
17
|
+
```
|
18
|
+
|
data/docs/VersionApi.md
ADDED
@@ -0,0 +1,52 @@
|
|
1
|
+
# OryHydraClient::VersionApi
|
2
|
+
|
3
|
+
All URIs are relative to *http://localhost*
|
4
|
+
|
5
|
+
Method | HTTP request | Description
|
6
|
+
------------- | ------------- | -------------
|
7
|
+
[**get_version**](VersionApi.md#get_version) | **GET** /version | Get service version
|
8
|
+
|
9
|
+
|
10
|
+
|
11
|
+
## get_version
|
12
|
+
|
13
|
+
> Version get_version
|
14
|
+
|
15
|
+
Get service version
|
16
|
+
|
17
|
+
This endpoint returns the service version typically notated using semantic versioning. If the service supports TLS Edge Termination, this endpoint does not require the `X-Forwarded-Proto` header to be set. Be aware that if you are running multiple nodes of this service, the health status will never refer to the cluster state, only to a single instance.
|
18
|
+
|
19
|
+
### Example
|
20
|
+
|
21
|
+
```ruby
|
22
|
+
# load the gem
|
23
|
+
require 'ory-oathkeeper-client'
|
24
|
+
|
25
|
+
api_instance = OryHydraClient::VersionApi.new
|
26
|
+
|
27
|
+
begin
|
28
|
+
#Get service version
|
29
|
+
result = api_instance.get_version
|
30
|
+
p result
|
31
|
+
rescue OryHydraClient::ApiError => e
|
32
|
+
puts "Exception when calling VersionApi->get_version: #{e}"
|
33
|
+
end
|
34
|
+
```
|
35
|
+
|
36
|
+
### Parameters
|
37
|
+
|
38
|
+
This endpoint does not need any parameter.
|
39
|
+
|
40
|
+
### Return type
|
41
|
+
|
42
|
+
[**Version**](Version.md)
|
43
|
+
|
44
|
+
### Authorization
|
45
|
+
|
46
|
+
No authorization required
|
47
|
+
|
48
|
+
### HTTP request headers
|
49
|
+
|
50
|
+
- **Content-Type**: Not defined
|
51
|
+
- **Accept**: application/json
|
52
|
+
|
@@ -0,0 +1,131 @@
|
|
1
|
+
=begin
|
2
|
+
#ORY Oathkeeper
|
3
|
+
|
4
|
+
#ORY Oathkeeper is a reverse proxy that checks the HTTP Authorization for validity against a set of rules. This service uses Hydra to validate access tokens and policies.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: v0.0.0-alpha.38
|
7
|
+
Contact: hi@ory.am
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 5.2.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
# Common files
|
14
|
+
require 'ory-oathkeeper-client/api_client'
|
15
|
+
require 'ory-oathkeeper-client/api_error'
|
16
|
+
require 'ory-oathkeeper-client/version'
|
17
|
+
require 'ory-oathkeeper-client/configuration'
|
18
|
+
|
19
|
+
# Models
|
20
|
+
require 'ory-oathkeeper-client/models/create_rule_created'
|
21
|
+
require 'ory-oathkeeper-client/models/create_rule_forbidden'
|
22
|
+
require 'ory-oathkeeper-client/models/create_rule_forbidden_body'
|
23
|
+
require 'ory-oathkeeper-client/models/create_rule_internal_server_error'
|
24
|
+
require 'ory-oathkeeper-client/models/create_rule_internal_server_error_body'
|
25
|
+
require 'ory-oathkeeper-client/models/create_rule_unauthorized'
|
26
|
+
require 'ory-oathkeeper-client/models/create_rule_unauthorized_body'
|
27
|
+
require 'ory-oathkeeper-client/models/decisions_forbidden'
|
28
|
+
require 'ory-oathkeeper-client/models/decisions_forbidden_body'
|
29
|
+
require 'ory-oathkeeper-client/models/decisions_internal_server_error'
|
30
|
+
require 'ory-oathkeeper-client/models/decisions_internal_server_error_body'
|
31
|
+
require 'ory-oathkeeper-client/models/decisions_not_found'
|
32
|
+
require 'ory-oathkeeper-client/models/decisions_not_found_body'
|
33
|
+
require 'ory-oathkeeper-client/models/decisions_unauthorized'
|
34
|
+
require 'ory-oathkeeper-client/models/decisions_unauthorized_body'
|
35
|
+
require 'ory-oathkeeper-client/models/delete_rule_forbidden'
|
36
|
+
require 'ory-oathkeeper-client/models/delete_rule_forbidden_body'
|
37
|
+
require 'ory-oathkeeper-client/models/delete_rule_internal_server_error'
|
38
|
+
require 'ory-oathkeeper-client/models/delete_rule_internal_server_error_body'
|
39
|
+
require 'ory-oathkeeper-client/models/delete_rule_not_found'
|
40
|
+
require 'ory-oathkeeper-client/models/delete_rule_not_found_body'
|
41
|
+
require 'ory-oathkeeper-client/models/delete_rule_unauthorized'
|
42
|
+
require 'ory-oathkeeper-client/models/delete_rule_unauthorized_body'
|
43
|
+
require 'ory-oathkeeper-client/models/get_rule_forbidden'
|
44
|
+
require 'ory-oathkeeper-client/models/get_rule_forbidden_body'
|
45
|
+
require 'ory-oathkeeper-client/models/get_rule_internal_server_error'
|
46
|
+
require 'ory-oathkeeper-client/models/get_rule_internal_server_error_body'
|
47
|
+
require 'ory-oathkeeper-client/models/get_rule_not_found'
|
48
|
+
require 'ory-oathkeeper-client/models/get_rule_not_found_body'
|
49
|
+
require 'ory-oathkeeper-client/models/get_rule_ok'
|
50
|
+
require 'ory-oathkeeper-client/models/get_rule_unauthorized'
|
51
|
+
require 'ory-oathkeeper-client/models/get_rule_unauthorized_body'
|
52
|
+
require 'ory-oathkeeper-client/models/get_well_known_forbidden'
|
53
|
+
require 'ory-oathkeeper-client/models/get_well_known_forbidden_body'
|
54
|
+
require 'ory-oathkeeper-client/models/get_well_known_json_web_keys_internal_server_error'
|
55
|
+
require 'ory-oathkeeper-client/models/get_well_known_json_web_keys_internal_server_error_body'
|
56
|
+
require 'ory-oathkeeper-client/models/get_well_known_json_web_keys_ok'
|
57
|
+
require 'ory-oathkeeper-client/models/get_well_known_ok'
|
58
|
+
require 'ory-oathkeeper-client/models/get_well_known_unauthorized'
|
59
|
+
require 'ory-oathkeeper-client/models/get_well_known_unauthorized_body'
|
60
|
+
require 'ory-oathkeeper-client/models/health_not_ready_status'
|
61
|
+
require 'ory-oathkeeper-client/models/health_status'
|
62
|
+
require 'ory-oathkeeper-client/models/inline_response500'
|
63
|
+
require 'ory-oathkeeper-client/models/is_instance_alive_internal_server_error'
|
64
|
+
require 'ory-oathkeeper-client/models/is_instance_alive_internal_server_error_body'
|
65
|
+
require 'ory-oathkeeper-client/models/is_instance_alive_ok'
|
66
|
+
require 'ory-oathkeeper-client/models/json_web_key'
|
67
|
+
require 'ory-oathkeeper-client/models/json_web_key_set'
|
68
|
+
require 'ory-oathkeeper-client/models/judge_forbidden'
|
69
|
+
require 'ory-oathkeeper-client/models/judge_forbidden_body'
|
70
|
+
require 'ory-oathkeeper-client/models/judge_internal_server_error'
|
71
|
+
require 'ory-oathkeeper-client/models/judge_internal_server_error_body'
|
72
|
+
require 'ory-oathkeeper-client/models/judge_not_found'
|
73
|
+
require 'ory-oathkeeper-client/models/judge_not_found_body'
|
74
|
+
require 'ory-oathkeeper-client/models/judge_unauthorized'
|
75
|
+
require 'ory-oathkeeper-client/models/judge_unauthorized_body'
|
76
|
+
require 'ory-oathkeeper-client/models/list_rules_forbidden'
|
77
|
+
require 'ory-oathkeeper-client/models/list_rules_forbidden_body'
|
78
|
+
require 'ory-oathkeeper-client/models/list_rules_internal_server_error'
|
79
|
+
require 'ory-oathkeeper-client/models/list_rules_internal_server_error_body'
|
80
|
+
require 'ory-oathkeeper-client/models/list_rules_ok'
|
81
|
+
require 'ory-oathkeeper-client/models/list_rules_unauthorized'
|
82
|
+
require 'ory-oathkeeper-client/models/list_rules_unauthorized_body'
|
83
|
+
require 'ory-oathkeeper-client/models/rule'
|
84
|
+
require 'ory-oathkeeper-client/models/rule_handler'
|
85
|
+
require 'ory-oathkeeper-client/models/rule_match'
|
86
|
+
require 'ory-oathkeeper-client/models/swagger_create_rule_parameters'
|
87
|
+
require 'ory-oathkeeper-client/models/swagger_get_rule_parameters'
|
88
|
+
require 'ory-oathkeeper-client/models/swagger_health_status'
|
89
|
+
require 'ory-oathkeeper-client/models/swagger_json_web_key'
|
90
|
+
require 'ory-oathkeeper-client/models/swagger_json_web_key_set'
|
91
|
+
require 'ory-oathkeeper-client/models/swagger_list_rules_parameters'
|
92
|
+
require 'ory-oathkeeper-client/models/swagger_not_ready_status'
|
93
|
+
require 'ory-oathkeeper-client/models/swagger_rule'
|
94
|
+
require 'ory-oathkeeper-client/models/swagger_rule_handler'
|
95
|
+
require 'ory-oathkeeper-client/models/swagger_rule_match'
|
96
|
+
require 'ory-oathkeeper-client/models/swagger_rule_response'
|
97
|
+
require 'ory-oathkeeper-client/models/swagger_rules_response'
|
98
|
+
require 'ory-oathkeeper-client/models/swagger_update_rule_parameters'
|
99
|
+
require 'ory-oathkeeper-client/models/swagger_version'
|
100
|
+
require 'ory-oathkeeper-client/models/update_rule_forbidden'
|
101
|
+
require 'ory-oathkeeper-client/models/update_rule_forbidden_body'
|
102
|
+
require 'ory-oathkeeper-client/models/update_rule_internal_server_error'
|
103
|
+
require 'ory-oathkeeper-client/models/update_rule_internal_server_error_body'
|
104
|
+
require 'ory-oathkeeper-client/models/update_rule_not_found'
|
105
|
+
require 'ory-oathkeeper-client/models/update_rule_not_found_body'
|
106
|
+
require 'ory-oathkeeper-client/models/update_rule_ok'
|
107
|
+
require 'ory-oathkeeper-client/models/update_rule_unauthorized'
|
108
|
+
require 'ory-oathkeeper-client/models/update_rule_unauthorized_body'
|
109
|
+
require 'ory-oathkeeper-client/models/upstream'
|
110
|
+
require 'ory-oathkeeper-client/models/version'
|
111
|
+
|
112
|
+
# APIs
|
113
|
+
require 'ory-oathkeeper-client/api/api_api'
|
114
|
+
|
115
|
+
module OryOathkeeperClient
|
116
|
+
class << self
|
117
|
+
# Customize default settings for the SDK using block.
|
118
|
+
# OryOathkeeperClient.configure do |config|
|
119
|
+
# config.username = "xxx"
|
120
|
+
# config.password = "xxx"
|
121
|
+
# end
|
122
|
+
# If no block given, return the default Configuration object.
|
123
|
+
def configure
|
124
|
+
if block_given?
|
125
|
+
yield(Configuration.default)
|
126
|
+
else
|
127
|
+
Configuration.default
|
128
|
+
end
|
129
|
+
end
|
130
|
+
end
|
131
|
+
end
|
@@ -0,0 +1,433 @@
|
|
1
|
+
=begin
|
2
|
+
#ORY Oathkeeper
|
3
|
+
|
4
|
+
#ORY Oathkeeper is a reverse proxy that checks the HTTP Authorization for validity against a set of rules. This service uses Hydra to validate access tokens and policies.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: v0.0.0-alpha.38
|
7
|
+
Contact: hi@ory.am
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 5.2.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'cgi'
|
14
|
+
|
15
|
+
module OryOathkeeperClient
|
16
|
+
class ApiApi
|
17
|
+
attr_accessor :api_client
|
18
|
+
|
19
|
+
def initialize(api_client = ApiClient.default)
|
20
|
+
@api_client = api_client
|
21
|
+
end
|
22
|
+
# Access Control Decision API
|
23
|
+
# > This endpoint works with all HTTP Methods (GET, POST, PUT, ...) and matches every path prefixed with /decision. This endpoint mirrors the proxy capability of ORY Oathkeeper's proxy functionality but instead of forwarding the request to the upstream server, returns 200 (request should be allowed), 401 (unauthorized), or 403 (forbidden) status codes. This endpoint can be used to integrate with other API Proxies like Ambassador, Kong, Envoy, and many more.
|
24
|
+
# @param [Hash] opts the optional parameters
|
25
|
+
# @return [nil]
|
26
|
+
def decisions(opts = {})
|
27
|
+
decisions_with_http_info(opts)
|
28
|
+
nil
|
29
|
+
end
|
30
|
+
|
31
|
+
# Access Control Decision API
|
32
|
+
# > This endpoint works with all HTTP Methods (GET, POST, PUT, ...) and matches every path prefixed with /decision. This endpoint mirrors the proxy capability of ORY Oathkeeper's proxy functionality but instead of forwarding the request to the upstream server, returns 200 (request should be allowed), 401 (unauthorized), or 403 (forbidden) status codes. This endpoint can be used to integrate with other API Proxies like Ambassador, Kong, Envoy, and many more.
|
33
|
+
# @param [Hash] opts the optional parameters
|
34
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
35
|
+
def decisions_with_http_info(opts = {})
|
36
|
+
if @api_client.config.debugging
|
37
|
+
@api_client.config.logger.debug 'Calling API: ApiApi.decisions ...'
|
38
|
+
end
|
39
|
+
# resource path
|
40
|
+
local_var_path = '/decisions'
|
41
|
+
|
42
|
+
# query parameters
|
43
|
+
query_params = opts[:query_params] || {}
|
44
|
+
|
45
|
+
# header parameters
|
46
|
+
header_params = opts[:header_params] || {}
|
47
|
+
# HTTP header 'Accept' (if needed)
|
48
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
49
|
+
|
50
|
+
# form parameters
|
51
|
+
form_params = opts[:form_params] || {}
|
52
|
+
|
53
|
+
# http body (model)
|
54
|
+
post_body = opts[:debug_body]
|
55
|
+
|
56
|
+
# return_type
|
57
|
+
return_type = opts[:debug_return_type]
|
58
|
+
|
59
|
+
# auth_names
|
60
|
+
auth_names = opts[:debug_auth_names] || []
|
61
|
+
|
62
|
+
new_options = opts.merge(
|
63
|
+
:operation => :"ApiApi.decisions",
|
64
|
+
:header_params => header_params,
|
65
|
+
:query_params => query_params,
|
66
|
+
:form_params => form_params,
|
67
|
+
:body => post_body,
|
68
|
+
:auth_names => auth_names,
|
69
|
+
:return_type => return_type
|
70
|
+
)
|
71
|
+
|
72
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
73
|
+
if @api_client.config.debugging
|
74
|
+
@api_client.config.logger.debug "API called: ApiApi#decisions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
75
|
+
end
|
76
|
+
return data, status_code, headers
|
77
|
+
end
|
78
|
+
|
79
|
+
# Retrieve a rule
|
80
|
+
# Use this method to retrieve a rule from the storage. If it does not exist you will receive a 404 error.
|
81
|
+
# @param id [String]
|
82
|
+
# @param [Hash] opts the optional parameters
|
83
|
+
# @return [Rule]
|
84
|
+
def get_rule(id, opts = {})
|
85
|
+
data, _status_code, _headers = get_rule_with_http_info(id, opts)
|
86
|
+
data
|
87
|
+
end
|
88
|
+
|
89
|
+
# Retrieve a rule
|
90
|
+
# Use this method to retrieve a rule from the storage. If it does not exist you will receive a 404 error.
|
91
|
+
# @param id [String]
|
92
|
+
# @param [Hash] opts the optional parameters
|
93
|
+
# @return [Array<(Rule, Integer, Hash)>] Rule data, response status code and response headers
|
94
|
+
def get_rule_with_http_info(id, opts = {})
|
95
|
+
if @api_client.config.debugging
|
96
|
+
@api_client.config.logger.debug 'Calling API: ApiApi.get_rule ...'
|
97
|
+
end
|
98
|
+
# verify the required parameter 'id' is set
|
99
|
+
if @api_client.config.client_side_validation && id.nil?
|
100
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling ApiApi.get_rule"
|
101
|
+
end
|
102
|
+
# resource path
|
103
|
+
local_var_path = '/rules/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
|
104
|
+
|
105
|
+
# query parameters
|
106
|
+
query_params = opts[:query_params] || {}
|
107
|
+
|
108
|
+
# header parameters
|
109
|
+
header_params = opts[:header_params] || {}
|
110
|
+
# HTTP header 'Accept' (if needed)
|
111
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
112
|
+
|
113
|
+
# form parameters
|
114
|
+
form_params = opts[:form_params] || {}
|
115
|
+
|
116
|
+
# http body (model)
|
117
|
+
post_body = opts[:debug_body]
|
118
|
+
|
119
|
+
# return_type
|
120
|
+
return_type = opts[:debug_return_type] || 'Rule'
|
121
|
+
|
122
|
+
# auth_names
|
123
|
+
auth_names = opts[:debug_auth_names] || []
|
124
|
+
|
125
|
+
new_options = opts.merge(
|
126
|
+
:operation => :"ApiApi.get_rule",
|
127
|
+
:header_params => header_params,
|
128
|
+
:query_params => query_params,
|
129
|
+
:form_params => form_params,
|
130
|
+
:body => post_body,
|
131
|
+
:auth_names => auth_names,
|
132
|
+
:return_type => return_type
|
133
|
+
)
|
134
|
+
|
135
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
136
|
+
if @api_client.config.debugging
|
137
|
+
@api_client.config.logger.debug "API called: ApiApi#get_rule\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
138
|
+
end
|
139
|
+
return data, status_code, headers
|
140
|
+
end
|
141
|
+
|
142
|
+
# Get service version
|
143
|
+
# This endpoint returns the service version typically notated using semantic versioning. If the service supports TLS Edge Termination, this endpoint does not require the `X-Forwarded-Proto` header to be set. Be aware that if you are running multiple nodes of this service, the health status will never refer to the cluster state, only to a single instance.
|
144
|
+
# @param [Hash] opts the optional parameters
|
145
|
+
# @return [Version]
|
146
|
+
def get_version(opts = {})
|
147
|
+
data, _status_code, _headers = get_version_with_http_info(opts)
|
148
|
+
data
|
149
|
+
end
|
150
|
+
|
151
|
+
# Get service version
|
152
|
+
# This endpoint returns the service version typically notated using semantic versioning. If the service supports TLS Edge Termination, this endpoint does not require the `X-Forwarded-Proto` header to be set. Be aware that if you are running multiple nodes of this service, the health status will never refer to the cluster state, only to a single instance.
|
153
|
+
# @param [Hash] opts the optional parameters
|
154
|
+
# @return [Array<(Version, Integer, Hash)>] Version data, response status code and response headers
|
155
|
+
def get_version_with_http_info(opts = {})
|
156
|
+
if @api_client.config.debugging
|
157
|
+
@api_client.config.logger.debug 'Calling API: ApiApi.get_version ...'
|
158
|
+
end
|
159
|
+
# resource path
|
160
|
+
local_var_path = '/version'
|
161
|
+
|
162
|
+
# query parameters
|
163
|
+
query_params = opts[:query_params] || {}
|
164
|
+
|
165
|
+
# header parameters
|
166
|
+
header_params = opts[:header_params] || {}
|
167
|
+
# HTTP header 'Accept' (if needed)
|
168
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
169
|
+
|
170
|
+
# form parameters
|
171
|
+
form_params = opts[:form_params] || {}
|
172
|
+
|
173
|
+
# http body (model)
|
174
|
+
post_body = opts[:debug_body]
|
175
|
+
|
176
|
+
# return_type
|
177
|
+
return_type = opts[:debug_return_type] || 'Version'
|
178
|
+
|
179
|
+
# auth_names
|
180
|
+
auth_names = opts[:debug_auth_names] || []
|
181
|
+
|
182
|
+
new_options = opts.merge(
|
183
|
+
:operation => :"ApiApi.get_version",
|
184
|
+
:header_params => header_params,
|
185
|
+
:query_params => query_params,
|
186
|
+
:form_params => form_params,
|
187
|
+
:body => post_body,
|
188
|
+
:auth_names => auth_names,
|
189
|
+
:return_type => return_type
|
190
|
+
)
|
191
|
+
|
192
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
193
|
+
if @api_client.config.debugging
|
194
|
+
@api_client.config.logger.debug "API called: ApiApi#get_version\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
195
|
+
end
|
196
|
+
return data, status_code, headers
|
197
|
+
end
|
198
|
+
|
199
|
+
# Lists cryptographic keys
|
200
|
+
# This endpoint returns cryptographic keys that are required to, for example, verify signatures of ID Tokens.
|
201
|
+
# @param [Hash] opts the optional parameters
|
202
|
+
# @return [JsonWebKeySet]
|
203
|
+
def get_well_known_json_web_keys(opts = {})
|
204
|
+
data, _status_code, _headers = get_well_known_json_web_keys_with_http_info(opts)
|
205
|
+
data
|
206
|
+
end
|
207
|
+
|
208
|
+
# Lists cryptographic keys
|
209
|
+
# This endpoint returns cryptographic keys that are required to, for example, verify signatures of ID Tokens.
|
210
|
+
# @param [Hash] opts the optional parameters
|
211
|
+
# @return [Array<(JsonWebKeySet, Integer, Hash)>] JsonWebKeySet data, response status code and response headers
|
212
|
+
def get_well_known_json_web_keys_with_http_info(opts = {})
|
213
|
+
if @api_client.config.debugging
|
214
|
+
@api_client.config.logger.debug 'Calling API: ApiApi.get_well_known_json_web_keys ...'
|
215
|
+
end
|
216
|
+
# resource path
|
217
|
+
local_var_path = '/.well-known/jwks.json'
|
218
|
+
|
219
|
+
# query parameters
|
220
|
+
query_params = opts[:query_params] || {}
|
221
|
+
|
222
|
+
# header parameters
|
223
|
+
header_params = opts[:header_params] || {}
|
224
|
+
# HTTP header 'Accept' (if needed)
|
225
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
226
|
+
|
227
|
+
# form parameters
|
228
|
+
form_params = opts[:form_params] || {}
|
229
|
+
|
230
|
+
# http body (model)
|
231
|
+
post_body = opts[:debug_body]
|
232
|
+
|
233
|
+
# return_type
|
234
|
+
return_type = opts[:debug_return_type] || 'JsonWebKeySet'
|
235
|
+
|
236
|
+
# auth_names
|
237
|
+
auth_names = opts[:debug_auth_names] || []
|
238
|
+
|
239
|
+
new_options = opts.merge(
|
240
|
+
:operation => :"ApiApi.get_well_known_json_web_keys",
|
241
|
+
:header_params => header_params,
|
242
|
+
:query_params => query_params,
|
243
|
+
:form_params => form_params,
|
244
|
+
:body => post_body,
|
245
|
+
:auth_names => auth_names,
|
246
|
+
:return_type => return_type
|
247
|
+
)
|
248
|
+
|
249
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
250
|
+
if @api_client.config.debugging
|
251
|
+
@api_client.config.logger.debug "API called: ApiApi#get_well_known_json_web_keys\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
252
|
+
end
|
253
|
+
return data, status_code, headers
|
254
|
+
end
|
255
|
+
|
256
|
+
# Check alive status
|
257
|
+
# This endpoint returns a 200 status code when the HTTP server is up running. This status does currently not include checks whether the database connection is working. If the service supports TLS Edge Termination, this endpoint does not require the `X-Forwarded-Proto` header to be set. Be aware that if you are running multiple nodes of this service, the health status will never refer to the cluster state, only to a single instance.
|
258
|
+
# @param [Hash] opts the optional parameters
|
259
|
+
# @return [HealthStatus]
|
260
|
+
def is_instance_alive(opts = {})
|
261
|
+
data, _status_code, _headers = is_instance_alive_with_http_info(opts)
|
262
|
+
data
|
263
|
+
end
|
264
|
+
|
265
|
+
# Check alive status
|
266
|
+
# This endpoint returns a 200 status code when the HTTP server is up running. This status does currently not include checks whether the database connection is working. If the service supports TLS Edge Termination, this endpoint does not require the `X-Forwarded-Proto` header to be set. Be aware that if you are running multiple nodes of this service, the health status will never refer to the cluster state, only to a single instance.
|
267
|
+
# @param [Hash] opts the optional parameters
|
268
|
+
# @return [Array<(HealthStatus, Integer, Hash)>] HealthStatus data, response status code and response headers
|
269
|
+
def is_instance_alive_with_http_info(opts = {})
|
270
|
+
if @api_client.config.debugging
|
271
|
+
@api_client.config.logger.debug 'Calling API: ApiApi.is_instance_alive ...'
|
272
|
+
end
|
273
|
+
# resource path
|
274
|
+
local_var_path = '/health/alive'
|
275
|
+
|
276
|
+
# query parameters
|
277
|
+
query_params = opts[:query_params] || {}
|
278
|
+
|
279
|
+
# header parameters
|
280
|
+
header_params = opts[:header_params] || {}
|
281
|
+
# HTTP header 'Accept' (if needed)
|
282
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
283
|
+
|
284
|
+
# form parameters
|
285
|
+
form_params = opts[:form_params] || {}
|
286
|
+
|
287
|
+
# http body (model)
|
288
|
+
post_body = opts[:debug_body]
|
289
|
+
|
290
|
+
# return_type
|
291
|
+
return_type = opts[:debug_return_type] || 'HealthStatus'
|
292
|
+
|
293
|
+
# auth_names
|
294
|
+
auth_names = opts[:debug_auth_names] || []
|
295
|
+
|
296
|
+
new_options = opts.merge(
|
297
|
+
:operation => :"ApiApi.is_instance_alive",
|
298
|
+
:header_params => header_params,
|
299
|
+
:query_params => query_params,
|
300
|
+
:form_params => form_params,
|
301
|
+
:body => post_body,
|
302
|
+
:auth_names => auth_names,
|
303
|
+
:return_type => return_type
|
304
|
+
)
|
305
|
+
|
306
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
307
|
+
if @api_client.config.debugging
|
308
|
+
@api_client.config.logger.debug "API called: ApiApi#is_instance_alive\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
309
|
+
end
|
310
|
+
return data, status_code, headers
|
311
|
+
end
|
312
|
+
|
313
|
+
# Check readiness status
|
314
|
+
# This endpoint returns a 200 status code when the HTTP server is up running and the environment dependencies (e.g. the database) are responsive as well. If the service supports TLS Edge Termination, this endpoint does not require the `X-Forwarded-Proto` header to be set. Be aware that if you are running multiple nodes of this service, the health status will never refer to the cluster state, only to a single instance.
|
315
|
+
# @param [Hash] opts the optional parameters
|
316
|
+
# @return [HealthStatus]
|
317
|
+
def is_instance_ready(opts = {})
|
318
|
+
data, _status_code, _headers = is_instance_ready_with_http_info(opts)
|
319
|
+
data
|
320
|
+
end
|
321
|
+
|
322
|
+
# Check readiness status
|
323
|
+
# This endpoint returns a 200 status code when the HTTP server is up running and the environment dependencies (e.g. the database) are responsive as well. If the service supports TLS Edge Termination, this endpoint does not require the `X-Forwarded-Proto` header to be set. Be aware that if you are running multiple nodes of this service, the health status will never refer to the cluster state, only to a single instance.
|
324
|
+
# @param [Hash] opts the optional parameters
|
325
|
+
# @return [Array<(HealthStatus, Integer, Hash)>] HealthStatus data, response status code and response headers
|
326
|
+
def is_instance_ready_with_http_info(opts = {})
|
327
|
+
if @api_client.config.debugging
|
328
|
+
@api_client.config.logger.debug 'Calling API: ApiApi.is_instance_ready ...'
|
329
|
+
end
|
330
|
+
# resource path
|
331
|
+
local_var_path = '/health/ready'
|
332
|
+
|
333
|
+
# query parameters
|
334
|
+
query_params = opts[:query_params] || {}
|
335
|
+
|
336
|
+
# header parameters
|
337
|
+
header_params = opts[:header_params] || {}
|
338
|
+
# HTTP header 'Accept' (if needed)
|
339
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
340
|
+
|
341
|
+
# form parameters
|
342
|
+
form_params = opts[:form_params] || {}
|
343
|
+
|
344
|
+
# http body (model)
|
345
|
+
post_body = opts[:debug_body]
|
346
|
+
|
347
|
+
# return_type
|
348
|
+
return_type = opts[:debug_return_type] || 'HealthStatus'
|
349
|
+
|
350
|
+
# auth_names
|
351
|
+
auth_names = opts[:debug_auth_names] || []
|
352
|
+
|
353
|
+
new_options = opts.merge(
|
354
|
+
:operation => :"ApiApi.is_instance_ready",
|
355
|
+
:header_params => header_params,
|
356
|
+
:query_params => query_params,
|
357
|
+
:form_params => form_params,
|
358
|
+
:body => post_body,
|
359
|
+
:auth_names => auth_names,
|
360
|
+
:return_type => return_type
|
361
|
+
)
|
362
|
+
|
363
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
364
|
+
if @api_client.config.debugging
|
365
|
+
@api_client.config.logger.debug "API called: ApiApi#is_instance_ready\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
366
|
+
end
|
367
|
+
return data, status_code, headers
|
368
|
+
end
|
369
|
+
|
370
|
+
# List all rules
|
371
|
+
# This method returns an array of all rules that are stored in the backend. This is useful if you want to get a full view of what rules you have currently in place.
|
372
|
+
# @param [Hash] opts the optional parameters
|
373
|
+
# @option opts [Integer] :limit The maximum amount of rules returned.
|
374
|
+
# @option opts [Integer] :offset The offset from where to start looking.
|
375
|
+
# @return [Array<Rule>]
|
376
|
+
def list_rules(opts = {})
|
377
|
+
data, _status_code, _headers = list_rules_with_http_info(opts)
|
378
|
+
data
|
379
|
+
end
|
380
|
+
|
381
|
+
# List all rules
|
382
|
+
# This method returns an array of all rules that are stored in the backend. This is useful if you want to get a full view of what rules you have currently in place.
|
383
|
+
# @param [Hash] opts the optional parameters
|
384
|
+
# @option opts [Integer] :limit The maximum amount of rules returned.
|
385
|
+
# @option opts [Integer] :offset The offset from where to start looking.
|
386
|
+
# @return [Array<(Array<Rule>, Integer, Hash)>] Array<Rule> data, response status code and response headers
|
387
|
+
def list_rules_with_http_info(opts = {})
|
388
|
+
if @api_client.config.debugging
|
389
|
+
@api_client.config.logger.debug 'Calling API: ApiApi.list_rules ...'
|
390
|
+
end
|
391
|
+
# resource path
|
392
|
+
local_var_path = '/rules'
|
393
|
+
|
394
|
+
# query parameters
|
395
|
+
query_params = opts[:query_params] || {}
|
396
|
+
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
397
|
+
query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
|
398
|
+
|
399
|
+
# header parameters
|
400
|
+
header_params = opts[:header_params] || {}
|
401
|
+
# HTTP header 'Accept' (if needed)
|
402
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
403
|
+
|
404
|
+
# form parameters
|
405
|
+
form_params = opts[:form_params] || {}
|
406
|
+
|
407
|
+
# http body (model)
|
408
|
+
post_body = opts[:debug_body]
|
409
|
+
|
410
|
+
# return_type
|
411
|
+
return_type = opts[:debug_return_type] || 'Array<Rule>'
|
412
|
+
|
413
|
+
# auth_names
|
414
|
+
auth_names = opts[:debug_auth_names] || []
|
415
|
+
|
416
|
+
new_options = opts.merge(
|
417
|
+
:operation => :"ApiApi.list_rules",
|
418
|
+
:header_params => header_params,
|
419
|
+
:query_params => query_params,
|
420
|
+
:form_params => form_params,
|
421
|
+
:body => post_body,
|
422
|
+
:auth_names => auth_names,
|
423
|
+
:return_type => return_type
|
424
|
+
)
|
425
|
+
|
426
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
427
|
+
if @api_client.config.debugging
|
428
|
+
@api_client.config.logger.debug "API called: ApiApi#list_rules\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
429
|
+
end
|
430
|
+
return data, status_code, headers
|
431
|
+
end
|
432
|
+
end
|
433
|
+
end
|