akeyless 3.0.1 → 3.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +24 -3
- data/docs/AttributeTypeAndValue.md +20 -0
- data/docs/CertificateChainInfo.md +22 -0
- data/docs/CertificateExpirationEvent.md +18 -0
- data/docs/CertificateInfo.md +62 -0
- data/docs/Connect.md +2 -0
- data/docs/CreateEventForwarder.md +48 -0
- data/docs/CreateEventForwarderOutput.md +18 -0
- data/docs/CreateRotatedSecret.md +2 -0
- data/docs/DeleteEventForwarder.md +24 -0
- data/docs/EmailEntry.md +20 -0
- data/docs/Extension.md +22 -0
- data/docs/GatewayUpdateItem.md +2 -0
- data/docs/GetEventForwarder.md +24 -0
- data/docs/GetEventForwarderOutput.md +18 -0
- data/docs/Item.md +4 -0
- data/docs/ItemGeneralInfo.md +2 -0
- data/docs/ListSharedItems.md +24 -0
- data/docs/Name.md +28 -0
- data/docs/NotiForwarder.md +56 -0
- data/docs/RequestAccess.md +28 -0
- data/docs/RequestAccessOutput.md +18 -0
- data/docs/Target.md +4 -0
- data/docs/UpdateEventForwarder.md +40 -0
- data/docs/UpdateRotatedSecret.md +2 -0
- data/docs/V2Api.md +377 -63
- data/lib/akeyless/api/v2_api.rb +384 -64
- data/lib/akeyless/api_error.rb +1 -0
- data/lib/akeyless/configuration.rb +11 -0
- data/lib/akeyless/models/attribute_type_and_value.rb +231 -0
- data/lib/akeyless/models/certificate_chain_info.rb +241 -0
- data/lib/akeyless/models/certificate_expiration_event.rb +219 -0
- data/lib/akeyless/models/certificate_info.rb +434 -0
- data/lib/akeyless/models/connect.rb +11 -1
- data/lib/akeyless/models/create_event_forwarder.rb +394 -0
- data/lib/akeyless/models/create_event_forwarder_output.rb +219 -0
- data/lib/akeyless/models/create_rotated_secret.rb +11 -1
- data/lib/akeyless/models/delete_event_forwarder.rb +255 -0
- data/lib/akeyless/models/email_entry.rb +228 -0
- data/lib/akeyless/models/extension.rb +237 -0
- data/lib/akeyless/models/gateway_update_item.rb +11 -1
- data/lib/akeyless/models/get_event_forwarder.rb +255 -0
- data/lib/akeyless/models/get_event_forwarder_output.rb +219 -0
- data/lib/akeyless/models/item.rb +19 -1
- data/lib/akeyless/models/item_general_info.rb +10 -1
- data/lib/akeyless/models/list_shared_items.rb +253 -0
- data/lib/akeyless/models/name.rb +277 -0
- data/lib/akeyless/models/noti_forwarder.rb +400 -0
- data/lib/akeyless/models/request_access.rb +282 -0
- data/lib/akeyless/models/request_access_output.rb +219 -0
- data/lib/akeyless/models/target.rb +19 -1
- data/lib/akeyless/models/update_event_forwarder.rb +341 -0
- data/lib/akeyless/models/update_rotated_secret.rb +11 -1
- data/lib/akeyless/version.rb +1 -1
- data/lib/akeyless.rb +17 -1
- data/spec/models/attribute_type_and_value_spec.rb +40 -0
- data/spec/models/certificate_chain_info_spec.rb +46 -0
- data/spec/models/certificate_expiration_event_spec.rb +34 -0
- data/spec/models/certificate_info_spec.rb +166 -0
- data/spec/models/create_event_forwarder_output_spec.rb +34 -0
- data/spec/models/create_event_forwarder_spec.rb +124 -0
- data/spec/models/delete_event_forwarder_spec.rb +52 -0
- data/spec/models/email_entry_spec.rb +40 -0
- data/spec/models/extension_spec.rb +46 -0
- data/spec/models/get_event_forwarder_output_spec.rb +34 -0
- data/spec/models/get_event_forwarder_spec.rb +52 -0
- data/spec/models/list_shared_items_spec.rb +52 -0
- data/spec/models/name_spec.rb +64 -0
- data/spec/models/noti_forwarder_spec.rb +148 -0
- data/spec/models/request_access_output_spec.rb +34 -0
- data/spec/models/request_access_spec.rb +64 -0
- data/spec/models/update_event_forwarder_spec.rb +100 -0
- metadata +597 -529
data/lib/akeyless/api/v2_api.rb
CHANGED
@@ -1683,6 +1683,70 @@ module Akeyless
|
|
1683
1683
|
return data, status_code, headers
|
1684
1684
|
end
|
1685
1685
|
|
1686
|
+
# @param body [CreateEventForwarder]
|
1687
|
+
# @param [Hash] opts the optional parameters
|
1688
|
+
# @return [CreateEventForwarderOutput]
|
1689
|
+
def create_event_forwarder(body, opts = {})
|
1690
|
+
data, _status_code, _headers = create_event_forwarder_with_http_info(body, opts)
|
1691
|
+
data
|
1692
|
+
end
|
1693
|
+
|
1694
|
+
# @param body [CreateEventForwarder]
|
1695
|
+
# @param [Hash] opts the optional parameters
|
1696
|
+
# @return [Array<(CreateEventForwarderOutput, Integer, Hash)>] CreateEventForwarderOutput data, response status code and response headers
|
1697
|
+
def create_event_forwarder_with_http_info(body, opts = {})
|
1698
|
+
if @api_client.config.debugging
|
1699
|
+
@api_client.config.logger.debug 'Calling API: V2Api.create_event_forwarder ...'
|
1700
|
+
end
|
1701
|
+
# verify the required parameter 'body' is set
|
1702
|
+
if @api_client.config.client_side_validation && body.nil?
|
1703
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling V2Api.create_event_forwarder"
|
1704
|
+
end
|
1705
|
+
# resource path
|
1706
|
+
local_var_path = '/create-event-forwarder'
|
1707
|
+
|
1708
|
+
# query parameters
|
1709
|
+
query_params = opts[:query_params] || {}
|
1710
|
+
|
1711
|
+
# header parameters
|
1712
|
+
header_params = opts[:header_params] || {}
|
1713
|
+
# HTTP header 'Accept' (if needed)
|
1714
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1715
|
+
# HTTP header 'Content-Type'
|
1716
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
1717
|
+
if !content_type.nil?
|
1718
|
+
header_params['Content-Type'] = content_type
|
1719
|
+
end
|
1720
|
+
|
1721
|
+
# form parameters
|
1722
|
+
form_params = opts[:form_params] || {}
|
1723
|
+
|
1724
|
+
# http body (model)
|
1725
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(body)
|
1726
|
+
|
1727
|
+
# return_type
|
1728
|
+
return_type = opts[:debug_return_type] || 'CreateEventForwarderOutput'
|
1729
|
+
|
1730
|
+
# auth_names
|
1731
|
+
auth_names = opts[:debug_auth_names] || []
|
1732
|
+
|
1733
|
+
new_options = opts.merge(
|
1734
|
+
:operation => :"V2Api.create_event_forwarder",
|
1735
|
+
:header_params => header_params,
|
1736
|
+
:query_params => query_params,
|
1737
|
+
:form_params => form_params,
|
1738
|
+
:body => post_body,
|
1739
|
+
:auth_names => auth_names,
|
1740
|
+
:return_type => return_type
|
1741
|
+
)
|
1742
|
+
|
1743
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1744
|
+
if @api_client.config.debugging
|
1745
|
+
@api_client.config.logger.debug "API called: V2Api#create_event_forwarder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1746
|
+
end
|
1747
|
+
return data, status_code, headers
|
1748
|
+
end
|
1749
|
+
|
1686
1750
|
# @param body [CreateGcpTarget]
|
1687
1751
|
# @param [Hash] opts the optional parameters
|
1688
1752
|
# @return [CreateGcpTargetOutput]
|
@@ -3027,6 +3091,70 @@ module Akeyless
|
|
3027
3091
|
return data, status_code, headers
|
3028
3092
|
end
|
3029
3093
|
|
3094
|
+
# @param body [DeleteEventForwarder]
|
3095
|
+
# @param [Hash] opts the optional parameters
|
3096
|
+
# @return [Object]
|
3097
|
+
def delete_event_forwarder(body, opts = {})
|
3098
|
+
data, _status_code, _headers = delete_event_forwarder_with_http_info(body, opts)
|
3099
|
+
data
|
3100
|
+
end
|
3101
|
+
|
3102
|
+
# @param body [DeleteEventForwarder]
|
3103
|
+
# @param [Hash] opts the optional parameters
|
3104
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
3105
|
+
def delete_event_forwarder_with_http_info(body, opts = {})
|
3106
|
+
if @api_client.config.debugging
|
3107
|
+
@api_client.config.logger.debug 'Calling API: V2Api.delete_event_forwarder ...'
|
3108
|
+
end
|
3109
|
+
# verify the required parameter 'body' is set
|
3110
|
+
if @api_client.config.client_side_validation && body.nil?
|
3111
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling V2Api.delete_event_forwarder"
|
3112
|
+
end
|
3113
|
+
# resource path
|
3114
|
+
local_var_path = '/delete-event-forwarder'
|
3115
|
+
|
3116
|
+
# query parameters
|
3117
|
+
query_params = opts[:query_params] || {}
|
3118
|
+
|
3119
|
+
# header parameters
|
3120
|
+
header_params = opts[:header_params] || {}
|
3121
|
+
# HTTP header 'Accept' (if needed)
|
3122
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
3123
|
+
# HTTP header 'Content-Type'
|
3124
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
3125
|
+
if !content_type.nil?
|
3126
|
+
header_params['Content-Type'] = content_type
|
3127
|
+
end
|
3128
|
+
|
3129
|
+
# form parameters
|
3130
|
+
form_params = opts[:form_params] || {}
|
3131
|
+
|
3132
|
+
# http body (model)
|
3133
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(body)
|
3134
|
+
|
3135
|
+
# return_type
|
3136
|
+
return_type = opts[:debug_return_type] || 'Object'
|
3137
|
+
|
3138
|
+
# auth_names
|
3139
|
+
auth_names = opts[:debug_auth_names] || []
|
3140
|
+
|
3141
|
+
new_options = opts.merge(
|
3142
|
+
:operation => :"V2Api.delete_event_forwarder",
|
3143
|
+
:header_params => header_params,
|
3144
|
+
:query_params => query_params,
|
3145
|
+
:form_params => form_params,
|
3146
|
+
:body => post_body,
|
3147
|
+
:auth_names => auth_names,
|
3148
|
+
:return_type => return_type
|
3149
|
+
)
|
3150
|
+
|
3151
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
3152
|
+
if @api_client.config.debugging
|
3153
|
+
@api_client.config.logger.debug "API called: V2Api#delete_event_forwarder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
3154
|
+
end
|
3155
|
+
return data, status_code, headers
|
3156
|
+
end
|
3157
|
+
|
3030
3158
|
# @param body [DeleteItem]
|
3031
3159
|
# @param [Hash] opts the optional parameters
|
3032
3160
|
# @return [DeleteItemOutput]
|
@@ -4051,70 +4179,6 @@ module Akeyless
|
|
4051
4179
|
return data, status_code, headers
|
4052
4180
|
end
|
4053
4181
|
|
4054
|
-
# @param body [GatewayAddAllowedManagementAccess]
|
4055
|
-
# @param [Hash] opts the optional parameters
|
4056
|
-
# @return [Object]
|
4057
|
-
def gateway_add_allowed_management_access(body, opts = {})
|
4058
|
-
data, _status_code, _headers = gateway_add_allowed_management_access_with_http_info(body, opts)
|
4059
|
-
data
|
4060
|
-
end
|
4061
|
-
|
4062
|
-
# @param body [GatewayAddAllowedManagementAccess]
|
4063
|
-
# @param [Hash] opts the optional parameters
|
4064
|
-
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
4065
|
-
def gateway_add_allowed_management_access_with_http_info(body, opts = {})
|
4066
|
-
if @api_client.config.debugging
|
4067
|
-
@api_client.config.logger.debug 'Calling API: V2Api.gateway_add_allowed_management_access ...'
|
4068
|
-
end
|
4069
|
-
# verify the required parameter 'body' is set
|
4070
|
-
if @api_client.config.client_side_validation && body.nil?
|
4071
|
-
fail ArgumentError, "Missing the required parameter 'body' when calling V2Api.gateway_add_allowed_management_access"
|
4072
|
-
end
|
4073
|
-
# resource path
|
4074
|
-
local_var_path = '/gateway-add-allow-management-access'
|
4075
|
-
|
4076
|
-
# query parameters
|
4077
|
-
query_params = opts[:query_params] || {}
|
4078
|
-
|
4079
|
-
# header parameters
|
4080
|
-
header_params = opts[:header_params] || {}
|
4081
|
-
# HTTP header 'Accept' (if needed)
|
4082
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
4083
|
-
# HTTP header 'Content-Type'
|
4084
|
-
content_type = @api_client.select_header_content_type(['application/json'])
|
4085
|
-
if !content_type.nil?
|
4086
|
-
header_params['Content-Type'] = content_type
|
4087
|
-
end
|
4088
|
-
|
4089
|
-
# form parameters
|
4090
|
-
form_params = opts[:form_params] || {}
|
4091
|
-
|
4092
|
-
# http body (model)
|
4093
|
-
post_body = opts[:debug_body] || @api_client.object_to_http_body(body)
|
4094
|
-
|
4095
|
-
# return_type
|
4096
|
-
return_type = opts[:debug_return_type] || 'Object'
|
4097
|
-
|
4098
|
-
# auth_names
|
4099
|
-
auth_names = opts[:debug_auth_names] || []
|
4100
|
-
|
4101
|
-
new_options = opts.merge(
|
4102
|
-
:operation => :"V2Api.gateway_add_allowed_management_access",
|
4103
|
-
:header_params => header_params,
|
4104
|
-
:query_params => query_params,
|
4105
|
-
:form_params => form_params,
|
4106
|
-
:body => post_body,
|
4107
|
-
:auth_names => auth_names,
|
4108
|
-
:return_type => return_type
|
4109
|
-
)
|
4110
|
-
|
4111
|
-
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
4112
|
-
if @api_client.config.debugging
|
4113
|
-
@api_client.config.logger.debug "API called: V2Api#gateway_add_allowed_management_access\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
4114
|
-
end
|
4115
|
-
return data, status_code, headers
|
4116
|
-
end
|
4117
|
-
|
4118
4182
|
# @param body [GatewayCreateK8SAuthConfig]
|
4119
4183
|
# @param [Hash] opts the optional parameters
|
4120
4184
|
# @return [GatewayCreateK8SAuthConfigOutput]
|
@@ -8956,6 +9020,70 @@ module Akeyless
|
|
8956
9020
|
return data, status_code, headers
|
8957
9021
|
end
|
8958
9022
|
|
9023
|
+
# @param body [GetEventForwarder]
|
9024
|
+
# @param [Hash] opts the optional parameters
|
9025
|
+
# @return [GetEventForwarderOutput]
|
9026
|
+
def get_event_forwarder(body, opts = {})
|
9027
|
+
data, _status_code, _headers = get_event_forwarder_with_http_info(body, opts)
|
9028
|
+
data
|
9029
|
+
end
|
9030
|
+
|
9031
|
+
# @param body [GetEventForwarder]
|
9032
|
+
# @param [Hash] opts the optional parameters
|
9033
|
+
# @return [Array<(GetEventForwarderOutput, Integer, Hash)>] GetEventForwarderOutput data, response status code and response headers
|
9034
|
+
def get_event_forwarder_with_http_info(body, opts = {})
|
9035
|
+
if @api_client.config.debugging
|
9036
|
+
@api_client.config.logger.debug 'Calling API: V2Api.get_event_forwarder ...'
|
9037
|
+
end
|
9038
|
+
# verify the required parameter 'body' is set
|
9039
|
+
if @api_client.config.client_side_validation && body.nil?
|
9040
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling V2Api.get_event_forwarder"
|
9041
|
+
end
|
9042
|
+
# resource path
|
9043
|
+
local_var_path = '/get-event-forwarder'
|
9044
|
+
|
9045
|
+
# query parameters
|
9046
|
+
query_params = opts[:query_params] || {}
|
9047
|
+
|
9048
|
+
# header parameters
|
9049
|
+
header_params = opts[:header_params] || {}
|
9050
|
+
# HTTP header 'Accept' (if needed)
|
9051
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
9052
|
+
# HTTP header 'Content-Type'
|
9053
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
9054
|
+
if !content_type.nil?
|
9055
|
+
header_params['Content-Type'] = content_type
|
9056
|
+
end
|
9057
|
+
|
9058
|
+
# form parameters
|
9059
|
+
form_params = opts[:form_params] || {}
|
9060
|
+
|
9061
|
+
# http body (model)
|
9062
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(body)
|
9063
|
+
|
9064
|
+
# return_type
|
9065
|
+
return_type = opts[:debug_return_type] || 'GetEventForwarderOutput'
|
9066
|
+
|
9067
|
+
# auth_names
|
9068
|
+
auth_names = opts[:debug_auth_names] || []
|
9069
|
+
|
9070
|
+
new_options = opts.merge(
|
9071
|
+
:operation => :"V2Api.get_event_forwarder",
|
9072
|
+
:header_params => header_params,
|
9073
|
+
:query_params => query_params,
|
9074
|
+
:form_params => form_params,
|
9075
|
+
:body => post_body,
|
9076
|
+
:auth_names => auth_names,
|
9077
|
+
:return_type => return_type
|
9078
|
+
)
|
9079
|
+
|
9080
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
9081
|
+
if @api_client.config.debugging
|
9082
|
+
@api_client.config.logger.debug "API called: V2Api#get_event_forwarder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
9083
|
+
end
|
9084
|
+
return data, status_code, headers
|
9085
|
+
end
|
9086
|
+
|
8959
9087
|
# @param body [GetKubeExecCreds]
|
8960
9088
|
# @param [Hash] opts the optional parameters
|
8961
9089
|
# @return [GetKubeExecCredsOutput]
|
@@ -10632,6 +10760,70 @@ module Akeyless
|
|
10632
10760
|
return data, status_code, headers
|
10633
10761
|
end
|
10634
10762
|
|
10763
|
+
# @param body [ListSharedItems]
|
10764
|
+
# @param [Hash] opts the optional parameters
|
10765
|
+
# @return [nil]
|
10766
|
+
def list_shared_items(body, opts = {})
|
10767
|
+
list_shared_items_with_http_info(body, opts)
|
10768
|
+
nil
|
10769
|
+
end
|
10770
|
+
|
10771
|
+
# @param body [ListSharedItems]
|
10772
|
+
# @param [Hash] opts the optional parameters
|
10773
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
10774
|
+
def list_shared_items_with_http_info(body, opts = {})
|
10775
|
+
if @api_client.config.debugging
|
10776
|
+
@api_client.config.logger.debug 'Calling API: V2Api.list_shared_items ...'
|
10777
|
+
end
|
10778
|
+
# verify the required parameter 'body' is set
|
10779
|
+
if @api_client.config.client_side_validation && body.nil?
|
10780
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling V2Api.list_shared_items"
|
10781
|
+
end
|
10782
|
+
# resource path
|
10783
|
+
local_var_path = '/list-shared-items'
|
10784
|
+
|
10785
|
+
# query parameters
|
10786
|
+
query_params = opts[:query_params] || {}
|
10787
|
+
|
10788
|
+
# header parameters
|
10789
|
+
header_params = opts[:header_params] || {}
|
10790
|
+
# HTTP header 'Accept' (if needed)
|
10791
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
10792
|
+
# HTTP header 'Content-Type'
|
10793
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
10794
|
+
if !content_type.nil?
|
10795
|
+
header_params['Content-Type'] = content_type
|
10796
|
+
end
|
10797
|
+
|
10798
|
+
# form parameters
|
10799
|
+
form_params = opts[:form_params] || {}
|
10800
|
+
|
10801
|
+
# http body (model)
|
10802
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(body)
|
10803
|
+
|
10804
|
+
# return_type
|
10805
|
+
return_type = opts[:debug_return_type]
|
10806
|
+
|
10807
|
+
# auth_names
|
10808
|
+
auth_names = opts[:debug_auth_names] || []
|
10809
|
+
|
10810
|
+
new_options = opts.merge(
|
10811
|
+
:operation => :"V2Api.list_shared_items",
|
10812
|
+
:header_params => header_params,
|
10813
|
+
:query_params => query_params,
|
10814
|
+
:form_params => form_params,
|
10815
|
+
:body => post_body,
|
10816
|
+
:auth_names => auth_names,
|
10817
|
+
:return_type => return_type
|
10818
|
+
)
|
10819
|
+
|
10820
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
10821
|
+
if @api_client.config.debugging
|
10822
|
+
@api_client.config.logger.debug "API called: V2Api#list_shared_items\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
10823
|
+
end
|
10824
|
+
return data, status_code, headers
|
10825
|
+
end
|
10826
|
+
|
10635
10827
|
# @param body [ListSRABastions]
|
10636
10828
|
# @param [Hash] opts the optional parameters
|
10637
10829
|
# @return [BastionsList]
|
@@ -10948,6 +11140,70 @@ module Akeyless
|
|
10948
11140
|
return data, status_code, headers
|
10949
11141
|
end
|
10950
11142
|
|
11143
|
+
# @param body [RequestAccess]
|
11144
|
+
# @param [Hash] opts the optional parameters
|
11145
|
+
# @return [RequestAccessOutput]
|
11146
|
+
def request_access(body, opts = {})
|
11147
|
+
data, _status_code, _headers = request_access_with_http_info(body, opts)
|
11148
|
+
data
|
11149
|
+
end
|
11150
|
+
|
11151
|
+
# @param body [RequestAccess]
|
11152
|
+
# @param [Hash] opts the optional parameters
|
11153
|
+
# @return [Array<(RequestAccessOutput, Integer, Hash)>] RequestAccessOutput data, response status code and response headers
|
11154
|
+
def request_access_with_http_info(body, opts = {})
|
11155
|
+
if @api_client.config.debugging
|
11156
|
+
@api_client.config.logger.debug 'Calling API: V2Api.request_access ...'
|
11157
|
+
end
|
11158
|
+
# verify the required parameter 'body' is set
|
11159
|
+
if @api_client.config.client_side_validation && body.nil?
|
11160
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling V2Api.request_access"
|
11161
|
+
end
|
11162
|
+
# resource path
|
11163
|
+
local_var_path = '/request-access'
|
11164
|
+
|
11165
|
+
# query parameters
|
11166
|
+
query_params = opts[:query_params] || {}
|
11167
|
+
|
11168
|
+
# header parameters
|
11169
|
+
header_params = opts[:header_params] || {}
|
11170
|
+
# HTTP header 'Accept' (if needed)
|
11171
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
11172
|
+
# HTTP header 'Content-Type'
|
11173
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
11174
|
+
if !content_type.nil?
|
11175
|
+
header_params['Content-Type'] = content_type
|
11176
|
+
end
|
11177
|
+
|
11178
|
+
# form parameters
|
11179
|
+
form_params = opts[:form_params] || {}
|
11180
|
+
|
11181
|
+
# http body (model)
|
11182
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(body)
|
11183
|
+
|
11184
|
+
# return_type
|
11185
|
+
return_type = opts[:debug_return_type] || 'RequestAccessOutput'
|
11186
|
+
|
11187
|
+
# auth_names
|
11188
|
+
auth_names = opts[:debug_auth_names] || []
|
11189
|
+
|
11190
|
+
new_options = opts.merge(
|
11191
|
+
:operation => :"V2Api.request_access",
|
11192
|
+
:header_params => header_params,
|
11193
|
+
:query_params => query_params,
|
11194
|
+
:form_params => form_params,
|
11195
|
+
:body => post_body,
|
11196
|
+
:auth_names => auth_names,
|
11197
|
+
:return_type => return_type
|
11198
|
+
)
|
11199
|
+
|
11200
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
11201
|
+
if @api_client.config.debugging
|
11202
|
+
@api_client.config.logger.debug "API called: V2Api#request_access\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
11203
|
+
end
|
11204
|
+
return data, status_code, headers
|
11205
|
+
end
|
11206
|
+
|
10951
11207
|
# @param body [ReverseRBAC]
|
10952
11208
|
# @param [Hash] opts the optional parameters
|
10953
11209
|
# @return [ReverseRBACOutput]
|
@@ -13433,6 +13689,70 @@ module Akeyless
|
|
13433
13689
|
return data, status_code, headers
|
13434
13690
|
end
|
13435
13691
|
|
13692
|
+
# @param body [UpdateEventForwarder]
|
13693
|
+
# @param [Hash] opts the optional parameters
|
13694
|
+
# @return [Object]
|
13695
|
+
def update_event_forwarder(body, opts = {})
|
13696
|
+
data, _status_code, _headers = update_event_forwarder_with_http_info(body, opts)
|
13697
|
+
data
|
13698
|
+
end
|
13699
|
+
|
13700
|
+
# @param body [UpdateEventForwarder]
|
13701
|
+
# @param [Hash] opts the optional parameters
|
13702
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
13703
|
+
def update_event_forwarder_with_http_info(body, opts = {})
|
13704
|
+
if @api_client.config.debugging
|
13705
|
+
@api_client.config.logger.debug 'Calling API: V2Api.update_event_forwarder ...'
|
13706
|
+
end
|
13707
|
+
# verify the required parameter 'body' is set
|
13708
|
+
if @api_client.config.client_side_validation && body.nil?
|
13709
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling V2Api.update_event_forwarder"
|
13710
|
+
end
|
13711
|
+
# resource path
|
13712
|
+
local_var_path = '/update-event-forwarder'
|
13713
|
+
|
13714
|
+
# query parameters
|
13715
|
+
query_params = opts[:query_params] || {}
|
13716
|
+
|
13717
|
+
# header parameters
|
13718
|
+
header_params = opts[:header_params] || {}
|
13719
|
+
# HTTP header 'Accept' (if needed)
|
13720
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
13721
|
+
# HTTP header 'Content-Type'
|
13722
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
13723
|
+
if !content_type.nil?
|
13724
|
+
header_params['Content-Type'] = content_type
|
13725
|
+
end
|
13726
|
+
|
13727
|
+
# form parameters
|
13728
|
+
form_params = opts[:form_params] || {}
|
13729
|
+
|
13730
|
+
# http body (model)
|
13731
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(body)
|
13732
|
+
|
13733
|
+
# return_type
|
13734
|
+
return_type = opts[:debug_return_type] || 'Object'
|
13735
|
+
|
13736
|
+
# auth_names
|
13737
|
+
auth_names = opts[:debug_auth_names] || []
|
13738
|
+
|
13739
|
+
new_options = opts.merge(
|
13740
|
+
:operation => :"V2Api.update_event_forwarder",
|
13741
|
+
:header_params => header_params,
|
13742
|
+
:query_params => query_params,
|
13743
|
+
:form_params => form_params,
|
13744
|
+
:body => post_body,
|
13745
|
+
:auth_names => auth_names,
|
13746
|
+
:return_type => return_type
|
13747
|
+
)
|
13748
|
+
|
13749
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
13750
|
+
if @api_client.config.debugging
|
13751
|
+
@api_client.config.logger.debug "API called: V2Api#update_event_forwarder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
13752
|
+
end
|
13753
|
+
return data, status_code, headers
|
13754
|
+
end
|
13755
|
+
|
13436
13756
|
# @param body [UpdateGcpTarget]
|
13437
13757
|
# @param [Hash] opts the optional parameters
|
13438
13758
|
# @return [UpdateGcpTargetOutput]
|
data/lib/akeyless/api_error.rb
CHANGED
@@ -62,6 +62,11 @@ module Akeyless
|
|
62
62
|
# Defines the access token (Bearer) used with OAuth2.
|
63
63
|
attr_accessor :access_token
|
64
64
|
|
65
|
+
# Defines a Proc used to fetch or refresh access tokens (Bearer) used with OAuth2.
|
66
|
+
# Overrides the access_token if set
|
67
|
+
# @return [Proc]
|
68
|
+
attr_accessor :access_token_getter
|
69
|
+
|
65
70
|
# Set this to enable/disable debugging. When enabled (set to true), HTTP request/response
|
66
71
|
# details will be logged with `logger.debug` (see the `logger` attribute).
|
67
72
|
# Default to false.
|
@@ -208,6 +213,12 @@ module Akeyless
|
|
208
213
|
end
|
209
214
|
end
|
210
215
|
|
216
|
+
# Gets access_token using access_token_getter or uses the static access_token
|
217
|
+
def access_token_with_refresh
|
218
|
+
return access_token if access_token_getter.nil?
|
219
|
+
access_token_getter.call
|
220
|
+
end
|
221
|
+
|
211
222
|
# Gets Basic Auth token string
|
212
223
|
def basic_auth_token
|
213
224
|
'Basic ' + ["#{username}:#{password}"].pack('m').delete("\r\n")
|