zitadel-client 1.5.1 → 1.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/zitadel/client/api/action_service_api.rb +670 -0
- data/lib/zitadel/client/api/settings_service_api.rb +125 -0
- data/lib/zitadel/client/api/web_key_service_api.rb +273 -0
- data/lib/zitadel/client/models/action_service_beta_condition.rb +257 -0
- data/lib/zitadel/client/models/action_service_beta_create_target_response.rb +251 -0
- data/lib/zitadel/client/models/action_service_beta_delete_target_response.rb +231 -0
- data/lib/zitadel/client/models/action_service_beta_event_execution.rb +307 -0
- data/lib/zitadel/client/models/action_service_beta_execution.rb +262 -0
- data/lib/zitadel/client/models/action_service_beta_execution_target_type.rb +240 -0
- data/lib/zitadel/client/models/action_service_beta_function_execution.rb +230 -0
- data/lib/zitadel/client/models/action_service_beta_get_target_response.rb +230 -0
- data/lib/zitadel/client/models/action_service_beta_in_target_i_ds_filter.rb +233 -0
- data/lib/zitadel/client/models/action_service_beta_list_execution_functions_response.rb +232 -0
- data/lib/zitadel/client/models/action_service_beta_list_execution_methods_response.rb +232 -0
- data/lib/zitadel/client/models/action_service_beta_list_execution_services_response.rb +232 -0
- data/lib/zitadel/client/models/action_service_beta_list_executions_response.rb +241 -0
- data/lib/zitadel/client/models/action_service_beta_list_targets_response.rb +241 -0
- data/lib/zitadel/client/models/action_service_beta_pagination_request.rb +251 -0
- data/lib/zitadel/client/models/action_service_beta_pagination_response.rb +241 -0
- data/lib/zitadel/client/models/action_service_beta_r_e_s_t_call.rb +231 -0
- data/lib/zitadel/client/models/action_service_beta_r_e_s_t_webhook.rb +231 -0
- data/lib/zitadel/client/models/action_service_beta_request_execution.rb +307 -0
- data/lib/zitadel/client/models/action_service_beta_response_execution.rb +307 -0
- data/lib/zitadel/client/models/action_service_beta_set_execution_response.rb +231 -0
- data/lib/zitadel/client/models/action_service_beta_target.rb +315 -0
- data/lib/zitadel/client/models/action_service_beta_target_field_name.rb +48 -0
- data/lib/zitadel/client/models/action_service_beta_target_name_filter.rb +283 -0
- data/lib/zitadel/client/models/action_service_beta_target_search_filter.rb +239 -0
- data/lib/zitadel/client/models/action_service_beta_text_filter_method.rb +47 -0
- data/lib/zitadel/client/models/action_service_beta_update_target_response.rb +241 -0
- data/lib/zitadel/client/models/action_service_create_target_request.rb +332 -0
- data/lib/zitadel/client/models/action_service_list_targets_request.rb +275 -0
- data/lib/zitadel/client/models/action_service_protobuf_any.rb +230 -0
- data/lib/zitadel/client/models/action_service_rpc_status.rb +250 -0
- data/lib/zitadel/client/models/action_service_set_execution_request.rb +242 -0
- data/lib/zitadel/client/models/action_service_update_target_request.rb +342 -0
- data/lib/zitadel/client/models/web_key_service_beta_activate_web_key_response.rb +231 -0
- data/lib/zitadel/client/models/web_key_service_beta_create_web_key_response.rb +241 -0
- data/lib/zitadel/client/models/web_key_service_beta_delete_web_key_response.rb +231 -0
- data/lib/zitadel/client/models/web_key_service_beta_e_c_d_s_a.rb +254 -0
- data/lib/zitadel/client/models/web_key_service_beta_e_c_d_s_a_curve.rb +43 -0
- data/lib/zitadel/client/models/web_key_service_beta_list_web_keys_response.rb +232 -0
- data/lib/zitadel/client/models/web_key_service_beta_r_s_a.rb +265 -0
- data/lib/zitadel/client/models/web_key_service_beta_r_s_a_bits.rb +43 -0
- data/lib/zitadel/client/models/web_key_service_beta_r_s_a_hasher.rb +43 -0
- data/lib/zitadel/client/models/web_key_service_beta_state.rb +44 -0
- data/lib/zitadel/client/models/web_key_service_beta_web_key.rb +289 -0
- data/lib/zitadel/client/models/web_key_service_create_web_key_request.rb +248 -0
- data/lib/zitadel/client/models/web_key_service_protobuf_any.rb +230 -0
- data/lib/zitadel/client/models/web_key_service_rpc_status.rb +250 -0
- data/lib/zitadel/client/version.rb +1 -1
- data/lib/zitadel/client/zitadel.rb +9 -5
- data/sig/lib.rbs +2 -0
- metadata +50 -2
- data/lib/zitadel/client/api/settings_api.rb +0 -147
@@ -590,6 +590,131 @@ module Zitadel::Client::Api
|
|
590
590
|
@api_client.config.logger.debug "API called: Api::SettingsServiceApi#settings_service_get_password_expiry_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" # MODIFIED
|
591
591
|
end
|
592
592
|
return data, status_code, headers
|
593
|
+
end
|
594
|
+
|
595
|
+
# Get Security Settings
|
596
|
+
# Returns the security settings of the ZITADEL instance.
|
597
|
+
# @param [Hash] opts the optional parameters
|
598
|
+
# @return [SettingsServiceGetSecuritySettingsResponse]
|
599
|
+
def settings_service_get_security_settings(opts = {})
|
600
|
+
data, _status_code, _headers = settings_service_get_security_settings_with_http_info(opts)
|
601
|
+
data
|
602
|
+
end
|
603
|
+
|
604
|
+
# Get Security Settings
|
605
|
+
# Returns the security settings of the ZITADEL instance.
|
606
|
+
# @param [Hash] opts the optional parameters
|
607
|
+
# @return [Array<(SettingsServiceGetSecuritySettingsResponse, Integer, Hash)>] SettingsServiceGetSecuritySettingsResponse data, response status code and response headers
|
608
|
+
def settings_service_get_security_settings_with_http_info(opts = {})
|
609
|
+
if @api_client.config.debugging
|
610
|
+
@api_client.config.logger.debug 'Calling API: Api::SettingsServiceApi.settings_service_get_security_settings ...' # MODIFIED
|
611
|
+
end
|
612
|
+
# resource path
|
613
|
+
local_var_path = '/v2/settings/security'
|
614
|
+
|
615
|
+
# query parameters
|
616
|
+
query_params = opts[:query_params] || {}
|
617
|
+
|
618
|
+
# header parameters
|
619
|
+
header_params = opts[:header_params] || {}
|
620
|
+
# HTTP header 'Accept' (if needed)
|
621
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
622
|
+
|
623
|
+
# form parameters
|
624
|
+
form_params = opts[:form_params] || {}
|
625
|
+
|
626
|
+
# http body (model)
|
627
|
+
post_body = opts[:debug_body]
|
628
|
+
|
629
|
+
# return_type
|
630
|
+
return_type = opts[:debug_return_type] || 'SettingsServiceGetSecuritySettingsResponse'
|
631
|
+
|
632
|
+
# auth_names
|
633
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
634
|
+
|
635
|
+
new_options = opts.merge(
|
636
|
+
:operation => :"Api::SettingsServiceApi.settings_service_get_security_settings", # MODIFIED
|
637
|
+
:header_params => header_params,
|
638
|
+
:query_params => query_params,
|
639
|
+
:form_params => form_params,
|
640
|
+
:body => post_body,
|
641
|
+
:auth_names => auth_names,
|
642
|
+
:return_type => return_type
|
643
|
+
)
|
644
|
+
|
645
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
646
|
+
if @api_client.config.debugging
|
647
|
+
@api_client.config.logger.debug "API called: Api::SettingsServiceApi#settings_service_get_security_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" # MODIFIED
|
648
|
+
end
|
649
|
+
return data, status_code, headers
|
650
|
+
end
|
651
|
+
|
652
|
+
# Set Security Settings
|
653
|
+
# Set the security settings of the ZITADEL instance.
|
654
|
+
# @param settings_service_set_security_settings_request [SettingsServiceSetSecuritySettingsRequest]
|
655
|
+
# @param [Hash] opts the optional parameters
|
656
|
+
# @return [SettingsServiceSetSecuritySettingsResponse]
|
657
|
+
def settings_service_set_security_settings(settings_service_set_security_settings_request, opts = {})
|
658
|
+
data, _status_code, _headers = settings_service_set_security_settings_with_http_info(settings_service_set_security_settings_request, opts)
|
659
|
+
data
|
660
|
+
end
|
661
|
+
|
662
|
+
# Set Security Settings
|
663
|
+
# Set the security settings of the ZITADEL instance.
|
664
|
+
# @param settings_service_set_security_settings_request [SettingsServiceSetSecuritySettingsRequest]
|
665
|
+
# @param [Hash] opts the optional parameters
|
666
|
+
# @return [Array<(SettingsServiceSetSecuritySettingsResponse, Integer, Hash)>] SettingsServiceSetSecuritySettingsResponse data, response status code and response headers
|
667
|
+
def settings_service_set_security_settings_with_http_info(settings_service_set_security_settings_request, opts = {})
|
668
|
+
if @api_client.config.debugging
|
669
|
+
@api_client.config.logger.debug 'Calling API: Api::SettingsServiceApi.settings_service_set_security_settings ...' # MODIFIED
|
670
|
+
end
|
671
|
+
# verify the required parameter 'settings_service_set_security_settings_request' is set
|
672
|
+
if @api_client.config.client_side_validation && settings_service_set_security_settings_request.nil?
|
673
|
+
fail ArgumentError, "Missing the required parameter 'settings_service_set_security_settings_request' when calling Api::SettingsServiceApi.settings_service_set_security_settings" # MODIFIED
|
674
|
+
end
|
675
|
+
# resource path
|
676
|
+
local_var_path = '/v2/policies/security'
|
677
|
+
|
678
|
+
# query parameters
|
679
|
+
query_params = opts[:query_params] || {}
|
680
|
+
|
681
|
+
# header parameters
|
682
|
+
header_params = opts[:header_params] || {}
|
683
|
+
# HTTP header 'Accept' (if needed)
|
684
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
685
|
+
# HTTP header 'Content-Type'
|
686
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
687
|
+
if !content_type.nil?
|
688
|
+
header_params['Content-Type'] = content_type
|
689
|
+
end
|
690
|
+
|
691
|
+
# form parameters
|
692
|
+
form_params = opts[:form_params] || {}
|
693
|
+
|
694
|
+
# http body (model)
|
695
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(settings_service_set_security_settings_request)
|
696
|
+
|
697
|
+
# return_type
|
698
|
+
return_type = opts[:debug_return_type] || 'SettingsServiceSetSecuritySettingsResponse'
|
699
|
+
|
700
|
+
# auth_names
|
701
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
702
|
+
|
703
|
+
new_options = opts.merge(
|
704
|
+
:operation => :"Api::SettingsServiceApi.settings_service_set_security_settings", # MODIFIED
|
705
|
+
:header_params => header_params,
|
706
|
+
:query_params => query_params,
|
707
|
+
:form_params => form_params,
|
708
|
+
:body => post_body,
|
709
|
+
:auth_names => auth_names,
|
710
|
+
:return_type => return_type
|
711
|
+
)
|
712
|
+
|
713
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
|
714
|
+
if @api_client.config.debugging
|
715
|
+
@api_client.config.logger.debug "API called: Api::SettingsServiceApi#settings_service_set_security_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" # MODIFIED
|
716
|
+
end
|
717
|
+
return data, status_code, headers
|
593
718
|
end
|
594
719
|
end
|
595
720
|
end
|
@@ -0,0 +1,273 @@
|
|
1
|
+
=begin
|
2
|
+
#Zitadel SDK
|
3
|
+
|
4
|
+
#The Zitadel SDK is a convenience wrapper around the Zitadel APIs to assist you in integrating with your Zitadel environment. This SDK enables you to handle resources, settings, and configurations within the Zitadel platform.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
Generator version: 7.12.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'cgi'
|
14
|
+
|
15
|
+
module Zitadel::Client::Api
|
16
|
+
class WebKeyServiceApi
|
17
|
+
attr_accessor :api_client
|
18
|
+
|
19
|
+
def initialize(api_client = ApiClient.default)
|
20
|
+
@api_client = api_client
|
21
|
+
end
|
22
|
+
# Activate Web Key
|
23
|
+
# Switch the active signing web key. The previously active key will be deactivated. Note that the JWKs OIDC endpoint returns a cacheable response. Therefore it is not advised to activate a key that has been created within the cache duration (default is 5min), as the public key may not have been propagated to caches and clients yet. Required permission: - `iam.web_key.write` Required feature flag: - `web_key`
|
24
|
+
# @param id [String]
|
25
|
+
# @param [Hash] opts the optional parameters
|
26
|
+
# @return [WebKeyServiceBetaActivateWebKeyResponse]
|
27
|
+
def web_key_service_activate_web_key(id, opts = {})
|
28
|
+
data, _status_code, _headers = web_key_service_activate_web_key_with_http_info(id, opts)
|
29
|
+
data
|
30
|
+
end
|
31
|
+
|
32
|
+
# Activate Web Key
|
33
|
+
# Switch the active signing web key. The previously active key will be deactivated. Note that the JWKs OIDC endpoint returns a cacheable response. Therefore it is not advised to activate a key that has been created within the cache duration (default is 5min), as the public key may not have been propagated to caches and clients yet. Required permission: - `iam.web_key.write` Required feature flag: - `web_key`
|
34
|
+
# @param id [String]
|
35
|
+
# @param [Hash] opts the optional parameters
|
36
|
+
# @return [Array<(WebKeyServiceBetaActivateWebKeyResponse, Integer, Hash)>] WebKeyServiceBetaActivateWebKeyResponse data, response status code and response headers
|
37
|
+
def web_key_service_activate_web_key_with_http_info(id, opts = {})
|
38
|
+
if @api_client.config.debugging
|
39
|
+
@api_client.config.logger.debug 'Calling API: Api::WebKeyServiceApi.web_key_service_activate_web_key ...' # MODIFIED
|
40
|
+
end
|
41
|
+
# verify the required parameter 'id' is set
|
42
|
+
if @api_client.config.client_side_validation && id.nil?
|
43
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling Api::WebKeyServiceApi.web_key_service_activate_web_key" # MODIFIED
|
44
|
+
end
|
45
|
+
# resource path
|
46
|
+
local_var_path = '/v2beta/web_keys/{id}/activate'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
|
47
|
+
|
48
|
+
# query parameters
|
49
|
+
query_params = opts[:query_params] || {}
|
50
|
+
|
51
|
+
# header parameters
|
52
|
+
header_params = opts[:header_params] || {}
|
53
|
+
# HTTP header 'Accept' (if needed)
|
54
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
55
|
+
|
56
|
+
# form parameters
|
57
|
+
form_params = opts[:form_params] || {}
|
58
|
+
|
59
|
+
# http body (model)
|
60
|
+
post_body = opts[:debug_body]
|
61
|
+
|
62
|
+
# return_type
|
63
|
+
return_type = opts[:debug_return_type] || 'WebKeyServiceBetaActivateWebKeyResponse'
|
64
|
+
|
65
|
+
# auth_names
|
66
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
67
|
+
|
68
|
+
new_options = opts.merge(
|
69
|
+
:operation => :"Api::WebKeyServiceApi.web_key_service_activate_web_key", # MODIFIED
|
70
|
+
:header_params => header_params,
|
71
|
+
:query_params => query_params,
|
72
|
+
:form_params => form_params,
|
73
|
+
:body => post_body,
|
74
|
+
:auth_names => auth_names,
|
75
|
+
:return_type => return_type
|
76
|
+
)
|
77
|
+
|
78
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
79
|
+
if @api_client.config.debugging
|
80
|
+
@api_client.config.logger.debug "API called: Api::WebKeyServiceApi#web_key_service_activate_web_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" # MODIFIED
|
81
|
+
end
|
82
|
+
return data, status_code, headers
|
83
|
+
end
|
84
|
+
|
85
|
+
# Create Web Key
|
86
|
+
# Generate a private and public key pair. The private key can be used to sign OIDC tokens after activation. The public key can be used to validate OIDC tokens. The newly created key will have the state `STATE_INITIAL` and is published to the public key endpoint. Note that the JWKs OIDC endpoint returns a cacheable response. If no key type is provided, a RSA key pair with 2048 bits and SHA256 hashing will be created. Required permission: - `iam.web_key.write` Required feature flag: - `web_key`
|
87
|
+
# @param web_key_service_create_web_key_request [WebKeyServiceCreateWebKeyRequest]
|
88
|
+
# @param [Hash] opts the optional parameters
|
89
|
+
# @return [WebKeyServiceBetaCreateWebKeyResponse]
|
90
|
+
def web_key_service_create_web_key(web_key_service_create_web_key_request, opts = {})
|
91
|
+
data, _status_code, _headers = web_key_service_create_web_key_with_http_info(web_key_service_create_web_key_request, opts)
|
92
|
+
data
|
93
|
+
end
|
94
|
+
|
95
|
+
# Create Web Key
|
96
|
+
# Generate a private and public key pair. The private key can be used to sign OIDC tokens after activation. The public key can be used to validate OIDC tokens. The newly created key will have the state `STATE_INITIAL` and is published to the public key endpoint. Note that the JWKs OIDC endpoint returns a cacheable response. If no key type is provided, a RSA key pair with 2048 bits and SHA256 hashing will be created. Required permission: - `iam.web_key.write` Required feature flag: - `web_key`
|
97
|
+
# @param web_key_service_create_web_key_request [WebKeyServiceCreateWebKeyRequest]
|
98
|
+
# @param [Hash] opts the optional parameters
|
99
|
+
# @return [Array<(WebKeyServiceBetaCreateWebKeyResponse, Integer, Hash)>] WebKeyServiceBetaCreateWebKeyResponse data, response status code and response headers
|
100
|
+
def web_key_service_create_web_key_with_http_info(web_key_service_create_web_key_request, opts = {})
|
101
|
+
if @api_client.config.debugging
|
102
|
+
@api_client.config.logger.debug 'Calling API: Api::WebKeyServiceApi.web_key_service_create_web_key ...' # MODIFIED
|
103
|
+
end
|
104
|
+
# verify the required parameter 'web_key_service_create_web_key_request' is set
|
105
|
+
if @api_client.config.client_side_validation && web_key_service_create_web_key_request.nil?
|
106
|
+
fail ArgumentError, "Missing the required parameter 'web_key_service_create_web_key_request' when calling Api::WebKeyServiceApi.web_key_service_create_web_key" # MODIFIED
|
107
|
+
end
|
108
|
+
# resource path
|
109
|
+
local_var_path = '/v2beta/web_keys'
|
110
|
+
|
111
|
+
# query parameters
|
112
|
+
query_params = opts[:query_params] || {}
|
113
|
+
|
114
|
+
# header parameters
|
115
|
+
header_params = opts[:header_params] || {}
|
116
|
+
# HTTP header 'Accept' (if needed)
|
117
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
118
|
+
# HTTP header 'Content-Type'
|
119
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
120
|
+
if !content_type.nil?
|
121
|
+
header_params['Content-Type'] = content_type
|
122
|
+
end
|
123
|
+
|
124
|
+
# form parameters
|
125
|
+
form_params = opts[:form_params] || {}
|
126
|
+
|
127
|
+
# http body (model)
|
128
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(web_key_service_create_web_key_request)
|
129
|
+
|
130
|
+
# return_type
|
131
|
+
return_type = opts[:debug_return_type] || 'WebKeyServiceBetaCreateWebKeyResponse'
|
132
|
+
|
133
|
+
# auth_names
|
134
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
135
|
+
|
136
|
+
new_options = opts.merge(
|
137
|
+
:operation => :"Api::WebKeyServiceApi.web_key_service_create_web_key", # MODIFIED
|
138
|
+
:header_params => header_params,
|
139
|
+
:query_params => query_params,
|
140
|
+
:form_params => form_params,
|
141
|
+
:body => post_body,
|
142
|
+
:auth_names => auth_names,
|
143
|
+
:return_type => return_type
|
144
|
+
)
|
145
|
+
|
146
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
147
|
+
if @api_client.config.debugging
|
148
|
+
@api_client.config.logger.debug "API called: Api::WebKeyServiceApi#web_key_service_create_web_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" # MODIFIED
|
149
|
+
end
|
150
|
+
return data, status_code, headers
|
151
|
+
end
|
152
|
+
|
153
|
+
# Delete Web Key
|
154
|
+
# Delete a web key pair. Only inactive keys can be deleted. Once a key is deleted, any tokens signed by this key will be invalid. Note that the JWKs OIDC endpoint returns a cacheable response. In case the web key is not found, the request will return a successful response as the desired state is already achieved. You can check the change date in the response to verify if the web key was deleted during the request. Required permission: - `iam.web_key.delete` Required feature flag: - `web_key`
|
155
|
+
# @param id [String]
|
156
|
+
# @param [Hash] opts the optional parameters
|
157
|
+
# @return [WebKeyServiceBetaDeleteWebKeyResponse]
|
158
|
+
def web_key_service_delete_web_key(id, opts = {})
|
159
|
+
data, _status_code, _headers = web_key_service_delete_web_key_with_http_info(id, opts)
|
160
|
+
data
|
161
|
+
end
|
162
|
+
|
163
|
+
# Delete Web Key
|
164
|
+
# Delete a web key pair. Only inactive keys can be deleted. Once a key is deleted, any tokens signed by this key will be invalid. Note that the JWKs OIDC endpoint returns a cacheable response. In case the web key is not found, the request will return a successful response as the desired state is already achieved. You can check the change date in the response to verify if the web key was deleted during the request. Required permission: - `iam.web_key.delete` Required feature flag: - `web_key`
|
165
|
+
# @param id [String]
|
166
|
+
# @param [Hash] opts the optional parameters
|
167
|
+
# @return [Array<(WebKeyServiceBetaDeleteWebKeyResponse, Integer, Hash)>] WebKeyServiceBetaDeleteWebKeyResponse data, response status code and response headers
|
168
|
+
def web_key_service_delete_web_key_with_http_info(id, opts = {})
|
169
|
+
if @api_client.config.debugging
|
170
|
+
@api_client.config.logger.debug 'Calling API: Api::WebKeyServiceApi.web_key_service_delete_web_key ...' # MODIFIED
|
171
|
+
end
|
172
|
+
# verify the required parameter 'id' is set
|
173
|
+
if @api_client.config.client_side_validation && id.nil?
|
174
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling Api::WebKeyServiceApi.web_key_service_delete_web_key" # MODIFIED
|
175
|
+
end
|
176
|
+
# resource path
|
177
|
+
local_var_path = '/v2beta/web_keys/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
|
178
|
+
|
179
|
+
# query parameters
|
180
|
+
query_params = opts[:query_params] || {}
|
181
|
+
|
182
|
+
# header parameters
|
183
|
+
header_params = opts[:header_params] || {}
|
184
|
+
# HTTP header 'Accept' (if needed)
|
185
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
186
|
+
|
187
|
+
# form parameters
|
188
|
+
form_params = opts[:form_params] || {}
|
189
|
+
|
190
|
+
# http body (model)
|
191
|
+
post_body = opts[:debug_body]
|
192
|
+
|
193
|
+
# return_type
|
194
|
+
return_type = opts[:debug_return_type] || 'WebKeyServiceBetaDeleteWebKeyResponse'
|
195
|
+
|
196
|
+
# auth_names
|
197
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
198
|
+
|
199
|
+
new_options = opts.merge(
|
200
|
+
:operation => :"Api::WebKeyServiceApi.web_key_service_delete_web_key", # MODIFIED
|
201
|
+
:header_params => header_params,
|
202
|
+
:query_params => query_params,
|
203
|
+
:form_params => form_params,
|
204
|
+
:body => post_body,
|
205
|
+
:auth_names => auth_names,
|
206
|
+
:return_type => return_type
|
207
|
+
)
|
208
|
+
|
209
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
210
|
+
if @api_client.config.debugging
|
211
|
+
@api_client.config.logger.debug "API called: Api::WebKeyServiceApi#web_key_service_delete_web_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" # MODIFIED
|
212
|
+
end
|
213
|
+
return data, status_code, headers
|
214
|
+
end
|
215
|
+
|
216
|
+
# List Web Keys
|
217
|
+
# List all web keys and their states. Required permission: - `iam.web_key.read` Required feature flag: - `web_key`
|
218
|
+
# @param [Hash] opts the optional parameters
|
219
|
+
# @return [WebKeyServiceBetaListWebKeysResponse]
|
220
|
+
def web_key_service_list_web_keys(opts = {})
|
221
|
+
data, _status_code, _headers = web_key_service_list_web_keys_with_http_info(opts)
|
222
|
+
data
|
223
|
+
end
|
224
|
+
|
225
|
+
# List Web Keys
|
226
|
+
# List all web keys and their states. Required permission: - `iam.web_key.read` Required feature flag: - `web_key`
|
227
|
+
# @param [Hash] opts the optional parameters
|
228
|
+
# @return [Array<(WebKeyServiceBetaListWebKeysResponse, Integer, Hash)>] WebKeyServiceBetaListWebKeysResponse data, response status code and response headers
|
229
|
+
def web_key_service_list_web_keys_with_http_info(opts = {})
|
230
|
+
if @api_client.config.debugging
|
231
|
+
@api_client.config.logger.debug 'Calling API: Api::WebKeyServiceApi.web_key_service_list_web_keys ...' # MODIFIED
|
232
|
+
end
|
233
|
+
# resource path
|
234
|
+
local_var_path = '/v2beta/web_keys'
|
235
|
+
|
236
|
+
# query parameters
|
237
|
+
query_params = opts[:query_params] || {}
|
238
|
+
|
239
|
+
# header parameters
|
240
|
+
header_params = opts[:header_params] || {}
|
241
|
+
# HTTP header 'Accept' (if needed)
|
242
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
243
|
+
|
244
|
+
# form parameters
|
245
|
+
form_params = opts[:form_params] || {}
|
246
|
+
|
247
|
+
# http body (model)
|
248
|
+
post_body = opts[:debug_body]
|
249
|
+
|
250
|
+
# return_type
|
251
|
+
return_type = opts[:debug_return_type] || 'WebKeyServiceBetaListWebKeysResponse'
|
252
|
+
|
253
|
+
# auth_names
|
254
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
255
|
+
|
256
|
+
new_options = opts.merge(
|
257
|
+
:operation => :"Api::WebKeyServiceApi.web_key_service_list_web_keys", # MODIFIED
|
258
|
+
:header_params => header_params,
|
259
|
+
:query_params => query_params,
|
260
|
+
:form_params => form_params,
|
261
|
+
:body => post_body,
|
262
|
+
:auth_names => auth_names,
|
263
|
+
:return_type => return_type
|
264
|
+
)
|
265
|
+
|
266
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
267
|
+
if @api_client.config.debugging
|
268
|
+
@api_client.config.logger.debug "API called: Api::WebKeyServiceApi#web_key_service_list_web_keys\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" # MODIFIED
|
269
|
+
end
|
270
|
+
return data, status_code, headers
|
271
|
+
end
|
272
|
+
end
|
273
|
+
end
|
@@ -0,0 +1,257 @@
|
|
1
|
+
=begin
|
2
|
+
#Zitadel SDK
|
3
|
+
|
4
|
+
#The Zitadel SDK is a convenience wrapper around the Zitadel APIs to assist you in integrating with your Zitadel environment. This SDK enables you to handle resources, settings, and configurations within the Zitadel platform.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
Generator version: 7.12.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module Zitadel::Client::Models
|
17
|
+
class ActionServiceBetaCondition
|
18
|
+
attr_accessor :request
|
19
|
+
|
20
|
+
attr_accessor :response
|
21
|
+
|
22
|
+
attr_accessor :function
|
23
|
+
|
24
|
+
attr_accessor :event
|
25
|
+
|
26
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
27
|
+
def self.attribute_map
|
28
|
+
{
|
29
|
+
:'request' => :'request',
|
30
|
+
:'response' => :'response',
|
31
|
+
:'function' => :'function',
|
32
|
+
:'event' => :'event'
|
33
|
+
}
|
34
|
+
end
|
35
|
+
|
36
|
+
# Returns attribute mapping this model knows about
|
37
|
+
def self.acceptable_attribute_map
|
38
|
+
attribute_map
|
39
|
+
end
|
40
|
+
|
41
|
+
# Returns all the JSON keys this model knows about
|
42
|
+
def self.acceptable_attributes
|
43
|
+
acceptable_attribute_map.values
|
44
|
+
end
|
45
|
+
|
46
|
+
# Attribute type mapping.
|
47
|
+
def self.openapi_types
|
48
|
+
{
|
49
|
+
:'request' => :'ActionServiceBetaRequestExecution',
|
50
|
+
:'response' => :'ActionServiceBetaResponseExecution',
|
51
|
+
:'function' => :'ActionServiceBetaFunctionExecution',
|
52
|
+
:'event' => :'ActionServiceBetaEventExecution'
|
53
|
+
}
|
54
|
+
end
|
55
|
+
|
56
|
+
# List of attributes with nullable: true
|
57
|
+
def self.openapi_nullable
|
58
|
+
Set.new([
|
59
|
+
])
|
60
|
+
end
|
61
|
+
|
62
|
+
# Initializes the object
|
63
|
+
# @param [Hash] attributes Models attributes in the form of hash
|
64
|
+
def initialize(attributes = {})
|
65
|
+
if (!attributes.is_a?(Hash))
|
66
|
+
# MODIFIED: Updated class name in error message
|
67
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Zitadel::Client::Models::ActionServiceBetaCondition` initialize method"
|
68
|
+
end
|
69
|
+
|
70
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
71
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
72
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
73
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
74
|
+
# MODIFIED: Updated class name in error message
|
75
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Zitadel::Client::Models::ActionServiceBetaCondition`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
76
|
+
end
|
77
|
+
h[k.to_sym] = v
|
78
|
+
}
|
79
|
+
|
80
|
+
if attributes.key?(:'request')
|
81
|
+
self.request = attributes[:'request']
|
82
|
+
end
|
83
|
+
|
84
|
+
if attributes.key?(:'response')
|
85
|
+
self.response = attributes[:'response']
|
86
|
+
end
|
87
|
+
|
88
|
+
if attributes.key?(:'function')
|
89
|
+
self.function = attributes[:'function']
|
90
|
+
end
|
91
|
+
|
92
|
+
if attributes.key?(:'event')
|
93
|
+
self.event = attributes[:'event']
|
94
|
+
end
|
95
|
+
end
|
96
|
+
|
97
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
98
|
+
# @return Array for valid properties with the reasons
|
99
|
+
def list_invalid_properties
|
100
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
101
|
+
invalid_properties = Array.new
|
102
|
+
invalid_properties
|
103
|
+
end
|
104
|
+
|
105
|
+
# Check to see if the all the properties in the model are valid
|
106
|
+
# @return true if the model is valid
|
107
|
+
def valid?
|
108
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
109
|
+
true
|
110
|
+
end
|
111
|
+
|
112
|
+
# Checks equality by comparing each attribute.
|
113
|
+
# @param [Object] Object to be compared
|
114
|
+
def ==(o)
|
115
|
+
return true if self.equal?(o)
|
116
|
+
self.class == o.class &&
|
117
|
+
request == o.request &&
|
118
|
+
response == o.response &&
|
119
|
+
function == o.function &&
|
120
|
+
event == o.event
|
121
|
+
end
|
122
|
+
|
123
|
+
# @see the `==` method
|
124
|
+
# @param [Object] Object to be compared
|
125
|
+
def eql?(o)
|
126
|
+
self == o
|
127
|
+
end
|
128
|
+
|
129
|
+
# Calculates hash code according to all attributes.
|
130
|
+
# @return [Integer] Hash code
|
131
|
+
def hash
|
132
|
+
[request, response, function, event].hash
|
133
|
+
end
|
134
|
+
|
135
|
+
# Builds the object from hash
|
136
|
+
# @param [Hash] attributes Models attributes in the form of hash
|
137
|
+
# @return [Object] Returns the model itself
|
138
|
+
def self.build_from_hash(attributes)
|
139
|
+
return nil unless attributes.is_a?(Hash)
|
140
|
+
attributes = attributes.transform_keys(&:to_sym)
|
141
|
+
transformed_hash = {}
|
142
|
+
openapi_types.each_pair do |key, type|
|
143
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
144
|
+
transformed_hash["#{key}"] = nil
|
145
|
+
elsif type =~ /\AArray<(.*)>/i
|
146
|
+
# check to ensure the input is an array given that the attribute
|
147
|
+
# is documented as an array but the input is not
|
148
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
149
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
150
|
+
end
|
151
|
+
elsif !attributes[attribute_map[key]].nil?
|
152
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
153
|
+
end
|
154
|
+
end
|
155
|
+
new(transformed_hash) # `new` will call the initialize method of the specific model class.
|
156
|
+
end
|
157
|
+
|
158
|
+
# Deserializes the data based on type
|
159
|
+
# @param string type Data type
|
160
|
+
# @param string value Value to be deserialized
|
161
|
+
# @return [Object] Deserialized data
|
162
|
+
def self._deserialize(type, value)
|
163
|
+
case type.to_sym
|
164
|
+
when :Time
|
165
|
+
Time.parse(value)
|
166
|
+
when :Date
|
167
|
+
Date.parse(value)
|
168
|
+
when :String
|
169
|
+
value.to_s
|
170
|
+
when :Integer
|
171
|
+
value.to_i
|
172
|
+
when :Float
|
173
|
+
value.to_f
|
174
|
+
when :Boolean
|
175
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
176
|
+
true
|
177
|
+
else
|
178
|
+
false
|
179
|
+
end
|
180
|
+
when :Object
|
181
|
+
# generic object (usually a Hash), return directly
|
182
|
+
value
|
183
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
184
|
+
inner_type = Regexp.last_match[:inner_type]
|
185
|
+
value.map { |v| _deserialize(inner_type, v) }
|
186
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
187
|
+
k_type = Regexp.last_match[:k_type]
|
188
|
+
v_type = Regexp.last_match[:v_type]
|
189
|
+
{}.tap do |hash|
|
190
|
+
value.each do |k, v|
|
191
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
192
|
+
end
|
193
|
+
end
|
194
|
+
else # model
|
195
|
+
# models (e.g. Pet) or oneOf/anyOf constructs that resolve to a model name
|
196
|
+
# MODIFIED: Ensure model is looked up in the Models namespace
|
197
|
+
# 'type' here is expected to be the simple class name (e.g., "User", "OrderDetails")
|
198
|
+
klass = Zitadel::Client::Models.const_get(type)
|
199
|
+
# The `klass.build` method is for oneOf/anyOf types (defined in partial_oneof_module.mustache / partial_anyof_module.mustache)
|
200
|
+
# The `klass.build_from_hash` is for regular model types (defined in this base_object.mustache itself)
|
201
|
+
if klass.respond_to?(:openapi_one_of) || klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_allOf)
|
202
|
+
klass.build(value) # For oneOf/anyOf/allOf, delegate to their specific build method
|
203
|
+
else
|
204
|
+
klass.build_from_hash(value) # For regular models
|
205
|
+
end
|
206
|
+
end
|
207
|
+
end
|
208
|
+
|
209
|
+
# Returns the string representation of the object
|
210
|
+
# @return [String] String presentation of the object
|
211
|
+
def to_s
|
212
|
+
to_hash.to_s
|
213
|
+
end
|
214
|
+
|
215
|
+
# to_body is an alias to to_hash (backward compatibility)
|
216
|
+
# @return [Hash] Returns the object in the form of hash
|
217
|
+
def to_body
|
218
|
+
to_hash
|
219
|
+
end
|
220
|
+
|
221
|
+
# Returns the object in the form of hash
|
222
|
+
# @return [Hash] Returns the object in the form of hash
|
223
|
+
def to_hash
|
224
|
+
hash = {} # Calls super.to_hash if parent exists
|
225
|
+
self.class.attribute_map.each_pair do |attr, param|
|
226
|
+
value = self.send(attr)
|
227
|
+
if value.nil?
|
228
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
229
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
230
|
+
end
|
231
|
+
|
232
|
+
hash[param] = _to_hash(value)
|
233
|
+
end
|
234
|
+
hash
|
235
|
+
end
|
236
|
+
|
237
|
+
# Outputs non-array value in the form of hash
|
238
|
+
# For object, use to_hash. Otherwise, just return the value
|
239
|
+
# @param [Object] value Any valid value
|
240
|
+
# @return [Hash] Returns the value in the form of hash
|
241
|
+
def _to_hash(value)
|
242
|
+
if value.is_a?(Array)
|
243
|
+
value.compact.map { |v| _to_hash(v) }
|
244
|
+
elsif value.is_a?(Hash)
|
245
|
+
{}.tap do |hash|
|
246
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
247
|
+
end
|
248
|
+
elsif value.respond_to? :to_hash
|
249
|
+
value.to_hash
|
250
|
+
else
|
251
|
+
value
|
252
|
+
end
|
253
|
+
end
|
254
|
+
|
255
|
+
end
|
256
|
+
|
257
|
+
end
|