ory-kratos-client 0.2.0.alpha2 → 0.5.1.alpha1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -1
- data/README.md +84 -52
- data/docs/AdminApi.md +244 -86
- data/docs/CommonApi.md +54 -6
- data/docs/CompleteSelfServiceLoginFlowWithPasswordMethod.md +21 -0
- data/docs/CompleteSelfServiceRecoveryFlowWithLinkMethod.md +19 -0
- data/docs/CompleteSelfServiceSettingsFlowWithPasswordMethod.md +19 -0
- data/docs/CompleteSelfServiceVerificationFlowWithLinkMethod.md +19 -0
- data/docs/CreateIdentity.md +19 -0
- data/docs/CreateRecoveryLink.md +19 -0
- data/docs/ErrorContainer.md +2 -2
- data/docs/Form.md +2 -2
- data/docs/FormField.md +4 -4
- data/docs/GenericErrorPayload.md +1 -1
- data/docs/Identity.md +9 -7
- data/docs/LoginFlow.md +33 -0
- data/docs/LoginFlowMethod.md +19 -0
- data/docs/LoginFlowMethodConfig.md +25 -0
- data/docs/LoginRequest.md +2 -0
- data/docs/LoginRequestMethodConfig.md +2 -2
- data/docs/LoginViaApiResponse.md +19 -0
- data/docs/Message.md +23 -0
- data/docs/ProviderCredentialsConfig.md +19 -0
- data/docs/PublicApi.md +726 -151
- data/docs/RecoveryAddress.md +21 -0
- data/docs/RecoveryFlow.md +33 -0
- data/docs/RecoveryFlowMethod.md +19 -0
- data/docs/RecoveryFlowMethodConfig.md +23 -0
- data/docs/RecoveryLink.md +19 -0
- data/docs/RecoveryRequest.md +31 -0
- data/docs/RecoveryRequestMethod.md +19 -0
- data/docs/RegistrationFlow.md +31 -0
- data/docs/RegistrationFlowMethod.md +19 -0
- data/docs/RegistrationFlowMethodConfig.md +25 -0
- data/docs/RegistrationRequest.md +3 -1
- data/docs/RegistrationRequestMethodConfig.md +2 -2
- data/docs/RegistrationViaApiResponse.md +21 -0
- data/docs/RequestMethodConfig.md +2 -2
- data/docs/RevokeSession.md +17 -0
- data/docs/Session.md +6 -4
- data/docs/SettingsFlow.md +35 -0
- data/docs/SettingsFlowMethod.md +19 -0
- data/docs/SettingsFlowMethodConfig.md +23 -0
- data/docs/SettingsRequest.md +4 -2
- data/docs/SettingsViaApiResponse.md +19 -0
- data/docs/UpdateIdentity.md +19 -0
- data/docs/VerifiableAddress.md +3 -3
- data/docs/VerificationFlow.md +33 -0
- data/docs/VerificationFlowMethod.md +19 -0
- data/docs/VerificationFlowMethodConfig.md +23 -0
- data/docs/VerificationRequest.md +2 -0
- data/lib/ory-kratos-client.rb +31 -16
- data/lib/ory-kratos-client/api/admin_api.rb +321 -130
- data/lib/ory-kratos-client/api/common_api.rb +75 -12
- data/lib/ory-kratos-client/api/health_api.rb +2 -2
- data/lib/ory-kratos-client/api/public_api.rb +896 -246
- data/lib/ory-kratos-client/api/version_api.rb +2 -2
- data/lib/ory-kratos-client/api_client.rb +10 -7
- data/lib/ory-kratos-client/api_error.rb +2 -2
- data/lib/ory-kratos-client/configuration.rb +9 -2
- data/lib/ory-kratos-client/models/complete_self_service_browser_settings_strategy_profile_flow_payload.rb +2 -2
- data/lib/ory-kratos-client/models/complete_self_service_login_flow_with_password_method.rb +227 -0
- data/lib/ory-kratos-client/models/complete_self_service_recovery_flow_with_link_method.rb +217 -0
- data/lib/ory-kratos-client/models/complete_self_service_settings_flow_with_password_method.rb +222 -0
- data/lib/ory-kratos-client/models/complete_self_service_verification_flow_with_link_method.rb +217 -0
- data/lib/ory-kratos-client/models/create_identity.rb +227 -0
- data/lib/ory-kratos-client/models/create_recovery_link.rb +238 -0
- data/lib/ory-kratos-client/models/error_container.rb +13 -2
- data/lib/ory-kratos-client/models/form.rb +14 -15
- data/lib/ory-kratos-client/models/form_field.rb +11 -17
- data/lib/ory-kratos-client/models/generic_error.rb +2 -2
- data/lib/ory-kratos-client/models/generic_error_payload.rb +4 -6
- data/lib/ory-kratos-client/models/health_not_ready_status.rb +2 -2
- data/lib/ory-kratos-client/models/health_status.rb +2 -2
- data/lib/ory-kratos-client/models/identity.rb +53 -35
- data/lib/ory-kratos-client/models/login_flow.rb +315 -0
- data/lib/ory-kratos-client/models/login_flow_method.rb +226 -0
- data/lib/ory-kratos-client/models/login_flow_method_config.rb +267 -0
- data/lib/ory-kratos-client/models/login_request.rb +14 -3
- data/lib/ory-kratos-client/models/login_request_method.rb +2 -2
- data/lib/ory-kratos-client/models/login_request_method_config.rb +14 -15
- data/lib/ory-kratos-client/models/login_via_api_response.rb +227 -0
- data/lib/ory-kratos-client/models/message.rb +234 -0
- data/lib/ory-kratos-client/models/provider_credentials_config.rb +215 -0
- data/lib/ory-kratos-client/models/recovery_address.rb +239 -0
- data/lib/ory-kratos-client/models/recovery_flow.rb +319 -0
- data/lib/ory-kratos-client/models/recovery_flow_method.rb +226 -0
- data/lib/ory-kratos-client/models/recovery_flow_method_config.rb +255 -0
- data/lib/ory-kratos-client/models/recovery_link.rb +222 -0
- data/lib/ory-kratos-client/models/recovery_request.rb +309 -0
- data/lib/ory-kratos-client/models/recovery_request_method.rb +216 -0
- data/lib/ory-kratos-client/models/registration_flow.rb +304 -0
- data/lib/ory-kratos-client/models/registration_flow_method.rb +226 -0
- data/lib/ory-kratos-client/models/registration_flow_method_config.rb +267 -0
- data/lib/ory-kratos-client/models/registration_request.rb +14 -8
- data/lib/ory-kratos-client/models/registration_request_method.rb +2 -2
- data/lib/ory-kratos-client/models/registration_request_method_config.rb +14 -15
- data/lib/ory-kratos-client/models/registration_via_api_response.rb +236 -0
- data/lib/ory-kratos-client/models/request_method_config.rb +14 -15
- data/lib/ory-kratos-client/models/revoke_session.rb +212 -0
- data/lib/ory-kratos-client/models/session.rb +29 -20
- data/lib/ory-kratos-client/models/settings_flow.rb +333 -0
- data/lib/ory-kratos-client/models/settings_flow_method.rb +226 -0
- data/lib/ory-kratos-client/models/settings_flow_method_config.rb +255 -0
- data/lib/ory-kratos-client/models/settings_request.rb +24 -14
- data/lib/ory-kratos-client/models/settings_request_method.rb +2 -2
- data/lib/ory-kratos-client/models/settings_via_api_response.rb +226 -0
- data/lib/ory-kratos-client/models/update_identity.rb +222 -0
- data/lib/ory-kratos-client/models/verifiable_address.rb +17 -17
- data/lib/ory-kratos-client/models/verification_flow.rb +299 -0
- data/lib/ory-kratos-client/models/verification_flow_method.rb +226 -0
- data/lib/ory-kratos-client/models/verification_flow_method_config.rb +255 -0
- data/lib/ory-kratos-client/models/verification_request.rb +14 -3
- data/lib/ory-kratos-client/models/version.rb +2 -2
- data/lib/ory-kratos-client/version.rb +3 -3
- data/ory-kratos-client.gemspec +2 -2
- data/spec/models/complete_self_service_login_flow_with_password_method_spec.rb +53 -0
- data/spec/models/complete_self_service_recovery_flow_with_link_method_spec.rb +47 -0
- data/spec/models/complete_self_service_settings_flow_with_password_method_spec.rb +47 -0
- data/spec/models/complete_self_service_verification_flow_with_link_method_spec.rb +47 -0
- data/spec/models/create_identity_spec.rb +47 -0
- data/spec/models/create_recovery_link_spec.rb +47 -0
- data/spec/models/login_flow_method_config_spec.rb +65 -0
- data/spec/models/login_flow_method_spec.rb +47 -0
- data/spec/models/login_flow_spec.rb +89 -0
- data/spec/models/login_via_api_response_spec.rb +47 -0
- data/spec/models/message_spec.rb +59 -0
- data/spec/models/provider_credentials_config_spec.rb +47 -0
- data/spec/models/recovery_address_spec.rb +53 -0
- data/spec/models/recovery_flow_method_config_spec.rb +59 -0
- data/spec/models/recovery_flow_method_spec.rb +47 -0
- data/spec/models/recovery_flow_spec.rb +89 -0
- data/spec/models/recovery_link_spec.rb +47 -0
- data/spec/models/recovery_request_method_spec.rb +47 -0
- data/spec/models/recovery_request_spec.rb +83 -0
- data/spec/models/registration_flow_method_config_spec.rb +65 -0
- data/spec/models/registration_flow_method_spec.rb +47 -0
- data/spec/models/registration_flow_spec.rb +83 -0
- data/spec/models/registration_via_api_response_spec.rb +53 -0
- data/spec/models/revoke_session_spec.rb +41 -0
- data/spec/models/settings_flow_method_config_spec.rb +59 -0
- data/spec/models/settings_flow_method_spec.rb +47 -0
- data/spec/models/settings_flow_spec.rb +95 -0
- data/spec/models/settings_via_api_response_spec.rb +47 -0
- data/spec/models/update_identity_spec.rb +47 -0
- data/spec/models/verification_flow_method_config_spec.rb +59 -0
- data/spec/models/verification_flow_method_spec.rb +47 -0
- data/spec/models/verification_flow_spec.rb +89 -0
- metadata +152 -24
@@ -3,10 +3,10 @@
|
|
3
3
|
|
4
4
|
#Welcome to the ORY Kratos HTTP API documentation!
|
5
5
|
|
6
|
-
The version of the OpenAPI document:
|
6
|
+
The version of the OpenAPI document: v0.4.6-alpha.1
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 4.
|
9
|
+
OpenAPI Generator version: 4.3.1
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -80,7 +80,7 @@ module OryHydraClient
|
|
80
80
|
end
|
81
81
|
|
82
82
|
# Get the request context of browser-based login user flows
|
83
|
-
# This endpoint returns a login request's context with, for example, error details and other information. When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for CSRF to work. To prevent token scanning attacks, the public endpoint does not return 404 status codes
|
83
|
+
# This endpoint returns a login request's context with, for example, error details and other information. When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for CSRF to work. To prevent token scanning attacks, the public endpoint does not return 404 status codes. More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
84
84
|
# @param request [String] Request is the Login Request ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/login?request=abcde`).
|
85
85
|
# @param [Hash] opts the optional parameters
|
86
86
|
# @return [LoginRequest]
|
@@ -90,7 +90,7 @@ module OryHydraClient
|
|
90
90
|
end
|
91
91
|
|
92
92
|
# Get the request context of browser-based login user flows
|
93
|
-
# This endpoint returns a login request's context with, for example, error details and other information. When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for CSRF to work. To prevent token scanning attacks, the public endpoint does not return 404 status codes
|
93
|
+
# This endpoint returns a login request's context with, for example, error details and other information. When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for CSRF to work. To prevent token scanning attacks, the public endpoint does not return 404 status codes. More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
94
94
|
# @param request [String] Request is the Login Request ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/login?request=abcde`).
|
95
95
|
# @param [Hash] opts the optional parameters
|
96
96
|
# @return [Array<(LoginRequest, Integer, Hash)>] LoginRequest data, response status code and response headers
|
@@ -142,8 +142,71 @@ module OryHydraClient
|
|
142
142
|
return data, status_code, headers
|
143
143
|
end
|
144
144
|
|
145
|
+
# Get the request context of browser-based recovery flows
|
146
|
+
# When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for checking the auth session. To prevent scanning attacks, the public endpoint does not return 404 status codes but instead 403 or 500. More information can be found at [ORY Kratos Account Recovery Documentation](../self-service/flows/password-reset-account-recovery).
|
147
|
+
# @param request [String] Request is the Login Request ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/recover?request=abcde`).
|
148
|
+
# @param [Hash] opts the optional parameters
|
149
|
+
# @return [RecoveryRequest]
|
150
|
+
def get_self_service_browser_recovery_request(request, opts = {})
|
151
|
+
data, _status_code, _headers = get_self_service_browser_recovery_request_with_http_info(request, opts)
|
152
|
+
data
|
153
|
+
end
|
154
|
+
|
155
|
+
# Get the request context of browser-based recovery flows
|
156
|
+
# When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for checking the auth session. To prevent scanning attacks, the public endpoint does not return 404 status codes but instead 403 or 500. More information can be found at [ORY Kratos Account Recovery Documentation](../self-service/flows/password-reset-account-recovery).
|
157
|
+
# @param request [String] Request is the Login Request ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/recover?request=abcde`).
|
158
|
+
# @param [Hash] opts the optional parameters
|
159
|
+
# @return [Array<(RecoveryRequest, Integer, Hash)>] RecoveryRequest data, response status code and response headers
|
160
|
+
def get_self_service_browser_recovery_request_with_http_info(request, opts = {})
|
161
|
+
if @api_client.config.debugging
|
162
|
+
@api_client.config.logger.debug 'Calling API: CommonApi.get_self_service_browser_recovery_request ...'
|
163
|
+
end
|
164
|
+
# verify the required parameter 'request' is set
|
165
|
+
if @api_client.config.client_side_validation && request.nil?
|
166
|
+
fail ArgumentError, "Missing the required parameter 'request' when calling CommonApi.get_self_service_browser_recovery_request"
|
167
|
+
end
|
168
|
+
# resource path
|
169
|
+
local_var_path = '/self-service/browser/flows/requests/recovery'
|
170
|
+
|
171
|
+
# query parameters
|
172
|
+
query_params = opts[:query_params] || {}
|
173
|
+
query_params[:'request'] = request
|
174
|
+
|
175
|
+
# header parameters
|
176
|
+
header_params = opts[:header_params] || {}
|
177
|
+
# HTTP header 'Accept' (if needed)
|
178
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
179
|
+
|
180
|
+
# form parameters
|
181
|
+
form_params = opts[:form_params] || {}
|
182
|
+
|
183
|
+
# http body (model)
|
184
|
+
post_body = opts[:body]
|
185
|
+
|
186
|
+
# return_type
|
187
|
+
return_type = opts[:return_type] || 'RecoveryRequest'
|
188
|
+
|
189
|
+
# auth_names
|
190
|
+
auth_names = opts[:auth_names] || []
|
191
|
+
|
192
|
+
new_options = opts.merge(
|
193
|
+
:header_params => header_params,
|
194
|
+
:query_params => query_params,
|
195
|
+
:form_params => form_params,
|
196
|
+
:body => post_body,
|
197
|
+
:auth_names => auth_names,
|
198
|
+
:return_type => return_type
|
199
|
+
)
|
200
|
+
|
201
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
202
|
+
if @api_client.config.debugging
|
203
|
+
@api_client.config.logger.debug "API called: CommonApi#get_self_service_browser_recovery_request\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
204
|
+
end
|
205
|
+
return data, status_code, headers
|
206
|
+
end
|
207
|
+
|
145
208
|
# Get the request context of browser-based registration user flows
|
146
|
-
# This endpoint returns a registration request's context with, for example, error details and other information. When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for CSRF to work. To prevent token scanning attacks, the public endpoint does not return 404 status codes
|
209
|
+
# This endpoint returns a registration request's context with, for example, error details and other information. When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for CSRF to work. To prevent token scanning attacks, the public endpoint does not return 404 status codes. More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
147
210
|
# @param request [String] Request is the Registration Request ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/registration?request=abcde`).
|
148
211
|
# @param [Hash] opts the optional parameters
|
149
212
|
# @return [RegistrationRequest]
|
@@ -153,7 +216,7 @@ module OryHydraClient
|
|
153
216
|
end
|
154
217
|
|
155
218
|
# Get the request context of browser-based registration user flows
|
156
|
-
# This endpoint returns a registration request's context with, for example, error details and other information. When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for CSRF to work. To prevent token scanning attacks, the public endpoint does not return 404 status codes
|
219
|
+
# This endpoint returns a registration request's context with, for example, error details and other information. When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for CSRF to work. To prevent token scanning attacks, the public endpoint does not return 404 status codes. More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
157
220
|
# @param request [String] Request is the Registration Request ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/registration?request=abcde`).
|
158
221
|
# @param [Hash] opts the optional parameters
|
159
222
|
# @return [Array<(RegistrationRequest, Integer, Hash)>] RegistrationRequest data, response status code and response headers
|
@@ -206,8 +269,8 @@ module OryHydraClient
|
|
206
269
|
end
|
207
270
|
|
208
271
|
# Get the request context of browser-based settings flows
|
209
|
-
# When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for checking the auth session. To prevent scanning attacks, the public endpoint does not return 404 status codes but instead 403 or 500. More information can be found at [ORY Kratos User Settings & Profile Management Documentation](
|
210
|
-
# @param request [String] Request is the Login Request ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/
|
272
|
+
# When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for checking the auth session. To prevent scanning attacks, the public endpoint does not return 404 status codes but instead 403 or 500. More information can be found at [ORY Kratos User Settings & Profile Management Documentation](../self-service/flows/user-settings).
|
273
|
+
# @param request [String] Request is the Login Request ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/settingss?request=abcde`).
|
211
274
|
# @param [Hash] opts the optional parameters
|
212
275
|
# @return [SettingsRequest]
|
213
276
|
def get_self_service_browser_settings_request(request, opts = {})
|
@@ -216,8 +279,8 @@ module OryHydraClient
|
|
216
279
|
end
|
217
280
|
|
218
281
|
# Get the request context of browser-based settings flows
|
219
|
-
# When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for checking the auth session. To prevent scanning attacks, the public endpoint does not return 404 status codes but instead 403 or 500. More information can be found at [ORY Kratos User Settings & Profile Management Documentation](
|
220
|
-
# @param request [String] Request is the Login Request ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/
|
282
|
+
# When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for checking the auth session. To prevent scanning attacks, the public endpoint does not return 404 status codes but instead 403 or 500. More information can be found at [ORY Kratos User Settings & Profile Management Documentation](../self-service/flows/user-settings).
|
283
|
+
# @param request [String] Request is the Login Request ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/settingss?request=abcde`).
|
221
284
|
# @param [Hash] opts the optional parameters
|
222
285
|
# @return [Array<(SettingsRequest, Integer, Hash)>] SettingsRequest data, response status code and response headers
|
223
286
|
def get_self_service_browser_settings_request_with_http_info(request, opts = {})
|
@@ -269,7 +332,7 @@ module OryHydraClient
|
|
269
332
|
end
|
270
333
|
|
271
334
|
# Get user-facing self-service errors
|
272
|
-
# This endpoint returns the error associated with a user-facing self service errors. When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for CSRF to work. To prevent token scanning attacks, the public endpoint does not return 404 status codes
|
335
|
+
# This endpoint returns the error associated with a user-facing self service errors. When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for CSRF to work. To prevent token scanning attacks, the public endpoint does not return 404 status codes. More information can be found at [ORY Kratos User User Facing Error Documentation](https://www.ory.sh/docs/kratos/self-service/flows/user-facing-errors).
|
273
336
|
# @param [Hash] opts the optional parameters
|
274
337
|
# @option opts [String] :error
|
275
338
|
# @return [ErrorContainer]
|
@@ -279,7 +342,7 @@ module OryHydraClient
|
|
279
342
|
end
|
280
343
|
|
281
344
|
# Get user-facing self-service errors
|
282
|
-
# This endpoint returns the error associated with a user-facing self service errors. When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for CSRF to work. To prevent token scanning attacks, the public endpoint does not return 404 status codes
|
345
|
+
# This endpoint returns the error associated with a user-facing self service errors. When accessing this endpoint through ORY Kratos' Public API, ensure that cookies are set as they are required for CSRF to work. To prevent token scanning attacks, the public endpoint does not return 404 status codes. More information can be found at [ORY Kratos User User Facing Error Documentation](https://www.ory.sh/docs/kratos/self-service/flows/user-facing-errors).
|
283
346
|
# @param [Hash] opts the optional parameters
|
284
347
|
# @option opts [String] :error
|
285
348
|
# @return [Array<(ErrorContainer, Integer, Hash)>] ErrorContainer data, response status code and response headers
|
@@ -3,10 +3,10 @@
|
|
3
3
|
|
4
4
|
#Welcome to the ORY Kratos HTTP API documentation!
|
5
5
|
|
6
|
-
The version of the OpenAPI document:
|
6
|
+
The version of the OpenAPI document: v0.5.1-alpha.1
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 4.
|
9
|
+
OpenAPI Generator version: 4.3.1
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -3,10 +3,10 @@
|
|
3
3
|
|
4
4
|
#Welcome to the ORY Kratos HTTP API documentation!
|
5
5
|
|
6
|
-
The version of the OpenAPI document:
|
6
|
+
The version of the OpenAPI document: v0.5.1-alpha.1
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 4.
|
9
|
+
OpenAPI Generator version: 4.3.1
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -19,25 +19,25 @@ module OryHydraClient
|
|
19
19
|
def initialize(api_client = ApiClient.default)
|
20
20
|
@api_client = api_client
|
21
21
|
end
|
22
|
-
# Complete the
|
23
|
-
# This endpoint completes a browser-based settings flow. This is usually achieved by POSTing data to this endpoint. > This endpoint is NOT INTENDED for API clients and only works with browsers (Chrome, Firefox, ...) and HTML Forms. More information can be found at [ORY Kratos User Settings & Profile Management Documentation](
|
22
|
+
# Complete the Browser-Based Settings Flow for the OpenID Connect Strategy
|
23
|
+
# This endpoint completes a browser-based settings flow. This is usually achieved by POSTing data to this endpoint. > This endpoint is NOT INTENDED for API clients and only works with browsers (Chrome, Firefox, ...) and HTML Forms. More information can be found at [ORY Kratos User Settings & Profile Management Documentation](../self-service/flows/user-settings).
|
24
24
|
# @param [Hash] opts the optional parameters
|
25
25
|
# @return [nil]
|
26
|
-
def
|
27
|
-
|
26
|
+
def complete_self_service_browser_settings_oidc_settings_flow(opts = {})
|
27
|
+
complete_self_service_browser_settings_oidc_settings_flow_with_http_info(opts)
|
28
28
|
nil
|
29
29
|
end
|
30
30
|
|
31
|
-
# Complete the
|
32
|
-
# This endpoint completes a browser-based settings flow. This is usually achieved by POSTing data to this endpoint. > This endpoint is NOT INTENDED for API clients and only works with browsers (Chrome, Firefox, ...) and HTML Forms. More information can be found at [ORY Kratos User Settings & Profile Management Documentation](
|
31
|
+
# Complete the Browser-Based Settings Flow for the OpenID Connect Strategy
|
32
|
+
# This endpoint completes a browser-based settings flow. This is usually achieved by POSTing data to this endpoint. > This endpoint is NOT INTENDED for API clients and only works with browsers (Chrome, Firefox, ...) and HTML Forms. More information can be found at [ORY Kratos User Settings & Profile Management Documentation](../self-service/flows/user-settings).
|
33
33
|
# @param [Hash] opts the optional parameters
|
34
34
|
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
35
|
-
def
|
35
|
+
def complete_self_service_browser_settings_oidc_settings_flow_with_http_info(opts = {})
|
36
36
|
if @api_client.config.debugging
|
37
|
-
@api_client.config.logger.debug 'Calling API: PublicApi.
|
37
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.complete_self_service_browser_settings_oidc_settings_flow ...'
|
38
38
|
end
|
39
39
|
# resource path
|
40
|
-
local_var_path = '/self-service/browser/flows/
|
40
|
+
local_var_path = '/self-service/browser/flows/registration/strategies/oidc/settings/connections'
|
41
41
|
|
42
42
|
# query parameters
|
43
43
|
query_params = opts[:query_params] || {}
|
@@ -70,46 +70,171 @@ module OryHydraClient
|
|
70
70
|
|
71
71
|
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
72
72
|
if @api_client.config.debugging
|
73
|
-
@api_client.config.logger.debug "API called: PublicApi#
|
73
|
+
@api_client.config.logger.debug "API called: PublicApi#complete_self_service_browser_settings_oidc_settings_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
74
74
|
end
|
75
75
|
return data, status_code, headers
|
76
76
|
end
|
77
77
|
|
78
|
-
# Complete
|
79
|
-
#
|
80
|
-
# @param
|
81
|
-
# @param body [CompleteSelfServiceBrowserSettingsStrategyProfileFlowPayload]
|
78
|
+
# Complete Login Flow with Username/Email Password Method
|
79
|
+
# Use this endpoint to complete a login flow by sending an identity's identifier and password. This endpoint behaves differently for API and browser flows. API flows expect `application/json` to be sent in the body and responds with HTTP 200 and a application/json body with the session token on success; HTTP 302 redirect to a fresh login flow if the original flow expired with the appropriate error messages set; HTTP 400 on form validation errors. Browser flows expect `application/x-www-form-urlencoded` to be sent in the body and responds with a HTTP 302 redirect to the post/after login URL or the `return_to` value if it was set and if the login succeeded; a HTTP 302 redirect to the login UI URL with the flow ID containing the validation errors otherwise. More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
80
|
+
# @param flow [String] The Flow ID
|
82
81
|
# @param [Hash] opts the optional parameters
|
82
|
+
# @option opts [CompleteSelfServiceLoginFlowWithPasswordMethod] :body
|
83
|
+
# @return [LoginViaApiResponse]
|
84
|
+
def complete_self_service_login_flow_with_password_method(flow, opts = {})
|
85
|
+
data, _status_code, _headers = complete_self_service_login_flow_with_password_method_with_http_info(flow, opts)
|
86
|
+
data
|
87
|
+
end
|
88
|
+
|
89
|
+
# Complete Login Flow with Username/Email Password Method
|
90
|
+
# Use this endpoint to complete a login flow by sending an identity's identifier and password. This endpoint behaves differently for API and browser flows. API flows expect `application/json` to be sent in the body and responds with HTTP 200 and a application/json body with the session token on success; HTTP 302 redirect to a fresh login flow if the original flow expired with the appropriate error messages set; HTTP 400 on form validation errors. Browser flows expect `application/x-www-form-urlencoded` to be sent in the body and responds with a HTTP 302 redirect to the post/after login URL or the `return_to` value if it was set and if the login succeeded; a HTTP 302 redirect to the login UI URL with the flow ID containing the validation errors otherwise. More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
91
|
+
# @param flow [String] The Flow ID
|
92
|
+
# @param [Hash] opts the optional parameters
|
93
|
+
# @option opts [CompleteSelfServiceLoginFlowWithPasswordMethod] :body
|
94
|
+
# @return [Array<(LoginViaApiResponse, Integer, Hash)>] LoginViaApiResponse data, response status code and response headers
|
95
|
+
def complete_self_service_login_flow_with_password_method_with_http_info(flow, opts = {})
|
96
|
+
if @api_client.config.debugging
|
97
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.complete_self_service_login_flow_with_password_method ...'
|
98
|
+
end
|
99
|
+
# verify the required parameter 'flow' is set
|
100
|
+
if @api_client.config.client_side_validation && flow.nil?
|
101
|
+
fail ArgumentError, "Missing the required parameter 'flow' when calling PublicApi.complete_self_service_login_flow_with_password_method"
|
102
|
+
end
|
103
|
+
# resource path
|
104
|
+
local_var_path = '/self-service/login/methods/password'
|
105
|
+
|
106
|
+
# query parameters
|
107
|
+
query_params = opts[:query_params] || {}
|
108
|
+
query_params[:'flow'] = flow
|
109
|
+
|
110
|
+
# header parameters
|
111
|
+
header_params = opts[:header_params] || {}
|
112
|
+
# HTTP header 'Accept' (if needed)
|
113
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
114
|
+
# HTTP header 'Content-Type'
|
115
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded'])
|
116
|
+
|
117
|
+
# form parameters
|
118
|
+
form_params = opts[:form_params] || {}
|
119
|
+
|
120
|
+
# http body (model)
|
121
|
+
post_body = opts[:body] || @api_client.object_to_http_body(opts[:'body'])
|
122
|
+
|
123
|
+
# return_type
|
124
|
+
return_type = opts[:return_type] || 'LoginViaApiResponse'
|
125
|
+
|
126
|
+
# auth_names
|
127
|
+
auth_names = opts[:auth_names] || []
|
128
|
+
|
129
|
+
new_options = opts.merge(
|
130
|
+
:header_params => header_params,
|
131
|
+
:query_params => query_params,
|
132
|
+
:form_params => form_params,
|
133
|
+
:body => post_body,
|
134
|
+
:auth_names => auth_names,
|
135
|
+
:return_type => return_type
|
136
|
+
)
|
137
|
+
|
138
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
139
|
+
if @api_client.config.debugging
|
140
|
+
@api_client.config.logger.debug "API called: PublicApi#complete_self_service_login_flow_with_password_method\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
141
|
+
end
|
142
|
+
return data, status_code, headers
|
143
|
+
end
|
144
|
+
|
145
|
+
# Complete Recovery Flow with Link Method
|
146
|
+
# Use this endpoint to complete a recovery flow using the link method. This endpoint behaves differently for API and browser flows and has several states: `choose_method` expects `flow` (in the URL query) and `email` (in the body) to be sent and works with API- and Browser-initiated flows. For API clients it either returns a HTTP 200 OK when the form is valid and HTTP 400 OK when the form is invalid and a HTTP 302 Found redirect with a fresh recovery flow if the flow was otherwise invalid (e.g. expired). For Browser clients it returns a HTTP 302 Found redirect to the Recovery UI URL with the Recovery Flow ID appended. `sent_email` is the success state after `choose_method` and allows the user to request another recovery email. It works for both API and Browser-initiated flows and returns the same responses as the flow in `choose_method` state. `passed_challenge` expects a `token` to be sent in the URL query and given the nature of the flow (\"sending a recovery link\") does not have any API capabilities. The server responds with a HTTP 302 Found redirect either to the Settings UI URL (if the link was valid) and instructs the user to update their password, or a redirect to the Recover UI URL with a new Recovery Flow ID which contains an error message that the recovery link was invalid. More information can be found at [ORY Kratos Account Recovery Documentation](../self-service/flows/account-recovery.mdx).
|
147
|
+
# @param [Hash] opts the optional parameters
|
148
|
+
# @option opts [String] :token Recovery Token The recovery token which completes the recovery request. If the token is invalid (e.g. expired) an error will be shown to the end-user.
|
149
|
+
# @option opts [String] :flow The Flow ID format: uuid
|
150
|
+
# @option opts [CompleteSelfServiceRecoveryFlowWithLinkMethod] :body
|
83
151
|
# @return [nil]
|
84
|
-
def
|
85
|
-
|
152
|
+
def complete_self_service_recovery_flow_with_link_method(opts = {})
|
153
|
+
complete_self_service_recovery_flow_with_link_method_with_http_info(opts)
|
86
154
|
nil
|
87
155
|
end
|
88
156
|
|
89
|
-
# Complete
|
90
|
-
#
|
91
|
-
# @param request [String] Request is the request ID.
|
92
|
-
# @param body [CompleteSelfServiceBrowserSettingsStrategyProfileFlowPayload]
|
157
|
+
# Complete Recovery Flow with Link Method
|
158
|
+
# Use this endpoint to complete a recovery flow using the link method. This endpoint behaves differently for API and browser flows and has several states: `choose_method` expects `flow` (in the URL query) and `email` (in the body) to be sent and works with API- and Browser-initiated flows. For API clients it either returns a HTTP 200 OK when the form is valid and HTTP 400 OK when the form is invalid and a HTTP 302 Found redirect with a fresh recovery flow if the flow was otherwise invalid (e.g. expired). For Browser clients it returns a HTTP 302 Found redirect to the Recovery UI URL with the Recovery Flow ID appended. `sent_email` is the success state after `choose_method` and allows the user to request another recovery email. It works for both API and Browser-initiated flows and returns the same responses as the flow in `choose_method` state. `passed_challenge` expects a `token` to be sent in the URL query and given the nature of the flow (\"sending a recovery link\") does not have any API capabilities. The server responds with a HTTP 302 Found redirect either to the Settings UI URL (if the link was valid) and instructs the user to update their password, or a redirect to the Recover UI URL with a new Recovery Flow ID which contains an error message that the recovery link was invalid. More information can be found at [ORY Kratos Account Recovery Documentation](../self-service/flows/account-recovery.mdx).
|
93
159
|
# @param [Hash] opts the optional parameters
|
160
|
+
# @option opts [String] :token Recovery Token The recovery token which completes the recovery request. If the token is invalid (e.g. expired) an error will be shown to the end-user.
|
161
|
+
# @option opts [String] :flow The Flow ID format: uuid
|
162
|
+
# @option opts [CompleteSelfServiceRecoveryFlowWithLinkMethod] :body
|
94
163
|
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
95
|
-
def
|
164
|
+
def complete_self_service_recovery_flow_with_link_method_with_http_info(opts = {})
|
96
165
|
if @api_client.config.debugging
|
97
|
-
@api_client.config.logger.debug 'Calling API: PublicApi.
|
166
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.complete_self_service_recovery_flow_with_link_method ...'
|
98
167
|
end
|
99
|
-
#
|
100
|
-
|
101
|
-
|
168
|
+
# resource path
|
169
|
+
local_var_path = '/self-service/recovery/methods/link'
|
170
|
+
|
171
|
+
# query parameters
|
172
|
+
query_params = opts[:query_params] || {}
|
173
|
+
query_params[:'token'] = opts[:'token'] if !opts[:'token'].nil?
|
174
|
+
query_params[:'flow'] = opts[:'flow'] if !opts[:'flow'].nil?
|
175
|
+
|
176
|
+
# header parameters
|
177
|
+
header_params = opts[:header_params] || {}
|
178
|
+
# HTTP header 'Accept' (if needed)
|
179
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
180
|
+
# HTTP header 'Content-Type'
|
181
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded'])
|
182
|
+
|
183
|
+
# form parameters
|
184
|
+
form_params = opts[:form_params] || {}
|
185
|
+
|
186
|
+
# http body (model)
|
187
|
+
post_body = opts[:body] || @api_client.object_to_http_body(opts[:'body'])
|
188
|
+
|
189
|
+
# return_type
|
190
|
+
return_type = opts[:return_type]
|
191
|
+
|
192
|
+
# auth_names
|
193
|
+
auth_names = opts[:auth_names] || []
|
194
|
+
|
195
|
+
new_options = opts.merge(
|
196
|
+
:header_params => header_params,
|
197
|
+
:query_params => query_params,
|
198
|
+
:form_params => form_params,
|
199
|
+
:body => post_body,
|
200
|
+
:auth_names => auth_names,
|
201
|
+
:return_type => return_type
|
202
|
+
)
|
203
|
+
|
204
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
205
|
+
if @api_client.config.debugging
|
206
|
+
@api_client.config.logger.debug "API called: PublicApi#complete_self_service_recovery_flow_with_link_method\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
102
207
|
end
|
103
|
-
|
104
|
-
|
105
|
-
|
208
|
+
return data, status_code, headers
|
209
|
+
end
|
210
|
+
|
211
|
+
# Complete Registration Flow with Username/Email Password Method
|
212
|
+
# Use this endpoint to complete a registration flow by sending an identity's traits and password. This endpoint behaves differently for API and browser flows. API flows expect `application/json` to be sent in the body and respond with HTTP 200 and a application/json body with the created identity success - if the session hook is configured the `session` and `session_token` will also be included; HTTP 302 redirect to a fresh registration flow if the original flow expired with the appropriate error messages set; HTTP 400 on form validation errors. Browser flows expect `application/x-www-form-urlencoded` to be sent in the body and responds with a HTTP 302 redirect to the post/after registration URL or the `return_to` value if it was set and if the registration succeeded; a HTTP 302 redirect to the registration UI URL with the flow ID containing the validation errors otherwise. More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
213
|
+
# @param [Hash] opts the optional parameters
|
214
|
+
# @option opts [String] :flow Flow is flow ID.
|
215
|
+
# @option opts [Object] :payload
|
216
|
+
# @return [RegistrationViaApiResponse]
|
217
|
+
def complete_self_service_registration_flow_with_password_method(opts = {})
|
218
|
+
data, _status_code, _headers = complete_self_service_registration_flow_with_password_method_with_http_info(opts)
|
219
|
+
data
|
220
|
+
end
|
221
|
+
|
222
|
+
# Complete Registration Flow with Username/Email Password Method
|
223
|
+
# Use this endpoint to complete a registration flow by sending an identity's traits and password. This endpoint behaves differently for API and browser flows. API flows expect `application/json` to be sent in the body and respond with HTTP 200 and a application/json body with the created identity success - if the session hook is configured the `session` and `session_token` will also be included; HTTP 302 redirect to a fresh registration flow if the original flow expired with the appropriate error messages set; HTTP 400 on form validation errors. Browser flows expect `application/x-www-form-urlencoded` to be sent in the body and responds with a HTTP 302 redirect to the post/after registration URL or the `return_to` value if it was set and if the registration succeeded; a HTTP 302 redirect to the registration UI URL with the flow ID containing the validation errors otherwise. More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
224
|
+
# @param [Hash] opts the optional parameters
|
225
|
+
# @option opts [String] :flow Flow is flow ID.
|
226
|
+
# @option opts [Object] :payload
|
227
|
+
# @return [Array<(RegistrationViaApiResponse, Integer, Hash)>] RegistrationViaApiResponse data, response status code and response headers
|
228
|
+
def complete_self_service_registration_flow_with_password_method_with_http_info(opts = {})
|
229
|
+
if @api_client.config.debugging
|
230
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.complete_self_service_registration_flow_with_password_method ...'
|
106
231
|
end
|
107
232
|
# resource path
|
108
|
-
local_var_path = '/self-service/
|
233
|
+
local_var_path = '/self-service/registration/methods/password'
|
109
234
|
|
110
235
|
# query parameters
|
111
236
|
query_params = opts[:query_params] || {}
|
112
|
-
query_params[:'
|
237
|
+
query_params[:'flow'] = opts[:'flow'] if !opts[:'flow'].nil?
|
113
238
|
|
114
239
|
# header parameters
|
115
240
|
header_params = opts[:header_params] || {}
|
@@ -122,10 +247,10 @@ module OryHydraClient
|
|
122
247
|
form_params = opts[:form_params] || {}
|
123
248
|
|
124
249
|
# http body (model)
|
125
|
-
post_body = opts[:body] || @api_client.object_to_http_body(
|
250
|
+
post_body = opts[:body] || @api_client.object_to_http_body(opts[:'payload'])
|
126
251
|
|
127
252
|
# return_type
|
128
|
-
return_type = opts[:return_type]
|
253
|
+
return_type = opts[:return_type] || 'RegistrationViaApiResponse'
|
129
254
|
|
130
255
|
# auth_names
|
131
256
|
auth_names = opts[:auth_names] || []
|
@@ -141,57 +266,180 @@ module OryHydraClient
|
|
141
266
|
|
142
267
|
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
143
268
|
if @api_client.config.debugging
|
144
|
-
@api_client.config.logger.debug "API called: PublicApi#
|
269
|
+
@api_client.config.logger.debug "API called: PublicApi#complete_self_service_registration_flow_with_password_method\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
270
|
+
end
|
271
|
+
return data, status_code, headers
|
272
|
+
end
|
273
|
+
|
274
|
+
# Complete Settings Flow with Username/Email Password Method
|
275
|
+
# Use this endpoint to complete a settings flow by sending an identity's updated password. This endpoint behaves differently for API and browser flows. API-initiated flows expect `application/json` to be sent in the body and respond with HTTP 200 and an application/json body with the session token on success; HTTP 302 redirect to a fresh settings flow if the original flow expired with the appropriate error messages set; HTTP 400 on form validation errors. HTTP 401 when the endpoint is called without a valid session token. HTTP 403 when `selfservice.flows.settings.privileged_session_max_age` was reached. Implies that the user needs to re-authenticate. Browser flows expect `application/x-www-form-urlencoded` to be sent in the body and responds with a HTTP 302 redirect to the post/after settings URL or the `return_to` value if it was set and if the flow succeeded; a HTTP 302 redirect to the Settings UI URL with the flow ID containing the validation errors otherwise. a HTTP 302 redirect to the login endpoint when `selfservice.flows.settings.privileged_session_max_age` was reached. More information can be found at [ORY Kratos User Settings & Profile Management Documentation](../self-service/flows/user-settings).
|
276
|
+
# @param [Hash] opts the optional parameters
|
277
|
+
# @option opts [String] :flow Flow is flow ID.
|
278
|
+
# @option opts [CompleteSelfServiceSettingsFlowWithPasswordMethod] :body
|
279
|
+
# @return [SettingsViaApiResponse]
|
280
|
+
def complete_self_service_settings_flow_with_password_method(opts = {})
|
281
|
+
data, _status_code, _headers = complete_self_service_settings_flow_with_password_method_with_http_info(opts)
|
282
|
+
data
|
283
|
+
end
|
284
|
+
|
285
|
+
# Complete Settings Flow with Username/Email Password Method
|
286
|
+
# Use this endpoint to complete a settings flow by sending an identity's updated password. This endpoint behaves differently for API and browser flows. API-initiated flows expect `application/json` to be sent in the body and respond with HTTP 200 and an application/json body with the session token on success; HTTP 302 redirect to a fresh settings flow if the original flow expired with the appropriate error messages set; HTTP 400 on form validation errors. HTTP 401 when the endpoint is called without a valid session token. HTTP 403 when `selfservice.flows.settings.privileged_session_max_age` was reached. Implies that the user needs to re-authenticate. Browser flows expect `application/x-www-form-urlencoded` to be sent in the body and responds with a HTTP 302 redirect to the post/after settings URL or the `return_to` value if it was set and if the flow succeeded; a HTTP 302 redirect to the Settings UI URL with the flow ID containing the validation errors otherwise. a HTTP 302 redirect to the login endpoint when `selfservice.flows.settings.privileged_session_max_age` was reached. More information can be found at [ORY Kratos User Settings & Profile Management Documentation](../self-service/flows/user-settings).
|
287
|
+
# @param [Hash] opts the optional parameters
|
288
|
+
# @option opts [String] :flow Flow is flow ID.
|
289
|
+
# @option opts [CompleteSelfServiceSettingsFlowWithPasswordMethod] :body
|
290
|
+
# @return [Array<(SettingsViaApiResponse, Integer, Hash)>] SettingsViaApiResponse data, response status code and response headers
|
291
|
+
def complete_self_service_settings_flow_with_password_method_with_http_info(opts = {})
|
292
|
+
if @api_client.config.debugging
|
293
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.complete_self_service_settings_flow_with_password_method ...'
|
294
|
+
end
|
295
|
+
# resource path
|
296
|
+
local_var_path = '/self-service/settings/methods/password'
|
297
|
+
|
298
|
+
# query parameters
|
299
|
+
query_params = opts[:query_params] || {}
|
300
|
+
query_params[:'flow'] = opts[:'flow'] if !opts[:'flow'].nil?
|
301
|
+
|
302
|
+
# header parameters
|
303
|
+
header_params = opts[:header_params] || {}
|
304
|
+
# HTTP header 'Accept' (if needed)
|
305
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
306
|
+
# HTTP header 'Content-Type'
|
307
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded'])
|
308
|
+
|
309
|
+
# form parameters
|
310
|
+
form_params = opts[:form_params] || {}
|
311
|
+
|
312
|
+
# http body (model)
|
313
|
+
post_body = opts[:body] || @api_client.object_to_http_body(opts[:'body'])
|
314
|
+
|
315
|
+
# return_type
|
316
|
+
return_type = opts[:return_type] || 'SettingsViaApiResponse'
|
317
|
+
|
318
|
+
# auth_names
|
319
|
+
auth_names = opts[:auth_names] || ['sessionToken']
|
320
|
+
|
321
|
+
new_options = opts.merge(
|
322
|
+
:header_params => header_params,
|
323
|
+
:query_params => query_params,
|
324
|
+
:form_params => form_params,
|
325
|
+
:body => post_body,
|
326
|
+
:auth_names => auth_names,
|
327
|
+
:return_type => return_type
|
328
|
+
)
|
329
|
+
|
330
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
331
|
+
if @api_client.config.debugging
|
332
|
+
@api_client.config.logger.debug "API called: PublicApi#complete_self_service_settings_flow_with_password_method\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
333
|
+
end
|
334
|
+
return data, status_code, headers
|
335
|
+
end
|
336
|
+
|
337
|
+
# Complete Settings Flow with Profile Method
|
338
|
+
# Use this endpoint to complete a settings flow by sending an identity's updated traits. This endpoint behaves differently for API and browser flows. API-initiated flows expect `application/json` to be sent in the body and respond with HTTP 200 and an application/json body with the session token on success; HTTP 302 redirect to a fresh settings flow if the original flow expired with the appropriate error messages set; HTTP 400 on form validation errors. HTTP 401 when the endpoint is called without a valid session token. HTTP 403 when `selfservice.flows.settings.privileged_session_max_age` was reached and a sensitive field was updated (e.g. recovery email). Implies that the user needs to re-authenticate. Browser flows expect `application/x-www-form-urlencoded` to be sent in the body and responds with a HTTP 302 redirect to the post/after settings URL or the `return_to` value if it was set and if the flow succeeded; a HTTP 302 redirect to the settings UI URL with the flow ID containing the validation errors otherwise. a HTTP 302 redirect to the login endpoint when `selfservice.flows.settings.privileged_session_max_age` was reached. More information can be found at [ORY Kratos User Settings & Profile Management Documentation](../self-service/flows/user-settings).
|
339
|
+
# @param [Hash] opts the optional parameters
|
340
|
+
# @option opts [String] :flow Flow is flow ID.
|
341
|
+
# @option opts [Object] :payload
|
342
|
+
# @return [SettingsFlow]
|
343
|
+
def complete_self_service_settings_flow_with_profile_method(opts = {})
|
344
|
+
data, _status_code, _headers = complete_self_service_settings_flow_with_profile_method_with_http_info(opts)
|
345
|
+
data
|
346
|
+
end
|
347
|
+
|
348
|
+
# Complete Settings Flow with Profile Method
|
349
|
+
# Use this endpoint to complete a settings flow by sending an identity's updated traits. This endpoint behaves differently for API and browser flows. API-initiated flows expect `application/json` to be sent in the body and respond with HTTP 200 and an application/json body with the session token on success; HTTP 302 redirect to a fresh settings flow if the original flow expired with the appropriate error messages set; HTTP 400 on form validation errors. HTTP 401 when the endpoint is called without a valid session token. HTTP 403 when `selfservice.flows.settings.privileged_session_max_age` was reached and a sensitive field was updated (e.g. recovery email). Implies that the user needs to re-authenticate. Browser flows expect `application/x-www-form-urlencoded` to be sent in the body and responds with a HTTP 302 redirect to the post/after settings URL or the `return_to` value if it was set and if the flow succeeded; a HTTP 302 redirect to the settings UI URL with the flow ID containing the validation errors otherwise. a HTTP 302 redirect to the login endpoint when `selfservice.flows.settings.privileged_session_max_age` was reached. More information can be found at [ORY Kratos User Settings & Profile Management Documentation](../self-service/flows/user-settings).
|
350
|
+
# @param [Hash] opts the optional parameters
|
351
|
+
# @option opts [String] :flow Flow is flow ID.
|
352
|
+
# @option opts [Object] :payload
|
353
|
+
# @return [Array<(SettingsFlow, Integer, Hash)>] SettingsFlow data, response status code and response headers
|
354
|
+
def complete_self_service_settings_flow_with_profile_method_with_http_info(opts = {})
|
355
|
+
if @api_client.config.debugging
|
356
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.complete_self_service_settings_flow_with_profile_method ...'
|
357
|
+
end
|
358
|
+
# resource path
|
359
|
+
local_var_path = '/self-service/settings/methods/profile'
|
360
|
+
|
361
|
+
# query parameters
|
362
|
+
query_params = opts[:query_params] || {}
|
363
|
+
query_params[:'flow'] = opts[:'flow'] if !opts[:'flow'].nil?
|
364
|
+
|
365
|
+
# header parameters
|
366
|
+
header_params = opts[:header_params] || {}
|
367
|
+
# HTTP header 'Accept' (if needed)
|
368
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
369
|
+
# HTTP header 'Content-Type'
|
370
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded'])
|
371
|
+
|
372
|
+
# form parameters
|
373
|
+
form_params = opts[:form_params] || {}
|
374
|
+
|
375
|
+
# http body (model)
|
376
|
+
post_body = opts[:body] || @api_client.object_to_http_body(opts[:'payload'])
|
377
|
+
|
378
|
+
# return_type
|
379
|
+
return_type = opts[:return_type] || 'SettingsFlow'
|
380
|
+
|
381
|
+
# auth_names
|
382
|
+
auth_names = opts[:auth_names] || ['sessionToken']
|
383
|
+
|
384
|
+
new_options = opts.merge(
|
385
|
+
:header_params => header_params,
|
386
|
+
:query_params => query_params,
|
387
|
+
:form_params => form_params,
|
388
|
+
:body => post_body,
|
389
|
+
:auth_names => auth_names,
|
390
|
+
:return_type => return_type
|
391
|
+
)
|
392
|
+
|
393
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
394
|
+
if @api_client.config.debugging
|
395
|
+
@api_client.config.logger.debug "API called: PublicApi#complete_self_service_settings_flow_with_profile_method\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
145
396
|
end
|
146
397
|
return data, status_code, headers
|
147
398
|
end
|
148
399
|
|
149
|
-
# Complete
|
150
|
-
#
|
151
|
-
# @param request [String] Request is the Request ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/verify?request=abcde`).
|
152
|
-
# @param via [String] What to verify Currently only \"email\" is supported.
|
400
|
+
# Complete Verification Flow with Link Method
|
401
|
+
# Use this endpoint to complete a verification flow using the link method. This endpoint behaves differently for API and browser flows and has several states: `choose_method` expects `flow` (in the URL query) and `email` (in the body) to be sent and works with API- and Browser-initiated flows. For API clients it either returns a HTTP 200 OK when the form is valid and HTTP 400 OK when the form is invalid and a HTTP 302 Found redirect with a fresh verification flow if the flow was otherwise invalid (e.g. expired). For Browser clients it returns a HTTP 302 Found redirect to the Verification UI URL with the Verification Flow ID appended. `sent_email` is the success state after `choose_method` and allows the user to request another verification email. It works for both API and Browser-initiated flows and returns the same responses as the flow in `choose_method` state. `passed_challenge` expects a `token` to be sent in the URL query and given the nature of the flow (\"sending a verification link\") does not have any API capabilities. The server responds with a HTTP 302 Found redirect either to the Settings UI URL (if the link was valid) and instructs the user to update their password, or a redirect to the Verification UI URL with a new Verification Flow ID which contains an error message that the verification link was invalid. More information can be found at [ORY Kratos Email and Phone Verification Documentation](https://www.ory.sh/docs/kratos/selfservice/flows/verify-email-account-activation).
|
153
402
|
# @param [Hash] opts the optional parameters
|
403
|
+
# @option opts [String] :token Verification Token The verification token which completes the verification request. If the token is invalid (e.g. expired) an error will be shown to the end-user.
|
404
|
+
# @option opts [String] :flow The Flow ID format: uuid
|
405
|
+
# @option opts [CompleteSelfServiceVerificationFlowWithLinkMethod] :body
|
154
406
|
# @return [nil]
|
155
|
-
def
|
156
|
-
|
407
|
+
def complete_self_service_verification_flow_with_link_method(opts = {})
|
408
|
+
complete_self_service_verification_flow_with_link_method_with_http_info(opts)
|
157
409
|
nil
|
158
410
|
end
|
159
411
|
|
160
|
-
# Complete
|
161
|
-
#
|
162
|
-
# @param request [String] Request is the Request ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/verify?request=abcde`).
|
163
|
-
# @param via [String] What to verify Currently only \"email\" is supported.
|
412
|
+
# Complete Verification Flow with Link Method
|
413
|
+
# Use this endpoint to complete a verification flow using the link method. This endpoint behaves differently for API and browser flows and has several states: `choose_method` expects `flow` (in the URL query) and `email` (in the body) to be sent and works with API- and Browser-initiated flows. For API clients it either returns a HTTP 200 OK when the form is valid and HTTP 400 OK when the form is invalid and a HTTP 302 Found redirect with a fresh verification flow if the flow was otherwise invalid (e.g. expired). For Browser clients it returns a HTTP 302 Found redirect to the Verification UI URL with the Verification Flow ID appended. `sent_email` is the success state after `choose_method` and allows the user to request another verification email. It works for both API and Browser-initiated flows and returns the same responses as the flow in `choose_method` state. `passed_challenge` expects a `token` to be sent in the URL query and given the nature of the flow (\"sending a verification link\") does not have any API capabilities. The server responds with a HTTP 302 Found redirect either to the Settings UI URL (if the link was valid) and instructs the user to update their password, or a redirect to the Verification UI URL with a new Verification Flow ID which contains an error message that the verification link was invalid. More information can be found at [ORY Kratos Email and Phone Verification Documentation](https://www.ory.sh/docs/kratos/selfservice/flows/verify-email-account-activation).
|
164
414
|
# @param [Hash] opts the optional parameters
|
415
|
+
# @option opts [String] :token Verification Token The verification token which completes the verification request. If the token is invalid (e.g. expired) an error will be shown to the end-user.
|
416
|
+
# @option opts [String] :flow The Flow ID format: uuid
|
417
|
+
# @option opts [CompleteSelfServiceVerificationFlowWithLinkMethod] :body
|
165
418
|
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
166
|
-
def
|
419
|
+
def complete_self_service_verification_flow_with_link_method_with_http_info(opts = {})
|
167
420
|
if @api_client.config.debugging
|
168
|
-
@api_client.config.logger.debug 'Calling API: PublicApi.
|
169
|
-
end
|
170
|
-
# verify the required parameter 'request' is set
|
171
|
-
if @api_client.config.client_side_validation && request.nil?
|
172
|
-
fail ArgumentError, "Missing the required parameter 'request' when calling PublicApi.complete_self_service_browser_verification_flow"
|
173
|
-
end
|
174
|
-
# verify the required parameter 'via' is set
|
175
|
-
if @api_client.config.client_side_validation && via.nil?
|
176
|
-
fail ArgumentError, "Missing the required parameter 'via' when calling PublicApi.complete_self_service_browser_verification_flow"
|
421
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.complete_self_service_verification_flow_with_link_method ...'
|
177
422
|
end
|
178
423
|
# resource path
|
179
|
-
local_var_path = '/self-service/
|
424
|
+
local_var_path = '/self-service/verification/methods/link'
|
180
425
|
|
181
426
|
# query parameters
|
182
427
|
query_params = opts[:query_params] || {}
|
183
|
-
query_params[:'
|
428
|
+
query_params[:'token'] = opts[:'token'] if !opts[:'token'].nil?
|
429
|
+
query_params[:'flow'] = opts[:'flow'] if !opts[:'flow'].nil?
|
184
430
|
|
185
431
|
# header parameters
|
186
432
|
header_params = opts[:header_params] || {}
|
187
433
|
# HTTP header 'Accept' (if needed)
|
188
434
|
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
435
|
+
# HTTP header 'Content-Type'
|
436
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded'])
|
189
437
|
|
190
438
|
# form parameters
|
191
439
|
form_params = opts[:form_params] || {}
|
192
440
|
|
193
441
|
# http body (model)
|
194
|
-
post_body = opts[:body]
|
442
|
+
post_body = opts[:body] || @api_client.object_to_http_body(opts[:'body'])
|
195
443
|
|
196
444
|
# return_type
|
197
445
|
return_type = opts[:return_type]
|
@@ -210,12 +458,12 @@ module OryHydraClient
|
|
210
458
|
|
211
459
|
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
212
460
|
if @api_client.config.debugging
|
213
|
-
@api_client.config.logger.debug "API called: PublicApi#
|
461
|
+
@api_client.config.logger.debug "API called: PublicApi#complete_self_service_verification_flow_with_link_method\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
214
462
|
end
|
215
463
|
return data, status_code, headers
|
216
464
|
end
|
217
465
|
|
218
|
-
# Get a
|
466
|
+
# Get a Traits Schema Definition
|
219
467
|
# @param id [String] ID must be set to the ID of schema you want to get
|
220
468
|
# @param [Hash] opts the optional parameters
|
221
469
|
# @return [Object]
|
@@ -224,7 +472,7 @@ module OryHydraClient
|
|
224
472
|
data
|
225
473
|
end
|
226
474
|
|
227
|
-
# Get a
|
475
|
+
# Get a Traits Schema Definition
|
228
476
|
# @param id [String] ID must be set to the ID of schema you want to get
|
229
477
|
# @param [Hash] opts the optional parameters
|
230
478
|
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
@@ -275,35 +523,35 @@ module OryHydraClient
|
|
275
523
|
return data, status_code, headers
|
276
524
|
end
|
277
525
|
|
278
|
-
# Get
|
279
|
-
# This endpoint returns
|
280
|
-
# @param
|
526
|
+
# Get User-Facing Self-Service Errors
|
527
|
+
# This endpoint returns the error associated with a user-facing self service errors. This endpoint supports stub values to help you implement the error UI: `?error=stub:500` - returns a stub 500 (Internal Server Error) error. More information can be found at [ORY Kratos User User Facing Error Documentation](https://www.ory.sh/docs/kratos/self-service/flows/user-facing-errors).
|
528
|
+
# @param error [String] Error is the container's ID
|
281
529
|
# @param [Hash] opts the optional parameters
|
282
|
-
# @return [
|
283
|
-
def
|
284
|
-
data, _status_code, _headers =
|
530
|
+
# @return [ErrorContainer]
|
531
|
+
def get_self_service_error(error, opts = {})
|
532
|
+
data, _status_code, _headers = get_self_service_error_with_http_info(error, opts)
|
285
533
|
data
|
286
534
|
end
|
287
535
|
|
288
|
-
# Get
|
289
|
-
# This endpoint returns
|
290
|
-
# @param
|
536
|
+
# Get User-Facing Self-Service Errors
|
537
|
+
# This endpoint returns the error associated with a user-facing self service errors. This endpoint supports stub values to help you implement the error UI: `?error=stub:500` - returns a stub 500 (Internal Server Error) error. More information can be found at [ORY Kratos User User Facing Error Documentation](https://www.ory.sh/docs/kratos/self-service/flows/user-facing-errors).
|
538
|
+
# @param error [String] Error is the container's ID
|
291
539
|
# @param [Hash] opts the optional parameters
|
292
|
-
# @return [Array<(
|
293
|
-
def
|
540
|
+
# @return [Array<(ErrorContainer, Integer, Hash)>] ErrorContainer data, response status code and response headers
|
541
|
+
def get_self_service_error_with_http_info(error, opts = {})
|
294
542
|
if @api_client.config.debugging
|
295
|
-
@api_client.config.logger.debug 'Calling API: PublicApi.
|
543
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.get_self_service_error ...'
|
296
544
|
end
|
297
|
-
# verify the required parameter '
|
298
|
-
if @api_client.config.client_side_validation &&
|
299
|
-
fail ArgumentError, "Missing the required parameter '
|
545
|
+
# verify the required parameter 'error' is set
|
546
|
+
if @api_client.config.client_side_validation && error.nil?
|
547
|
+
fail ArgumentError, "Missing the required parameter 'error' when calling PublicApi.get_self_service_error"
|
300
548
|
end
|
301
549
|
# resource path
|
302
|
-
local_var_path = '/self-service/
|
550
|
+
local_var_path = '/self-service/errors'
|
303
551
|
|
304
552
|
# query parameters
|
305
553
|
query_params = opts[:query_params] || {}
|
306
|
-
query_params[:'
|
554
|
+
query_params[:'error'] = error
|
307
555
|
|
308
556
|
# header parameters
|
309
557
|
header_params = opts[:header_params] || {}
|
@@ -317,7 +565,7 @@ module OryHydraClient
|
|
317
565
|
post_body = opts[:body]
|
318
566
|
|
319
567
|
# return_type
|
320
|
-
return_type = opts[:return_type] || '
|
568
|
+
return_type = opts[:return_type] || 'ErrorContainer'
|
321
569
|
|
322
570
|
# auth_names
|
323
571
|
auth_names = opts[:auth_names] || []
|
@@ -333,40 +581,40 @@ module OryHydraClient
|
|
333
581
|
|
334
582
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
335
583
|
if @api_client.config.debugging
|
336
|
-
@api_client.config.logger.debug "API called: PublicApi#
|
584
|
+
@api_client.config.logger.debug "API called: PublicApi#get_self_service_error\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
337
585
|
end
|
338
586
|
return data, status_code, headers
|
339
587
|
end
|
340
588
|
|
341
|
-
# Get
|
342
|
-
# This endpoint returns a
|
343
|
-
# @param
|
589
|
+
# Get Login Flow
|
590
|
+
# This endpoint returns a login flow's context with, for example, error details and other information. More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
591
|
+
# @param id [String] The Login Flow ID The value for this parameter comes from `flow` URL Query parameter sent to your application (e.g. `/login?flow=abcde`).
|
344
592
|
# @param [Hash] opts the optional parameters
|
345
|
-
# @return [
|
346
|
-
def
|
347
|
-
data, _status_code, _headers =
|
593
|
+
# @return [LoginFlow]
|
594
|
+
def get_self_service_login_flow(id, opts = {})
|
595
|
+
data, _status_code, _headers = get_self_service_login_flow_with_http_info(id, opts)
|
348
596
|
data
|
349
597
|
end
|
350
598
|
|
351
|
-
# Get
|
352
|
-
# This endpoint returns a
|
353
|
-
# @param
|
599
|
+
# Get Login Flow
|
600
|
+
# This endpoint returns a login flow's context with, for example, error details and other information. More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
601
|
+
# @param id [String] The Login Flow ID The value for this parameter comes from `flow` URL Query parameter sent to your application (e.g. `/login?flow=abcde`).
|
354
602
|
# @param [Hash] opts the optional parameters
|
355
|
-
# @return [Array<(
|
356
|
-
def
|
603
|
+
# @return [Array<(LoginFlow, Integer, Hash)>] LoginFlow data, response status code and response headers
|
604
|
+
def get_self_service_login_flow_with_http_info(id, opts = {})
|
357
605
|
if @api_client.config.debugging
|
358
|
-
@api_client.config.logger.debug 'Calling API: PublicApi.
|
606
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.get_self_service_login_flow ...'
|
359
607
|
end
|
360
|
-
# verify the required parameter '
|
361
|
-
if @api_client.config.client_side_validation &&
|
362
|
-
fail ArgumentError, "Missing the required parameter '
|
608
|
+
# verify the required parameter 'id' is set
|
609
|
+
if @api_client.config.client_side_validation && id.nil?
|
610
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling PublicApi.get_self_service_login_flow"
|
363
611
|
end
|
364
612
|
# resource path
|
365
|
-
local_var_path = '/self-service/
|
613
|
+
local_var_path = '/self-service/login/flows'
|
366
614
|
|
367
615
|
# query parameters
|
368
616
|
query_params = opts[:query_params] || {}
|
369
|
-
query_params[:'
|
617
|
+
query_params[:'id'] = id
|
370
618
|
|
371
619
|
# header parameters
|
372
620
|
header_params = opts[:header_params] || {}
|
@@ -380,7 +628,7 @@ module OryHydraClient
|
|
380
628
|
post_body = opts[:body]
|
381
629
|
|
382
630
|
# return_type
|
383
|
-
return_type = opts[:return_type] || '
|
631
|
+
return_type = opts[:return_type] || 'LoginFlow'
|
384
632
|
|
385
633
|
# auth_names
|
386
634
|
auth_names = opts[:auth_names] || []
|
@@ -396,40 +644,40 @@ module OryHydraClient
|
|
396
644
|
|
397
645
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
398
646
|
if @api_client.config.debugging
|
399
|
-
@api_client.config.logger.debug "API called: PublicApi#
|
647
|
+
@api_client.config.logger.debug "API called: PublicApi#get_self_service_login_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
400
648
|
end
|
401
649
|
return data, status_code, headers
|
402
650
|
end
|
403
651
|
|
404
|
-
# Get
|
405
|
-
#
|
406
|
-
# @param
|
652
|
+
# Get information about a recovery flow
|
653
|
+
# This endpoint returns a recovery flow's context with, for example, error details and other information. More information can be found at [ORY Kratos Account Recovery Documentation](../self-service/flows/account-recovery.mdx).
|
654
|
+
# @param id [String] The Flow ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/recovery?flow=abcde`).
|
407
655
|
# @param [Hash] opts the optional parameters
|
408
|
-
# @return [
|
409
|
-
def
|
410
|
-
data, _status_code, _headers =
|
656
|
+
# @return [RecoveryFlow]
|
657
|
+
def get_self_service_recovery_flow(id, opts = {})
|
658
|
+
data, _status_code, _headers = get_self_service_recovery_flow_with_http_info(id, opts)
|
411
659
|
data
|
412
660
|
end
|
413
661
|
|
414
|
-
# Get
|
415
|
-
#
|
416
|
-
# @param
|
662
|
+
# Get information about a recovery flow
|
663
|
+
# This endpoint returns a recovery flow's context with, for example, error details and other information. More information can be found at [ORY Kratos Account Recovery Documentation](../self-service/flows/account-recovery.mdx).
|
664
|
+
# @param id [String] The Flow ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/recovery?flow=abcde`).
|
417
665
|
# @param [Hash] opts the optional parameters
|
418
|
-
# @return [Array<(
|
419
|
-
def
|
666
|
+
# @return [Array<(RecoveryFlow, Integer, Hash)>] RecoveryFlow data, response status code and response headers
|
667
|
+
def get_self_service_recovery_flow_with_http_info(id, opts = {})
|
420
668
|
if @api_client.config.debugging
|
421
|
-
@api_client.config.logger.debug 'Calling API: PublicApi.
|
669
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.get_self_service_recovery_flow ...'
|
422
670
|
end
|
423
|
-
# verify the required parameter '
|
424
|
-
if @api_client.config.client_side_validation &&
|
425
|
-
fail ArgumentError, "Missing the required parameter '
|
671
|
+
# verify the required parameter 'id' is set
|
672
|
+
if @api_client.config.client_side_validation && id.nil?
|
673
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling PublicApi.get_self_service_recovery_flow"
|
426
674
|
end
|
427
675
|
# resource path
|
428
|
-
local_var_path = '/self-service/
|
676
|
+
local_var_path = '/self-service/recovery/flows'
|
429
677
|
|
430
678
|
# query parameters
|
431
679
|
query_params = opts[:query_params] || {}
|
432
|
-
query_params[:'
|
680
|
+
query_params[:'id'] = id
|
433
681
|
|
434
682
|
# header parameters
|
435
683
|
header_params = opts[:header_params] || {}
|
@@ -443,7 +691,7 @@ module OryHydraClient
|
|
443
691
|
post_body = opts[:body]
|
444
692
|
|
445
693
|
# return_type
|
446
|
-
return_type = opts[:return_type] || '
|
694
|
+
return_type = opts[:return_type] || 'RecoveryFlow'
|
447
695
|
|
448
696
|
# auth_names
|
449
697
|
auth_names = opts[:auth_names] || []
|
@@ -459,36 +707,40 @@ module OryHydraClient
|
|
459
707
|
|
460
708
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
461
709
|
if @api_client.config.debugging
|
462
|
-
@api_client.config.logger.debug "API called: PublicApi#
|
710
|
+
@api_client.config.logger.debug "API called: PublicApi#get_self_service_recovery_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
463
711
|
end
|
464
712
|
return data, status_code, headers
|
465
713
|
end
|
466
714
|
|
467
|
-
# Get
|
468
|
-
# This endpoint returns
|
715
|
+
# Get Registration Flow
|
716
|
+
# This endpoint returns a registration flow's context with, for example, error details and other information. More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
717
|
+
# @param id [String] The Registration Flow ID The value for this parameter comes from `flow` URL Query parameter sent to your application (e.g. `/registration?flow=abcde`).
|
469
718
|
# @param [Hash] opts the optional parameters
|
470
|
-
# @
|
471
|
-
|
472
|
-
|
473
|
-
data, _status_code, _headers = get_self_service_error_with_http_info(opts)
|
719
|
+
# @return [RegistrationFlow]
|
720
|
+
def get_self_service_registration_flow(id, opts = {})
|
721
|
+
data, _status_code, _headers = get_self_service_registration_flow_with_http_info(id, opts)
|
474
722
|
data
|
475
723
|
end
|
476
724
|
|
477
|
-
# Get
|
478
|
-
# This endpoint returns
|
725
|
+
# Get Registration Flow
|
726
|
+
# This endpoint returns a registration flow's context with, for example, error details and other information. More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
727
|
+
# @param id [String] The Registration Flow ID The value for this parameter comes from `flow` URL Query parameter sent to your application (e.g. `/registration?flow=abcde`).
|
479
728
|
# @param [Hash] opts the optional parameters
|
480
|
-
# @
|
481
|
-
|
482
|
-
def get_self_service_error_with_http_info(opts = {})
|
729
|
+
# @return [Array<(RegistrationFlow, Integer, Hash)>] RegistrationFlow data, response status code and response headers
|
730
|
+
def get_self_service_registration_flow_with_http_info(id, opts = {})
|
483
731
|
if @api_client.config.debugging
|
484
|
-
@api_client.config.logger.debug 'Calling API: PublicApi.
|
732
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.get_self_service_registration_flow ...'
|
733
|
+
end
|
734
|
+
# verify the required parameter 'id' is set
|
735
|
+
if @api_client.config.client_side_validation && id.nil?
|
736
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling PublicApi.get_self_service_registration_flow"
|
485
737
|
end
|
486
738
|
# resource path
|
487
|
-
local_var_path = '/self-service/
|
739
|
+
local_var_path = '/self-service/registration/flows'
|
488
740
|
|
489
741
|
# query parameters
|
490
742
|
query_params = opts[:query_params] || {}
|
491
|
-
query_params[:'
|
743
|
+
query_params[:'id'] = id
|
492
744
|
|
493
745
|
# header parameters
|
494
746
|
header_params = opts[:header_params] || {}
|
@@ -502,7 +754,7 @@ module OryHydraClient
|
|
502
754
|
post_body = opts[:body]
|
503
755
|
|
504
756
|
# return_type
|
505
|
-
return_type = opts[:return_type] || '
|
757
|
+
return_type = opts[:return_type] || 'RegistrationFlow'
|
506
758
|
|
507
759
|
# auth_names
|
508
760
|
auth_names = opts[:auth_names] || []
|
@@ -518,40 +770,40 @@ module OryHydraClient
|
|
518
770
|
|
519
771
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
520
772
|
if @api_client.config.debugging
|
521
|
-
@api_client.config.logger.debug "API called: PublicApi#
|
773
|
+
@api_client.config.logger.debug "API called: PublicApi#get_self_service_registration_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
522
774
|
end
|
523
775
|
return data, status_code, headers
|
524
776
|
end
|
525
777
|
|
526
|
-
# Get
|
527
|
-
# When accessing this endpoint through ORY Kratos' Public API
|
528
|
-
# @param
|
778
|
+
# Get Settings Flow
|
779
|
+
# When accessing this endpoint through ORY Kratos' Public API you must ensure that either the ORY Kratos Session Cookie or the ORY Kratos Session Token are set. The public endpoint does not return 404 status codes but instead 403 or 500 to improve data privacy. You can access this endpoint without credentials when using ORY Kratos' Admin API. More information can be found at [ORY Kratos User Settings & Profile Management Documentation](../self-service/flows/user-settings).
|
780
|
+
# @param id [String] ID is the Settings Flow ID The value for this parameter comes from `flow` URL Query parameter sent to your application (e.g. `/settings?flow=abcde`).
|
529
781
|
# @param [Hash] opts the optional parameters
|
530
|
-
# @return [
|
531
|
-
def
|
532
|
-
data, _status_code, _headers =
|
782
|
+
# @return [SettingsFlow]
|
783
|
+
def get_self_service_settings_flow(id, opts = {})
|
784
|
+
data, _status_code, _headers = get_self_service_settings_flow_with_http_info(id, opts)
|
533
785
|
data
|
534
786
|
end
|
535
787
|
|
536
|
-
# Get
|
537
|
-
# When accessing this endpoint through ORY Kratos' Public API
|
538
|
-
# @param
|
788
|
+
# Get Settings Flow
|
789
|
+
# When accessing this endpoint through ORY Kratos' Public API you must ensure that either the ORY Kratos Session Cookie or the ORY Kratos Session Token are set. The public endpoint does not return 404 status codes but instead 403 or 500 to improve data privacy. You can access this endpoint without credentials when using ORY Kratos' Admin API. More information can be found at [ORY Kratos User Settings & Profile Management Documentation](../self-service/flows/user-settings).
|
790
|
+
# @param id [String] ID is the Settings Flow ID The value for this parameter comes from `flow` URL Query parameter sent to your application (e.g. `/settings?flow=abcde`).
|
539
791
|
# @param [Hash] opts the optional parameters
|
540
|
-
# @return [Array<(
|
541
|
-
def
|
792
|
+
# @return [Array<(SettingsFlow, Integer, Hash)>] SettingsFlow data, response status code and response headers
|
793
|
+
def get_self_service_settings_flow_with_http_info(id, opts = {})
|
542
794
|
if @api_client.config.debugging
|
543
|
-
@api_client.config.logger.debug 'Calling API: PublicApi.
|
795
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.get_self_service_settings_flow ...'
|
544
796
|
end
|
545
|
-
# verify the required parameter '
|
546
|
-
if @api_client.config.client_side_validation &&
|
547
|
-
fail ArgumentError, "Missing the required parameter '
|
797
|
+
# verify the required parameter 'id' is set
|
798
|
+
if @api_client.config.client_side_validation && id.nil?
|
799
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling PublicApi.get_self_service_settings_flow"
|
548
800
|
end
|
549
801
|
# resource path
|
550
|
-
local_var_path = '/self-service/
|
802
|
+
local_var_path = '/self-service/settings/flows'
|
551
803
|
|
552
804
|
# query parameters
|
553
805
|
query_params = opts[:query_params] || {}
|
554
|
-
query_params[:'
|
806
|
+
query_params[:'id'] = id
|
555
807
|
|
556
808
|
# header parameters
|
557
809
|
header_params = opts[:header_params] || {}
|
@@ -565,10 +817,10 @@ module OryHydraClient
|
|
565
817
|
post_body = opts[:body]
|
566
818
|
|
567
819
|
# return_type
|
568
|
-
return_type = opts[:return_type] || '
|
820
|
+
return_type = opts[:return_type] || 'SettingsFlow'
|
569
821
|
|
570
822
|
# auth_names
|
571
|
-
auth_names = opts[:auth_names] || []
|
823
|
+
auth_names = opts[:auth_names] || ['sessionToken']
|
572
824
|
|
573
825
|
new_options = opts.merge(
|
574
826
|
:header_params => header_params,
|
@@ -581,33 +833,40 @@ module OryHydraClient
|
|
581
833
|
|
582
834
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
583
835
|
if @api_client.config.debugging
|
584
|
-
@api_client.config.logger.debug "API called: PublicApi#
|
836
|
+
@api_client.config.logger.debug "API called: PublicApi#get_self_service_settings_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
585
837
|
end
|
586
838
|
return data, status_code, headers
|
587
839
|
end
|
588
840
|
|
589
|
-
#
|
590
|
-
# This endpoint
|
841
|
+
# Get Verification Flow
|
842
|
+
# This endpoint returns a verification flow's context with, for example, error details and other information. More information can be found at [ORY Kratos Email and Phone Verification Documentation](https://www.ory.sh/docs/kratos/selfservice/flows/verify-email-account-activation).
|
843
|
+
# @param id [String] The Flow ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/verification?flow=abcde`).
|
591
844
|
# @param [Hash] opts the optional parameters
|
592
|
-
# @return [
|
593
|
-
def
|
594
|
-
|
595
|
-
|
845
|
+
# @return [VerificationFlow]
|
846
|
+
def get_self_service_verification_flow(id, opts = {})
|
847
|
+
data, _status_code, _headers = get_self_service_verification_flow_with_http_info(id, opts)
|
848
|
+
data
|
596
849
|
end
|
597
850
|
|
598
|
-
#
|
599
|
-
# This endpoint
|
851
|
+
# Get Verification Flow
|
852
|
+
# This endpoint returns a verification flow's context with, for example, error details and other information. More information can be found at [ORY Kratos Email and Phone Verification Documentation](https://www.ory.sh/docs/kratos/selfservice/flows/verify-email-account-activation).
|
853
|
+
# @param id [String] The Flow ID The value for this parameter comes from `request` URL Query parameter sent to your application (e.g. `/verification?flow=abcde`).
|
600
854
|
# @param [Hash] opts the optional parameters
|
601
|
-
# @return [Array<(
|
602
|
-
def
|
855
|
+
# @return [Array<(VerificationFlow, Integer, Hash)>] VerificationFlow data, response status code and response headers
|
856
|
+
def get_self_service_verification_flow_with_http_info(id, opts = {})
|
603
857
|
if @api_client.config.debugging
|
604
|
-
@api_client.config.logger.debug 'Calling API: PublicApi.
|
858
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.get_self_service_verification_flow ...'
|
859
|
+
end
|
860
|
+
# verify the required parameter 'id' is set
|
861
|
+
if @api_client.config.client_side_validation && id.nil?
|
862
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling PublicApi.get_self_service_verification_flow"
|
605
863
|
end
|
606
864
|
# resource path
|
607
|
-
local_var_path = '/self-service/
|
865
|
+
local_var_path = '/self-service/verification/flows'
|
608
866
|
|
609
867
|
# query parameters
|
610
868
|
query_params = opts[:query_params] || {}
|
869
|
+
query_params[:'id'] = id
|
611
870
|
|
612
871
|
# header parameters
|
613
872
|
header_params = opts[:header_params] || {}
|
@@ -621,7 +880,7 @@ module OryHydraClient
|
|
621
880
|
post_body = opts[:body]
|
622
881
|
|
623
882
|
# return_type
|
624
|
-
return_type = opts[:return_type]
|
883
|
+
return_type = opts[:return_type] || 'VerificationFlow'
|
625
884
|
|
626
885
|
# auth_names
|
627
886
|
auth_names = opts[:auth_names] || []
|
@@ -637,7 +896,7 @@ module OryHydraClient
|
|
637
896
|
|
638
897
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
639
898
|
if @api_client.config.debugging
|
640
|
-
@api_client.config.logger.debug "API called: PublicApi#
|
899
|
+
@api_client.config.logger.debug "API called: PublicApi#get_self_service_verification_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
641
900
|
end
|
642
901
|
return data, status_code, headers
|
643
902
|
end
|
@@ -698,28 +957,31 @@ module OryHydraClient
|
|
698
957
|
return data, status_code, headers
|
699
958
|
end
|
700
959
|
|
701
|
-
# Initialize
|
702
|
-
# This endpoint
|
960
|
+
# Initialize Login Flow for API clients
|
961
|
+
# This endpoint initiates a login flow for API clients such as mobile devices, smart TVs, and so on. If a valid provided session cookie or session token is provided, a 400 Bad Request error will be returned unless the URL query parameter `?refresh=true` is set. To fetch an existing login flow call `/self-service/login/flows?flow=<flow_id>`. :::warning You MUST NOT use this endpoint in client-side (Single Page Apps, ReactJS, AngularJS) nor server-side (Java Server Pages, NodeJS, PHP, Golang, ...) browser applications. Using this endpoint in these applications will make you vulnerable to a variety of CSRF attacks, including CSRF login attacks. This endpoint MUST ONLY be used in scenarios such as native mobile apps (React Native, Objective C, Swift, Java, ...). ::: More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
703
962
|
# @param [Hash] opts the optional parameters
|
704
|
-
# @
|
705
|
-
|
706
|
-
|
707
|
-
|
963
|
+
# @option opts [Boolean] :refresh Refresh a login session If set to true, this will refresh an existing login session by asking the user to sign in again. This will reset the authenticated_at time of the session.
|
964
|
+
# @return [LoginFlow]
|
965
|
+
def initialize_self_service_login_via_api_flow(opts = {})
|
966
|
+
data, _status_code, _headers = initialize_self_service_login_via_api_flow_with_http_info(opts)
|
967
|
+
data
|
708
968
|
end
|
709
969
|
|
710
|
-
# Initialize
|
711
|
-
# This endpoint
|
970
|
+
# Initialize Login Flow for API clients
|
971
|
+
# This endpoint initiates a login flow for API clients such as mobile devices, smart TVs, and so on. If a valid provided session cookie or session token is provided, a 400 Bad Request error will be returned unless the URL query parameter `?refresh=true` is set. To fetch an existing login flow call `/self-service/login/flows?flow=<flow_id>`. :::warning You MUST NOT use this endpoint in client-side (Single Page Apps, ReactJS, AngularJS) nor server-side (Java Server Pages, NodeJS, PHP, Golang, ...) browser applications. Using this endpoint in these applications will make you vulnerable to a variety of CSRF attacks, including CSRF login attacks. This endpoint MUST ONLY be used in scenarios such as native mobile apps (React Native, Objective C, Swift, Java, ...). ::: More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
712
972
|
# @param [Hash] opts the optional parameters
|
713
|
-
# @
|
714
|
-
|
973
|
+
# @option opts [Boolean] :refresh Refresh a login session If set to true, this will refresh an existing login session by asking the user to sign in again. This will reset the authenticated_at time of the session.
|
974
|
+
# @return [Array<(LoginFlow, Integer, Hash)>] LoginFlow data, response status code and response headers
|
975
|
+
def initialize_self_service_login_via_api_flow_with_http_info(opts = {})
|
715
976
|
if @api_client.config.debugging
|
716
|
-
@api_client.config.logger.debug 'Calling API: PublicApi.
|
977
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.initialize_self_service_login_via_api_flow ...'
|
717
978
|
end
|
718
979
|
# resource path
|
719
|
-
local_var_path = '/self-service/
|
980
|
+
local_var_path = '/self-service/login/api'
|
720
981
|
|
721
982
|
# query parameters
|
722
983
|
query_params = opts[:query_params] || {}
|
984
|
+
query_params[:'refresh'] = opts[:'refresh'] if !opts[:'refresh'].nil?
|
723
985
|
|
724
986
|
# header parameters
|
725
987
|
header_params = opts[:header_params] || {}
|
@@ -733,7 +995,7 @@ module OryHydraClient
|
|
733
995
|
post_body = opts[:body]
|
734
996
|
|
735
997
|
# return_type
|
736
|
-
return_type = opts[:return_type]
|
998
|
+
return_type = opts[:return_type] || 'LoginFlow'
|
737
999
|
|
738
1000
|
# auth_names
|
739
1001
|
auth_names = opts[:auth_names] || []
|
@@ -749,36 +1011,30 @@ module OryHydraClient
|
|
749
1011
|
|
750
1012
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
751
1013
|
if @api_client.config.debugging
|
752
|
-
@api_client.config.logger.debug "API called: PublicApi#
|
1014
|
+
@api_client.config.logger.debug "API called: PublicApi#initialize_self_service_login_via_api_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
753
1015
|
end
|
754
1016
|
return data, status_code, headers
|
755
1017
|
end
|
756
1018
|
|
757
|
-
# Initialize
|
758
|
-
# This endpoint initializes a browser-based
|
759
|
-
# @param via [String] What to verify Currently only \"email\" is supported.
|
1019
|
+
# Initialize Login Flow for browsers
|
1020
|
+
# This endpoint initializes a browser-based user login flow. Once initialized, the browser will be redirected to `selfservice.flows.login.ui_url` with the flow ID set as the query parameter `?flow=`. If a valid user session exists already, the browser will be redirected to `urls.default_redirect_url` unless the query parameter `?refresh=true` was set. This endpoint is NOT INTENDED for API clients and only works with browsers (Chrome, Firefox, ...). More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
760
1021
|
# @param [Hash] opts the optional parameters
|
761
1022
|
# @return [nil]
|
762
|
-
def
|
763
|
-
|
1023
|
+
def initialize_self_service_login_via_browser_flow(opts = {})
|
1024
|
+
initialize_self_service_login_via_browser_flow_with_http_info(opts)
|
764
1025
|
nil
|
765
1026
|
end
|
766
1027
|
|
767
|
-
# Initialize
|
768
|
-
# This endpoint initializes a browser-based
|
769
|
-
# @param via [String] What to verify Currently only \"email\" is supported.
|
1028
|
+
# Initialize Login Flow for browsers
|
1029
|
+
# This endpoint initializes a browser-based user login flow. Once initialized, the browser will be redirected to `selfservice.flows.login.ui_url` with the flow ID set as the query parameter `?flow=`. If a valid user session exists already, the browser will be redirected to `urls.default_redirect_url` unless the query parameter `?refresh=true` was set. This endpoint is NOT INTENDED for API clients and only works with browsers (Chrome, Firefox, ...). More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
770
1030
|
# @param [Hash] opts the optional parameters
|
771
1031
|
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
772
|
-
def
|
1032
|
+
def initialize_self_service_login_via_browser_flow_with_http_info(opts = {})
|
773
1033
|
if @api_client.config.debugging
|
774
|
-
@api_client.config.logger.debug 'Calling API: PublicApi.
|
775
|
-
end
|
776
|
-
# verify the required parameter 'via' is set
|
777
|
-
if @api_client.config.client_side_validation && via.nil?
|
778
|
-
fail ArgumentError, "Missing the required parameter 'via' when calling PublicApi.initialize_self_service_browser_verification_flow"
|
1034
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.initialize_self_service_login_via_browser_flow ...'
|
779
1035
|
end
|
780
1036
|
# resource path
|
781
|
-
local_var_path = '/self-service/browser
|
1037
|
+
local_var_path = '/self-service/login/browser'
|
782
1038
|
|
783
1039
|
# query parameters
|
784
1040
|
query_params = opts[:query_params] || {}
|
@@ -811,30 +1067,30 @@ module OryHydraClient
|
|
811
1067
|
|
812
1068
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
813
1069
|
if @api_client.config.debugging
|
814
|
-
@api_client.config.logger.debug "API called: PublicApi#
|
1070
|
+
@api_client.config.logger.debug "API called: PublicApi#initialize_self_service_login_via_browser_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
815
1071
|
end
|
816
1072
|
return data, status_code, headers
|
817
1073
|
end
|
818
1074
|
|
819
|
-
# Initialize
|
820
|
-
# This endpoint
|
1075
|
+
# Initialize Recovery Flow for API Clients
|
1076
|
+
# This endpoint initiates a recovery flow for API clients such as mobile devices, smart TVs, and so on. If a valid provided session cookie or session token is provided, a 400 Bad Request error. To fetch an existing recovery flow call `/self-service/recovery/flows?flow=<flow_id>`. :::warning You MUST NOT use this endpoint in client-side (Single Page Apps, ReactJS, AngularJS) nor server-side (Java Server Pages, NodeJS, PHP, Golang, ...) browser applications. Using this endpoint in these applications will make you vulnerable to a variety of CSRF attacks. This endpoint MUST ONLY be used in scenarios such as native mobile apps (React Native, Objective C, Swift, Java, ...). ::: More information can be found at [ORY Kratos Account Recovery Documentation](../self-service/flows/account-recovery.mdx).
|
821
1077
|
# @param [Hash] opts the optional parameters
|
822
|
-
# @return [
|
823
|
-
def
|
824
|
-
|
825
|
-
|
1078
|
+
# @return [RecoveryFlow]
|
1079
|
+
def initialize_self_service_recovery_via_api_flow(opts = {})
|
1080
|
+
data, _status_code, _headers = initialize_self_service_recovery_via_api_flow_with_http_info(opts)
|
1081
|
+
data
|
826
1082
|
end
|
827
1083
|
|
828
|
-
# Initialize
|
829
|
-
# This endpoint
|
1084
|
+
# Initialize Recovery Flow for API Clients
|
1085
|
+
# This endpoint initiates a recovery flow for API clients such as mobile devices, smart TVs, and so on. If a valid provided session cookie or session token is provided, a 400 Bad Request error. To fetch an existing recovery flow call `/self-service/recovery/flows?flow=<flow_id>`. :::warning You MUST NOT use this endpoint in client-side (Single Page Apps, ReactJS, AngularJS) nor server-side (Java Server Pages, NodeJS, PHP, Golang, ...) browser applications. Using this endpoint in these applications will make you vulnerable to a variety of CSRF attacks. This endpoint MUST ONLY be used in scenarios such as native mobile apps (React Native, Objective C, Swift, Java, ...). ::: More information can be found at [ORY Kratos Account Recovery Documentation](../self-service/flows/account-recovery.mdx).
|
830
1086
|
# @param [Hash] opts the optional parameters
|
831
|
-
# @return [Array<(
|
832
|
-
def
|
1087
|
+
# @return [Array<(RecoveryFlow, Integer, Hash)>] RecoveryFlow data, response status code and response headers
|
1088
|
+
def initialize_self_service_recovery_via_api_flow_with_http_info(opts = {})
|
833
1089
|
if @api_client.config.debugging
|
834
|
-
@api_client.config.logger.debug 'Calling API: PublicApi.
|
1090
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.initialize_self_service_recovery_via_api_flow ...'
|
835
1091
|
end
|
836
1092
|
# resource path
|
837
|
-
local_var_path = '/self-service/
|
1093
|
+
local_var_path = '/self-service/recovery/api'
|
838
1094
|
|
839
1095
|
# query parameters
|
840
1096
|
query_params = opts[:query_params] || {}
|
@@ -851,7 +1107,7 @@ module OryHydraClient
|
|
851
1107
|
post_body = opts[:body]
|
852
1108
|
|
853
1109
|
# return_type
|
854
|
-
return_type = opts[:return_type]
|
1110
|
+
return_type = opts[:return_type] || 'RecoveryFlow'
|
855
1111
|
|
856
1112
|
# auth_names
|
857
1113
|
auth_names = opts[:auth_names] || []
|
@@ -867,42 +1123,30 @@ module OryHydraClient
|
|
867
1123
|
|
868
1124
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
869
1125
|
if @api_client.config.debugging
|
870
|
-
@api_client.config.logger.debug "API called: PublicApi#
|
1126
|
+
@api_client.config.logger.debug "API called: PublicApi#initialize_self_service_recovery_via_api_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
871
1127
|
end
|
872
1128
|
return data, status_code, headers
|
873
1129
|
end
|
874
1130
|
|
875
|
-
#
|
876
|
-
# This endpoint
|
877
|
-
# @param code [String]
|
878
|
-
# @param via [String] What to verify Currently only \"email\" is supported.
|
1131
|
+
# Initialize Recovery Flow for Browser Clients
|
1132
|
+
# This endpoint initializes a browser-based account recovery flow. Once initialized, the browser will be redirected to `selfservice.flows.recovery.ui_url` with the flow ID set as the query parameter `?flow=`. If a valid user session exists, the browser is returned to the configured return URL. This endpoint is NOT INTENDED for API clients and only works with browsers (Chrome, Firefox, ...). More information can be found at [ORY Kratos Account Recovery Documentation](../self-service/flows/account-recovery.mdx).
|
879
1133
|
# @param [Hash] opts the optional parameters
|
880
1134
|
# @return [nil]
|
881
|
-
def
|
882
|
-
|
1135
|
+
def initialize_self_service_recovery_via_browser_flow(opts = {})
|
1136
|
+
initialize_self_service_recovery_via_browser_flow_with_http_info(opts)
|
883
1137
|
nil
|
884
1138
|
end
|
885
1139
|
|
886
|
-
#
|
887
|
-
# This endpoint
|
888
|
-
# @param code [String]
|
889
|
-
# @param via [String] What to verify Currently only \"email\" is supported.
|
1140
|
+
# Initialize Recovery Flow for Browser Clients
|
1141
|
+
# This endpoint initializes a browser-based account recovery flow. Once initialized, the browser will be redirected to `selfservice.flows.recovery.ui_url` with the flow ID set as the query parameter `?flow=`. If a valid user session exists, the browser is returned to the configured return URL. This endpoint is NOT INTENDED for API clients and only works with browsers (Chrome, Firefox, ...). More information can be found at [ORY Kratos Account Recovery Documentation](../self-service/flows/account-recovery.mdx).
|
890
1142
|
# @param [Hash] opts the optional parameters
|
891
1143
|
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
892
|
-
def
|
1144
|
+
def initialize_self_service_recovery_via_browser_flow_with_http_info(opts = {})
|
893
1145
|
if @api_client.config.debugging
|
894
|
-
@api_client.config.logger.debug 'Calling API: PublicApi.
|
895
|
-
end
|
896
|
-
# verify the required parameter 'code' is set
|
897
|
-
if @api_client.config.client_side_validation && code.nil?
|
898
|
-
fail ArgumentError, "Missing the required parameter 'code' when calling PublicApi.self_service_browser_verify"
|
899
|
-
end
|
900
|
-
# verify the required parameter 'via' is set
|
901
|
-
if @api_client.config.client_side_validation && via.nil?
|
902
|
-
fail ArgumentError, "Missing the required parameter 'via' when calling PublicApi.self_service_browser_verify"
|
1146
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.initialize_self_service_recovery_via_browser_flow ...'
|
903
1147
|
end
|
904
1148
|
# resource path
|
905
|
-
local_var_path = '/self-service/browser
|
1149
|
+
local_var_path = '/self-service/recovery/browser'
|
906
1150
|
|
907
1151
|
# query parameters
|
908
1152
|
query_params = opts[:query_params] || {}
|
@@ -935,30 +1179,30 @@ module OryHydraClient
|
|
935
1179
|
|
936
1180
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
937
1181
|
if @api_client.config.debugging
|
938
|
-
@api_client.config.logger.debug "API called: PublicApi#
|
1182
|
+
@api_client.config.logger.debug "API called: PublicApi#initialize_self_service_recovery_via_browser_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
939
1183
|
end
|
940
1184
|
return data, status_code, headers
|
941
1185
|
end
|
942
1186
|
|
943
|
-
#
|
944
|
-
#
|
1187
|
+
# Initialize Registration Flow for API clients
|
1188
|
+
# This endpoint initiates a registration flow for API clients such as mobile devices, smart TVs, and so on. If a valid provided session cookie or session token is provided, a 400 Bad Request error will be returned unless the URL query parameter `?refresh=true` is set. To fetch an existing registration flow call `/self-service/registration/flows?flow=<flow_id>`. :::warning You MUST NOT use this endpoint in client-side (Single Page Apps, ReactJS, AngularJS) nor server-side (Java Server Pages, NodeJS, PHP, Golang, ...) browser applications. Using this endpoint in these applications will make you vulnerable to a variety of CSRF attacks. This endpoint MUST ONLY be used in scenarios such as native mobile apps (React Native, Objective C, Swift, Java, ...). ::: More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
945
1189
|
# @param [Hash] opts the optional parameters
|
946
|
-
# @return [
|
947
|
-
def
|
948
|
-
data, _status_code, _headers =
|
1190
|
+
# @return [RegistrationFlow]
|
1191
|
+
def initialize_self_service_registration_via_api_flow(opts = {})
|
1192
|
+
data, _status_code, _headers = initialize_self_service_registration_via_api_flow_with_http_info(opts)
|
949
1193
|
data
|
950
1194
|
end
|
951
1195
|
|
952
|
-
#
|
953
|
-
#
|
1196
|
+
# Initialize Registration Flow for API clients
|
1197
|
+
# This endpoint initiates a registration flow for API clients such as mobile devices, smart TVs, and so on. If a valid provided session cookie or session token is provided, a 400 Bad Request error will be returned unless the URL query parameter `?refresh=true` is set. To fetch an existing registration flow call `/self-service/registration/flows?flow=<flow_id>`. :::warning You MUST NOT use this endpoint in client-side (Single Page Apps, ReactJS, AngularJS) nor server-side (Java Server Pages, NodeJS, PHP, Golang, ...) browser applications. Using this endpoint in these applications will make you vulnerable to a variety of CSRF attacks. This endpoint MUST ONLY be used in scenarios such as native mobile apps (React Native, Objective C, Swift, Java, ...). ::: More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
954
1198
|
# @param [Hash] opts the optional parameters
|
955
|
-
# @return [Array<(
|
956
|
-
def
|
1199
|
+
# @return [Array<(RegistrationFlow, Integer, Hash)>] RegistrationFlow data, response status code and response headers
|
1200
|
+
def initialize_self_service_registration_via_api_flow_with_http_info(opts = {})
|
957
1201
|
if @api_client.config.debugging
|
958
|
-
@api_client.config.logger.debug 'Calling API: PublicApi.
|
1202
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.initialize_self_service_registration_via_api_flow ...'
|
959
1203
|
end
|
960
1204
|
# resource path
|
961
|
-
local_var_path = '/
|
1205
|
+
local_var_path = '/self-service/registration/api'
|
962
1206
|
|
963
1207
|
# query parameters
|
964
1208
|
query_params = opts[:query_params] || {}
|
@@ -975,7 +1219,7 @@ module OryHydraClient
|
|
975
1219
|
post_body = opts[:body]
|
976
1220
|
|
977
1221
|
# return_type
|
978
|
-
return_type = opts[:return_type] || '
|
1222
|
+
return_type = opts[:return_type] || 'RegistrationFlow'
|
979
1223
|
|
980
1224
|
# auth_names
|
981
1225
|
auth_names = opts[:auth_names] || []
|
@@ -989,6 +1233,412 @@ module OryHydraClient
|
|
989
1233
|
:return_type => return_type
|
990
1234
|
)
|
991
1235
|
|
1236
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
1237
|
+
if @api_client.config.debugging
|
1238
|
+
@api_client.config.logger.debug "API called: PublicApi#initialize_self_service_registration_via_api_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1239
|
+
end
|
1240
|
+
return data, status_code, headers
|
1241
|
+
end
|
1242
|
+
|
1243
|
+
# Initialize Registration Flow for browsers
|
1244
|
+
# This endpoint initializes a browser-based user registration flow. Once initialized, the browser will be redirected to `selfservice.flows.registration.ui_url` with the flow ID set as the query parameter `?flow=`. If a valid user session exists already, the browser will be redirected to `urls.default_redirect_url` unless the query parameter `?refresh=true` was set. :::note This endpoint is NOT INTENDED for API clients and only works with browsers (Chrome, Firefox, ...). ::: More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
1245
|
+
# @param [Hash] opts the optional parameters
|
1246
|
+
# @return [nil]
|
1247
|
+
def initialize_self_service_registration_via_browser_flow(opts = {})
|
1248
|
+
initialize_self_service_registration_via_browser_flow_with_http_info(opts)
|
1249
|
+
nil
|
1250
|
+
end
|
1251
|
+
|
1252
|
+
# Initialize Registration Flow for browsers
|
1253
|
+
# This endpoint initializes a browser-based user registration flow. Once initialized, the browser will be redirected to `selfservice.flows.registration.ui_url` with the flow ID set as the query parameter `?flow=`. If a valid user session exists already, the browser will be redirected to `urls.default_redirect_url` unless the query parameter `?refresh=true` was set. :::note This endpoint is NOT INTENDED for API clients and only works with browsers (Chrome, Firefox, ...). ::: More information can be found at [ORY Kratos User Login and User Registration Documentation](https://www.ory.sh/docs/next/kratos/self-service/flows/user-login-user-registration).
|
1254
|
+
# @param [Hash] opts the optional parameters
|
1255
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
1256
|
+
def initialize_self_service_registration_via_browser_flow_with_http_info(opts = {})
|
1257
|
+
if @api_client.config.debugging
|
1258
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.initialize_self_service_registration_via_browser_flow ...'
|
1259
|
+
end
|
1260
|
+
# resource path
|
1261
|
+
local_var_path = '/self-service/registration/browser'
|
1262
|
+
|
1263
|
+
# query parameters
|
1264
|
+
query_params = opts[:query_params] || {}
|
1265
|
+
|
1266
|
+
# header parameters
|
1267
|
+
header_params = opts[:header_params] || {}
|
1268
|
+
# HTTP header 'Accept' (if needed)
|
1269
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1270
|
+
|
1271
|
+
# form parameters
|
1272
|
+
form_params = opts[:form_params] || {}
|
1273
|
+
|
1274
|
+
# http body (model)
|
1275
|
+
post_body = opts[:body]
|
1276
|
+
|
1277
|
+
# return_type
|
1278
|
+
return_type = opts[:return_type]
|
1279
|
+
|
1280
|
+
# auth_names
|
1281
|
+
auth_names = opts[:auth_names] || []
|
1282
|
+
|
1283
|
+
new_options = opts.merge(
|
1284
|
+
:header_params => header_params,
|
1285
|
+
:query_params => query_params,
|
1286
|
+
:form_params => form_params,
|
1287
|
+
:body => post_body,
|
1288
|
+
:auth_names => auth_names,
|
1289
|
+
:return_type => return_type
|
1290
|
+
)
|
1291
|
+
|
1292
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
1293
|
+
if @api_client.config.debugging
|
1294
|
+
@api_client.config.logger.debug "API called: PublicApi#initialize_self_service_registration_via_browser_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1295
|
+
end
|
1296
|
+
return data, status_code, headers
|
1297
|
+
end
|
1298
|
+
|
1299
|
+
# Initialize Settings Flow for API Clients
|
1300
|
+
# This endpoint initiates a settings flow for API clients such as mobile devices, smart TVs, and so on. You must provide a valid ORY Kratos Session Token for this endpoint to respond with HTTP 200 OK. To fetch an existing settings flow call `/self-service/settings/flows?flow=<flow_id>`. :::warning You MUST NOT use this endpoint in client-side (Single Page Apps, ReactJS, AngularJS) nor server-side (Java Server Pages, NodeJS, PHP, Golang, ...) browser applications. Using this endpoint in these applications will make you vulnerable to a variety of CSRF attacks. This endpoint MUST ONLY be used in scenarios such as native mobile apps (React Native, Objective C, Swift, Java, ...). ::: More information can be found at [ORY Kratos User Settings & Profile Management Documentation](../self-service/flows/user-settings).
|
1301
|
+
# @param [Hash] opts the optional parameters
|
1302
|
+
# @return [SettingsFlow]
|
1303
|
+
def initialize_self_service_settings_via_api_flow(opts = {})
|
1304
|
+
data, _status_code, _headers = initialize_self_service_settings_via_api_flow_with_http_info(opts)
|
1305
|
+
data
|
1306
|
+
end
|
1307
|
+
|
1308
|
+
# Initialize Settings Flow for API Clients
|
1309
|
+
# This endpoint initiates a settings flow for API clients such as mobile devices, smart TVs, and so on. You must provide a valid ORY Kratos Session Token for this endpoint to respond with HTTP 200 OK. To fetch an existing settings flow call `/self-service/settings/flows?flow=<flow_id>`. :::warning You MUST NOT use this endpoint in client-side (Single Page Apps, ReactJS, AngularJS) nor server-side (Java Server Pages, NodeJS, PHP, Golang, ...) browser applications. Using this endpoint in these applications will make you vulnerable to a variety of CSRF attacks. This endpoint MUST ONLY be used in scenarios such as native mobile apps (React Native, Objective C, Swift, Java, ...). ::: More information can be found at [ORY Kratos User Settings & Profile Management Documentation](../self-service/flows/user-settings).
|
1310
|
+
# @param [Hash] opts the optional parameters
|
1311
|
+
# @return [Array<(SettingsFlow, Integer, Hash)>] SettingsFlow data, response status code and response headers
|
1312
|
+
def initialize_self_service_settings_via_api_flow_with_http_info(opts = {})
|
1313
|
+
if @api_client.config.debugging
|
1314
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.initialize_self_service_settings_via_api_flow ...'
|
1315
|
+
end
|
1316
|
+
# resource path
|
1317
|
+
local_var_path = '/self-service/settings/api'
|
1318
|
+
|
1319
|
+
# query parameters
|
1320
|
+
query_params = opts[:query_params] || {}
|
1321
|
+
|
1322
|
+
# header parameters
|
1323
|
+
header_params = opts[:header_params] || {}
|
1324
|
+
# HTTP header 'Accept' (if needed)
|
1325
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1326
|
+
|
1327
|
+
# form parameters
|
1328
|
+
form_params = opts[:form_params] || {}
|
1329
|
+
|
1330
|
+
# http body (model)
|
1331
|
+
post_body = opts[:body]
|
1332
|
+
|
1333
|
+
# return_type
|
1334
|
+
return_type = opts[:return_type] || 'SettingsFlow'
|
1335
|
+
|
1336
|
+
# auth_names
|
1337
|
+
auth_names = opts[:auth_names] || ['sessionToken']
|
1338
|
+
|
1339
|
+
new_options = opts.merge(
|
1340
|
+
:header_params => header_params,
|
1341
|
+
:query_params => query_params,
|
1342
|
+
:form_params => form_params,
|
1343
|
+
:body => post_body,
|
1344
|
+
:auth_names => auth_names,
|
1345
|
+
:return_type => return_type
|
1346
|
+
)
|
1347
|
+
|
1348
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
1349
|
+
if @api_client.config.debugging
|
1350
|
+
@api_client.config.logger.debug "API called: PublicApi#initialize_self_service_settings_via_api_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1351
|
+
end
|
1352
|
+
return data, status_code, headers
|
1353
|
+
end
|
1354
|
+
|
1355
|
+
# Initialize Settings Flow for Browsers
|
1356
|
+
# This endpoint initializes a browser-based user settings flow. Once initialized, the browser will be redirected to `selfservice.flows.settings.ui_url` with the flow ID set as the query parameter `?flow=`. If no valid ORY Kratos Session Cookie is included in the request, a login flow will be initialized. :::note This endpoint is NOT INTENDED for API clients and only works with browsers (Chrome, Firefox, ...). ::: More information can be found at [ORY Kratos User Settings & Profile Management Documentation](../self-service/flows/user-settings).
|
1357
|
+
# @param [Hash] opts the optional parameters
|
1358
|
+
# @return [nil]
|
1359
|
+
def initialize_self_service_settings_via_browser_flow(opts = {})
|
1360
|
+
initialize_self_service_settings_via_browser_flow_with_http_info(opts)
|
1361
|
+
nil
|
1362
|
+
end
|
1363
|
+
|
1364
|
+
# Initialize Settings Flow for Browsers
|
1365
|
+
# This endpoint initializes a browser-based user settings flow. Once initialized, the browser will be redirected to `selfservice.flows.settings.ui_url` with the flow ID set as the query parameter `?flow=`. If no valid ORY Kratos Session Cookie is included in the request, a login flow will be initialized. :::note This endpoint is NOT INTENDED for API clients and only works with browsers (Chrome, Firefox, ...). ::: More information can be found at [ORY Kratos User Settings & Profile Management Documentation](../self-service/flows/user-settings).
|
1366
|
+
# @param [Hash] opts the optional parameters
|
1367
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
1368
|
+
def initialize_self_service_settings_via_browser_flow_with_http_info(opts = {})
|
1369
|
+
if @api_client.config.debugging
|
1370
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.initialize_self_service_settings_via_browser_flow ...'
|
1371
|
+
end
|
1372
|
+
# resource path
|
1373
|
+
local_var_path = '/self-service/settings/browser/flows'
|
1374
|
+
|
1375
|
+
# query parameters
|
1376
|
+
query_params = opts[:query_params] || {}
|
1377
|
+
|
1378
|
+
# header parameters
|
1379
|
+
header_params = opts[:header_params] || {}
|
1380
|
+
# HTTP header 'Accept' (if needed)
|
1381
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1382
|
+
|
1383
|
+
# form parameters
|
1384
|
+
form_params = opts[:form_params] || {}
|
1385
|
+
|
1386
|
+
# http body (model)
|
1387
|
+
post_body = opts[:body]
|
1388
|
+
|
1389
|
+
# return_type
|
1390
|
+
return_type = opts[:return_type]
|
1391
|
+
|
1392
|
+
# auth_names
|
1393
|
+
auth_names = opts[:auth_names] || ['sessionToken']
|
1394
|
+
|
1395
|
+
new_options = opts.merge(
|
1396
|
+
:header_params => header_params,
|
1397
|
+
:query_params => query_params,
|
1398
|
+
:form_params => form_params,
|
1399
|
+
:body => post_body,
|
1400
|
+
:auth_names => auth_names,
|
1401
|
+
:return_type => return_type
|
1402
|
+
)
|
1403
|
+
|
1404
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
1405
|
+
if @api_client.config.debugging
|
1406
|
+
@api_client.config.logger.debug "API called: PublicApi#initialize_self_service_settings_via_browser_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1407
|
+
end
|
1408
|
+
return data, status_code, headers
|
1409
|
+
end
|
1410
|
+
|
1411
|
+
# Initialize Verification Flow for API Clients
|
1412
|
+
# This endpoint initiates a verification flow for API clients such as mobile devices, smart TVs, and so on. To fetch an existing verification flow call `/self-service/verification/flows?flow=<flow_id>`. :::warning You MUST NOT use this endpoint in client-side (Single Page Apps, ReactJS, AngularJS) nor server-side (Java Server Pages, NodeJS, PHP, Golang, ...) browser applications. Using this endpoint in these applications will make you vulnerable to a variety of CSRF attacks. This endpoint MUST ONLY be used in scenarios such as native mobile apps (React Native, Objective C, Swift, Java, ...). ::: More information can be found at [ORY Kratos Email and Phone Verification Documentation](https://www.ory.sh/docs/kratos/selfservice/flows/verify-email-account-activation).
|
1413
|
+
# @param [Hash] opts the optional parameters
|
1414
|
+
# @return [VerificationFlow]
|
1415
|
+
def initialize_self_service_verification_via_api_flow(opts = {})
|
1416
|
+
data, _status_code, _headers = initialize_self_service_verification_via_api_flow_with_http_info(opts)
|
1417
|
+
data
|
1418
|
+
end
|
1419
|
+
|
1420
|
+
# Initialize Verification Flow for API Clients
|
1421
|
+
# This endpoint initiates a verification flow for API clients such as mobile devices, smart TVs, and so on. To fetch an existing verification flow call `/self-service/verification/flows?flow=<flow_id>`. :::warning You MUST NOT use this endpoint in client-side (Single Page Apps, ReactJS, AngularJS) nor server-side (Java Server Pages, NodeJS, PHP, Golang, ...) browser applications. Using this endpoint in these applications will make you vulnerable to a variety of CSRF attacks. This endpoint MUST ONLY be used in scenarios such as native mobile apps (React Native, Objective C, Swift, Java, ...). ::: More information can be found at [ORY Kratos Email and Phone Verification Documentation](https://www.ory.sh/docs/kratos/selfservice/flows/verify-email-account-activation).
|
1422
|
+
# @param [Hash] opts the optional parameters
|
1423
|
+
# @return [Array<(VerificationFlow, Integer, Hash)>] VerificationFlow data, response status code and response headers
|
1424
|
+
def initialize_self_service_verification_via_api_flow_with_http_info(opts = {})
|
1425
|
+
if @api_client.config.debugging
|
1426
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.initialize_self_service_verification_via_api_flow ...'
|
1427
|
+
end
|
1428
|
+
# resource path
|
1429
|
+
local_var_path = '/self-service/verification/api'
|
1430
|
+
|
1431
|
+
# query parameters
|
1432
|
+
query_params = opts[:query_params] || {}
|
1433
|
+
|
1434
|
+
# header parameters
|
1435
|
+
header_params = opts[:header_params] || {}
|
1436
|
+
# HTTP header 'Accept' (if needed)
|
1437
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1438
|
+
|
1439
|
+
# form parameters
|
1440
|
+
form_params = opts[:form_params] || {}
|
1441
|
+
|
1442
|
+
# http body (model)
|
1443
|
+
post_body = opts[:body]
|
1444
|
+
|
1445
|
+
# return_type
|
1446
|
+
return_type = opts[:return_type] || 'VerificationFlow'
|
1447
|
+
|
1448
|
+
# auth_names
|
1449
|
+
auth_names = opts[:auth_names] || []
|
1450
|
+
|
1451
|
+
new_options = opts.merge(
|
1452
|
+
:header_params => header_params,
|
1453
|
+
:query_params => query_params,
|
1454
|
+
:form_params => form_params,
|
1455
|
+
:body => post_body,
|
1456
|
+
:auth_names => auth_names,
|
1457
|
+
:return_type => return_type
|
1458
|
+
)
|
1459
|
+
|
1460
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
1461
|
+
if @api_client.config.debugging
|
1462
|
+
@api_client.config.logger.debug "API called: PublicApi#initialize_self_service_verification_via_api_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1463
|
+
end
|
1464
|
+
return data, status_code, headers
|
1465
|
+
end
|
1466
|
+
|
1467
|
+
# Initialize Verification Flow for Browser Clients
|
1468
|
+
# This endpoint initializes a browser-based account verification flow. Once initialized, the browser will be redirected to `selfservice.flows.verification.ui_url` with the flow ID set as the query parameter `?flow=`. This endpoint is NOT INTENDED for API clients and only works with browsers (Chrome, Firefox, ...). More information can be found at [ORY Kratos Email and Phone Verification Documentation](https://www.ory.sh/docs/kratos/selfservice/flows/verify-email-account-activation).
|
1469
|
+
# @param [Hash] opts the optional parameters
|
1470
|
+
# @return [nil]
|
1471
|
+
def initialize_self_service_verification_via_browser_flow(opts = {})
|
1472
|
+
initialize_self_service_verification_via_browser_flow_with_http_info(opts)
|
1473
|
+
nil
|
1474
|
+
end
|
1475
|
+
|
1476
|
+
# Initialize Verification Flow for Browser Clients
|
1477
|
+
# This endpoint initializes a browser-based account verification flow. Once initialized, the browser will be redirected to `selfservice.flows.verification.ui_url` with the flow ID set as the query parameter `?flow=`. This endpoint is NOT INTENDED for API clients and only works with browsers (Chrome, Firefox, ...). More information can be found at [ORY Kratos Email and Phone Verification Documentation](https://www.ory.sh/docs/kratos/selfservice/flows/verify-email-account-activation).
|
1478
|
+
# @param [Hash] opts the optional parameters
|
1479
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
1480
|
+
def initialize_self_service_verification_via_browser_flow_with_http_info(opts = {})
|
1481
|
+
if @api_client.config.debugging
|
1482
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.initialize_self_service_verification_via_browser_flow ...'
|
1483
|
+
end
|
1484
|
+
# resource path
|
1485
|
+
local_var_path = '/self-service/verification/browser'
|
1486
|
+
|
1487
|
+
# query parameters
|
1488
|
+
query_params = opts[:query_params] || {}
|
1489
|
+
|
1490
|
+
# header parameters
|
1491
|
+
header_params = opts[:header_params] || {}
|
1492
|
+
# HTTP header 'Accept' (if needed)
|
1493
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1494
|
+
|
1495
|
+
# form parameters
|
1496
|
+
form_params = opts[:form_params] || {}
|
1497
|
+
|
1498
|
+
# http body (model)
|
1499
|
+
post_body = opts[:body]
|
1500
|
+
|
1501
|
+
# return_type
|
1502
|
+
return_type = opts[:return_type]
|
1503
|
+
|
1504
|
+
# auth_names
|
1505
|
+
auth_names = opts[:auth_names] || []
|
1506
|
+
|
1507
|
+
new_options = opts.merge(
|
1508
|
+
:header_params => header_params,
|
1509
|
+
:query_params => query_params,
|
1510
|
+
:form_params => form_params,
|
1511
|
+
:body => post_body,
|
1512
|
+
:auth_names => auth_names,
|
1513
|
+
:return_type => return_type
|
1514
|
+
)
|
1515
|
+
|
1516
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
1517
|
+
if @api_client.config.debugging
|
1518
|
+
@api_client.config.logger.debug "API called: PublicApi#initialize_self_service_verification_via_browser_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1519
|
+
end
|
1520
|
+
return data, status_code, headers
|
1521
|
+
end
|
1522
|
+
|
1523
|
+
# Revoke and Invalidate a Session
|
1524
|
+
# Use this endpoint to revoke a session using its token. This endpoint is particularly useful for API clients such as mobile apps to log the user out of the system and invalidate the session. This endpoint does not remove any HTTP Cookies - use the Self-Service Logout Flow instead.
|
1525
|
+
# @param body [RevokeSession]
|
1526
|
+
# @param [Hash] opts the optional parameters
|
1527
|
+
# @return [nil]
|
1528
|
+
def revoke_session(body, opts = {})
|
1529
|
+
revoke_session_with_http_info(body, opts)
|
1530
|
+
nil
|
1531
|
+
end
|
1532
|
+
|
1533
|
+
# Revoke and Invalidate a Session
|
1534
|
+
# Use this endpoint to revoke a session using its token. This endpoint is particularly useful for API clients such as mobile apps to log the user out of the system and invalidate the session. This endpoint does not remove any HTTP Cookies - use the Self-Service Logout Flow instead.
|
1535
|
+
# @param body [RevokeSession]
|
1536
|
+
# @param [Hash] opts the optional parameters
|
1537
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
1538
|
+
def revoke_session_with_http_info(body, opts = {})
|
1539
|
+
if @api_client.config.debugging
|
1540
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.revoke_session ...'
|
1541
|
+
end
|
1542
|
+
# verify the required parameter 'body' is set
|
1543
|
+
if @api_client.config.client_side_validation && body.nil?
|
1544
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling PublicApi.revoke_session"
|
1545
|
+
end
|
1546
|
+
# resource path
|
1547
|
+
local_var_path = '/sessions'
|
1548
|
+
|
1549
|
+
# query parameters
|
1550
|
+
query_params = opts[:query_params] || {}
|
1551
|
+
|
1552
|
+
# header parameters
|
1553
|
+
header_params = opts[:header_params] || {}
|
1554
|
+
# HTTP header 'Accept' (if needed)
|
1555
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1556
|
+
# HTTP header 'Content-Type'
|
1557
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
1558
|
+
|
1559
|
+
# form parameters
|
1560
|
+
form_params = opts[:form_params] || {}
|
1561
|
+
|
1562
|
+
# http body (model)
|
1563
|
+
post_body = opts[:body] || @api_client.object_to_http_body(body)
|
1564
|
+
|
1565
|
+
# return_type
|
1566
|
+
return_type = opts[:return_type]
|
1567
|
+
|
1568
|
+
# auth_names
|
1569
|
+
auth_names = opts[:auth_names] || []
|
1570
|
+
|
1571
|
+
new_options = opts.merge(
|
1572
|
+
:header_params => header_params,
|
1573
|
+
:query_params => query_params,
|
1574
|
+
:form_params => form_params,
|
1575
|
+
:body => post_body,
|
1576
|
+
:auth_names => auth_names,
|
1577
|
+
:return_type => return_type
|
1578
|
+
)
|
1579
|
+
|
1580
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
1581
|
+
if @api_client.config.debugging
|
1582
|
+
@api_client.config.logger.debug "API called: PublicApi#revoke_session\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1583
|
+
end
|
1584
|
+
return data, status_code, headers
|
1585
|
+
end
|
1586
|
+
|
1587
|
+
# Check Who the Current HTTP Session Belongs To
|
1588
|
+
# Uses the HTTP Headers in the GET request to determine (e.g. by using checking the cookies) who is authenticated. Returns a session object in the body or 401 if the credentials are invalid or no credentials were sent. Additionally when the request it successful it adds the user ID to the 'X-Kratos-Authenticated-Identity-Id' header in the response. This endpoint is useful for reverse proxies and API Gateways.
|
1589
|
+
# @param [Hash] opts the optional parameters
|
1590
|
+
# @option opts [String] :cookie
|
1591
|
+
# @option opts [String] :authorization in: authorization
|
1592
|
+
# @return [Session]
|
1593
|
+
def whoami(opts = {})
|
1594
|
+
data, _status_code, _headers = whoami_with_http_info(opts)
|
1595
|
+
data
|
1596
|
+
end
|
1597
|
+
|
1598
|
+
# Check Who the Current HTTP Session Belongs To
|
1599
|
+
# Uses the HTTP Headers in the GET request to determine (e.g. by using checking the cookies) who is authenticated. Returns a session object in the body or 401 if the credentials are invalid or no credentials were sent. Additionally when the request it successful it adds the user ID to the 'X-Kratos-Authenticated-Identity-Id' header in the response. This endpoint is useful for reverse proxies and API Gateways.
|
1600
|
+
# @param [Hash] opts the optional parameters
|
1601
|
+
# @option opts [String] :cookie
|
1602
|
+
# @option opts [String] :authorization in: authorization
|
1603
|
+
# @return [Array<(Session, Integer, Hash)>] Session data, response status code and response headers
|
1604
|
+
def whoami_with_http_info(opts = {})
|
1605
|
+
if @api_client.config.debugging
|
1606
|
+
@api_client.config.logger.debug 'Calling API: PublicApi.whoami ...'
|
1607
|
+
end
|
1608
|
+
# resource path
|
1609
|
+
local_var_path = '/sessions/whoami'
|
1610
|
+
|
1611
|
+
# query parameters
|
1612
|
+
query_params = opts[:query_params] || {}
|
1613
|
+
query_params[:'Authorization'] = opts[:'authorization'] if !opts[:'authorization'].nil?
|
1614
|
+
|
1615
|
+
# header parameters
|
1616
|
+
header_params = opts[:header_params] || {}
|
1617
|
+
# HTTP header 'Accept' (if needed)
|
1618
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1619
|
+
header_params[:'Cookie'] = opts[:'cookie'] if !opts[:'cookie'].nil?
|
1620
|
+
|
1621
|
+
# form parameters
|
1622
|
+
form_params = opts[:form_params] || {}
|
1623
|
+
|
1624
|
+
# http body (model)
|
1625
|
+
post_body = opts[:body]
|
1626
|
+
|
1627
|
+
# return_type
|
1628
|
+
return_type = opts[:return_type] || 'Session'
|
1629
|
+
|
1630
|
+
# auth_names
|
1631
|
+
auth_names = opts[:auth_names] || ['sessionToken']
|
1632
|
+
|
1633
|
+
new_options = opts.merge(
|
1634
|
+
:header_params => header_params,
|
1635
|
+
:query_params => query_params,
|
1636
|
+
:form_params => form_params,
|
1637
|
+
:body => post_body,
|
1638
|
+
:auth_names => auth_names,
|
1639
|
+
:return_type => return_type
|
1640
|
+
)
|
1641
|
+
|
992
1642
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
993
1643
|
if @api_client.config.debugging
|
994
1644
|
@api_client.config.logger.debug "API called: PublicApi#whoami\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|