zitadel-client 1.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/LICENSE +201 -0
- data/README.md +248 -0
- data/lib/patch.rb +26 -0
- data/lib/zitadel-client/api/.openapi +0 -0
- data/lib/zitadel-client/api/feature_service_api.rb +783 -0
- data/lib/zitadel-client/api/identity_provider_service_api.rb +85 -0
- data/lib/zitadel-client/api/o_i_d_c_service_api.rb +296 -0
- data/lib/zitadel-client/api/organization_service_api.rb +158 -0
- data/lib/zitadel-client/api/s_a_m_l_service_api.rb +159 -0
- data/lib/zitadel-client/api/session_service_api.rb +372 -0
- data/lib/zitadel-client/api/settings_api.rb +147 -0
- data/lib/zitadel-client/api/settings_service_api.rb +595 -0
- data/lib/zitadel-client/api/user_service_api.rb +3210 -0
- data/lib/zitadel-client/api_client.rb +376 -0
- data/lib/zitadel-client/api_error.rb +29 -0
- data/lib/zitadel-client/auth/authenticator.rb +76 -0
- data/lib/zitadel-client/auth/client_credentials_authenticator.rb +63 -0
- data/lib/zitadel-client/auth/no_auth_authenticator.rb +31 -0
- data/lib/zitadel-client/auth/o_auth_authenticator.rb +90 -0
- data/lib/zitadel-client/auth/open_id.rb +50 -0
- data/lib/zitadel-client/auth/personal_access_token_authenticator.rb +33 -0
- data/lib/zitadel-client/auth/web_token_authenticator.rb +159 -0
- data/lib/zitadel-client/configuration.rb +178 -0
- data/lib/zitadel-client/models/.openapi +0 -0
- data/lib/zitadel-client/models/feature_service_details.rb +249 -0
- data/lib/zitadel-client/models/feature_service_feature_flag.rb +255 -0
- data/lib/zitadel-client/models/feature_service_get_instance_features_response.rb +355 -0
- data/lib/zitadel-client/models/feature_service_get_organization_features_response.rb +220 -0
- data/lib/zitadel-client/models/feature_service_get_system_features_response.rb +328 -0
- data/lib/zitadel-client/models/feature_service_get_user_features_response.rb +220 -0
- data/lib/zitadel-client/models/feature_service_improved_performance.rb +44 -0
- data/lib/zitadel-client/models/feature_service_improved_performance_feature_flag.rb +256 -0
- data/lib/zitadel-client/models/feature_service_login_v2.rb +231 -0
- data/lib/zitadel-client/models/feature_service_login_v2_feature_flag.rb +262 -0
- data/lib/zitadel-client/models/feature_service_protobuf_any.rb +220 -0
- data/lib/zitadel-client/models/feature_service_reset_instance_features_response.rb +220 -0
- data/lib/zitadel-client/models/feature_service_reset_organization_features_response.rb +220 -0
- data/lib/zitadel-client/models/feature_service_reset_system_features_response.rb +220 -0
- data/lib/zitadel-client/models/feature_service_reset_user_features_response.rb +220 -0
- data/lib/zitadel-client/models/feature_service_rpc_status.rb +240 -0
- data/lib/zitadel-client/models/feature_service_set_instance_features_request.rb +362 -0
- data/lib/zitadel-client/models/feature_service_set_instance_features_response.rb +220 -0
- data/lib/zitadel-client/models/feature_service_set_organization_features_response.rb +220 -0
- data/lib/zitadel-client/models/feature_service_set_system_features_request.rb +332 -0
- data/lib/zitadel-client/models/feature_service_set_system_features_response.rb +220 -0
- data/lib/zitadel-client/models/feature_service_set_user_features_response.rb +220 -0
- data/lib/zitadel-client/models/feature_service_source.rb +45 -0
- data/lib/zitadel-client/models/identity_provider_service_apple_config.rb +253 -0
- data/lib/zitadel-client/models/identity_provider_service_auto_linking_option.rb +41 -0
- data/lib/zitadel-client/models/identity_provider_service_azure_a_d_config.rb +251 -0
- data/lib/zitadel-client/models/identity_provider_service_azure_a_d_tenant.rb +231 -0
- data/lib/zitadel-client/models/identity_provider_service_azure_a_d_tenant_type.rb +41 -0
- data/lib/zitadel-client/models/identity_provider_service_details.rb +249 -0
- data/lib/zitadel-client/models/identity_provider_service_generic_o_i_d_c_config.rb +253 -0
- data/lib/zitadel-client/models/identity_provider_service_get_i_d_p_by_i_d_response.rb +220 -0
- data/lib/zitadel-client/models/identity_provider_service_git_hub_config.rb +233 -0
- data/lib/zitadel-client/models/identity_provider_service_git_hub_enterprise_server_config.rb +260 -0
- data/lib/zitadel-client/models/identity_provider_service_git_lab_config.rb +233 -0
- data/lib/zitadel-client/models/identity_provider_service_git_lab_self_hosted_config.rb +242 -0
- data/lib/zitadel-client/models/identity_provider_service_google_config.rb +233 -0
- data/lib/zitadel-client/models/identity_provider_service_i_d_p.rb +292 -0
- data/lib/zitadel-client/models/identity_provider_service_i_d_p_config.rb +328 -0
- data/lib/zitadel-client/models/identity_provider_service_i_d_p_state.rb +43 -0
- data/lib/zitadel-client/models/identity_provider_service_i_d_p_type.rb +51 -0
- data/lib/zitadel-client/models/identity_provider_service_j_w_t_config.rb +251 -0
- data/lib/zitadel-client/models/identity_provider_service_l_d_a_p_attributes.rb +337 -0
- data/lib/zitadel-client/models/identity_provider_service_l_d_a_p_config.rb +307 -0
- data/lib/zitadel-client/models/identity_provider_service_o_auth_config.rb +273 -0
- data/lib/zitadel-client/models/identity_provider_service_options.rb +284 -0
- data/lib/zitadel-client/models/identity_provider_service_protobuf_any.rb +220 -0
- data/lib/zitadel-client/models/identity_provider_service_rpc_status.rb +240 -0
- data/lib/zitadel-client/models/identity_provider_service_s_a_m_l_binding.rb +42 -0
- data/lib/zitadel-client/models/identity_provider_service_s_a_m_l_config.rb +285 -0
- data/lib/zitadel-client/models/identity_provider_service_s_a_m_l_name_i_d_format.rb +42 -0
- data/lib/zitadel-client/models/o_i_d_c_service_auth_request.rb +317 -0
- data/lib/zitadel-client/models/o_i_d_c_service_authorization_error.rb +262 -0
- data/lib/zitadel-client/models/o_i_d_c_service_authorize_or_deny_device_authorization_request.rb +229 -0
- data/lib/zitadel-client/models/o_i_d_c_service_create_callback_request.rb +229 -0
- data/lib/zitadel-client/models/o_i_d_c_service_create_callback_response.rb +230 -0
- data/lib/zitadel-client/models/o_i_d_c_service_details.rb +249 -0
- data/lib/zitadel-client/models/o_i_d_c_service_device_authorization_request.rb +263 -0
- data/lib/zitadel-client/models/o_i_d_c_service_error_reason.rb +55 -0
- data/lib/zitadel-client/models/o_i_d_c_service_get_auth_request_response.rb +220 -0
- data/lib/zitadel-client/models/o_i_d_c_service_get_device_authorization_request_response.rb +220 -0
- data/lib/zitadel-client/models/o_i_d_c_service_prompt.rb +44 -0
- data/lib/zitadel-client/models/o_i_d_c_service_protobuf_any.rb +220 -0
- data/lib/zitadel-client/models/o_i_d_c_service_rpc_status.rb +240 -0
- data/lib/zitadel-client/models/o_i_d_c_service_session.rb +287 -0
- data/lib/zitadel-client/models/organization_service_add_human_user_request.rb +435 -0
- data/lib/zitadel-client/models/organization_service_add_organization_request.rb +266 -0
- data/lib/zitadel-client/models/organization_service_add_organization_request_admin.rb +240 -0
- data/lib/zitadel-client/models/organization_service_add_organization_response.rb +240 -0
- data/lib/zitadel-client/models/organization_service_add_organization_response_created_admin.rb +238 -0
- data/lib/zitadel-client/models/organization_service_details.rb +249 -0
- data/lib/zitadel-client/models/organization_service_gender.rb +42 -0
- data/lib/zitadel-client/models/organization_service_hashed_password.rb +265 -0
- data/lib/zitadel-client/models/organization_service_i_d_p_link.rb +325 -0
- data/lib/zitadel-client/models/organization_service_list_details.rb +239 -0
- data/lib/zitadel-client/models/organization_service_list_organizations_request.rb +264 -0
- data/lib/zitadel-client/models/organization_service_list_organizations_response.rb +264 -0
- data/lib/zitadel-client/models/organization_service_list_query.rb +241 -0
- data/lib/zitadel-client/models/organization_service_organization_domain_query.rb +289 -0
- data/lib/zitadel-client/models/organization_service_organization_field_name.rb +40 -0
- data/lib/zitadel-client/models/organization_service_organization_i_d_query.rb +256 -0
- data/lib/zitadel-client/models/organization_service_organization_name_query.rb +289 -0
- data/lib/zitadel-client/models/organization_service_organization_state.rb +42 -0
- data/lib/zitadel-client/models/organization_service_organization_state_query.rb +244 -0
- data/lib/zitadel-client/models/organization_service_password.rb +264 -0
- data/lib/zitadel-client/models/organization_service_protobuf_any.rb +220 -0
- data/lib/zitadel-client/models/organization_service_rpc_status.rb +240 -0
- data/lib/zitadel-client/models/organization_service_search_query.rb +256 -0
- data/lib/zitadel-client/models/organization_service_send_email_verification_code.rb +249 -0
- data/lib/zitadel-client/models/organization_service_set_human_email.rb +282 -0
- data/lib/zitadel-client/models/organization_service_set_human_phone.rb +266 -0
- data/lib/zitadel-client/models/organization_service_set_human_profile.rb +416 -0
- data/lib/zitadel-client/models/organization_service_set_metadata_entry.rb +300 -0
- data/lib/zitadel-client/models/organization_service_text_query_method.rb +46 -0
- data/lib/zitadel-client/models/s_a_m_l_service_authorization_error.rb +253 -0
- data/lib/zitadel-client/models/s_a_m_l_service_create_response_request.rb +229 -0
- data/lib/zitadel-client/models/s_a_m_l_service_create_response_response.rb +248 -0
- data/lib/zitadel-client/models/s_a_m_l_service_details.rb +249 -0
- data/lib/zitadel-client/models/s_a_m_l_service_error_reason.rb +46 -0
- data/lib/zitadel-client/models/s_a_m_l_service_get_s_a_m_l_request_response.rb +220 -0
- data/lib/zitadel-client/models/s_a_m_l_service_post_response.rb +229 -0
- data/lib/zitadel-client/models/s_a_m_l_service_protobuf_any.rb +220 -0
- data/lib/zitadel-client/models/s_a_m_l_service_rpc_status.rb +240 -0
- data/lib/zitadel-client/models/s_a_m_l_service_s_a_m_l_request.rb +271 -0
- data/lib/zitadel-client/models/s_a_m_l_service_session.rb +287 -0
- data/lib/zitadel-client/models/session_service_challenges.rb +238 -0
- data/lib/zitadel-client/models/session_service_challenges_web_auth_n.rb +221 -0
- data/lib/zitadel-client/models/session_service_check_i_d_p_intent.rb +287 -0
- data/lib/zitadel-client/models/session_service_check_o_t_p.rb +239 -0
- data/lib/zitadel-client/models/session_service_check_password.rb +248 -0
- data/lib/zitadel-client/models/session_service_check_t_o_t_p.rb +248 -0
- data/lib/zitadel-client/models/session_service_check_user.rb +285 -0
- data/lib/zitadel-client/models/session_service_check_web_auth_n.rb +238 -0
- data/lib/zitadel-client/models/session_service_checks.rb +274 -0
- data/lib/zitadel-client/models/session_service_create_session_request.rb +260 -0
- data/lib/zitadel-client/models/session_service_create_session_response.rb +249 -0
- data/lib/zitadel-client/models/session_service_creation_date_query.rb +253 -0
- data/lib/zitadel-client/models/session_service_creator_query.rb +240 -0
- data/lib/zitadel-client/models/session_service_delete_session_request.rb +221 -0
- data/lib/zitadel-client/models/session_service_delete_session_response.rb +220 -0
- data/lib/zitadel-client/models/session_service_details.rb +249 -0
- data/lib/zitadel-client/models/session_service_factors.rb +274 -0
- data/lib/zitadel-client/models/session_service_get_session_response.rb +220 -0
- data/lib/zitadel-client/models/session_service_i_ds_query.rb +222 -0
- data/lib/zitadel-client/models/session_service_intent_factor.rb +221 -0
- data/lib/zitadel-client/models/session_service_list_details.rb +239 -0
- data/lib/zitadel-client/models/session_service_list_query.rb +241 -0
- data/lib/zitadel-client/models/session_service_list_sessions_request.rb +264 -0
- data/lib/zitadel-client/models/session_service_list_sessions_response.rb +231 -0
- data/lib/zitadel-client/models/session_service_o_t_p_email_send_code.rb +249 -0
- data/lib/zitadel-client/models/session_service_o_t_p_factor.rb +221 -0
- data/lib/zitadel-client/models/session_service_password_factor.rb +221 -0
- data/lib/zitadel-client/models/session_service_protobuf_any.rb +220 -0
- data/lib/zitadel-client/models/session_service_request_challenges.rb +238 -0
- data/lib/zitadel-client/models/session_service_request_challenges_o_t_p_email.rb +229 -0
- data/lib/zitadel-client/models/session_service_request_challenges_o_t_p_s_m_s.rb +220 -0
- data/lib/zitadel-client/models/session_service_request_challenges_web_auth_n.rb +286 -0
- data/lib/zitadel-client/models/session_service_rpc_status.rb +240 -0
- data/lib/zitadel-client/models/session_service_search_query.rb +256 -0
- data/lib/zitadel-client/models/session_service_session.rb +291 -0
- data/lib/zitadel-client/models/session_service_session_field_name.rb +40 -0
- data/lib/zitadel-client/models/session_service_set_session_request.rb +289 -0
- data/lib/zitadel-client/models/session_service_set_session_response.rb +239 -0
- data/lib/zitadel-client/models/session_service_t_o_t_p_factor.rb +221 -0
- data/lib/zitadel-client/models/session_service_timestamp_query_method.rb +43 -0
- data/lib/zitadel-client/models/session_service_user_agent.rb +249 -0
- data/lib/zitadel-client/models/session_service_user_agent_header_values.rb +223 -0
- data/lib/zitadel-client/models/session_service_user_agent_query.rb +240 -0
- data/lib/zitadel-client/models/session_service_user_factor.rb +261 -0
- data/lib/zitadel-client/models/session_service_user_i_d_query.rb +220 -0
- data/lib/zitadel-client/models/session_service_user_verification_requirement.rb +42 -0
- data/lib/zitadel-client/models/session_service_web_auth_n_factor.rb +230 -0
- data/lib/zitadel-client/models/settings_service_auto_linking_option.rb +41 -0
- data/lib/zitadel-client/models/settings_service_branding_settings.rb +303 -0
- data/lib/zitadel-client/models/settings_service_details.rb +249 -0
- data/lib/zitadel-client/models/settings_service_domain_settings.rb +274 -0
- data/lib/zitadel-client/models/settings_service_embedded_iframe_settings.rb +233 -0
- data/lib/zitadel-client/models/settings_service_get_active_identity_providers_response.rb +231 -0
- data/lib/zitadel-client/models/settings_service_get_branding_settings_response.rb +229 -0
- data/lib/zitadel-client/models/settings_service_get_domain_settings_response.rb +229 -0
- data/lib/zitadel-client/models/settings_service_get_general_settings_response.rb +242 -0
- data/lib/zitadel-client/models/settings_service_get_legal_and_support_settings_response.rb +229 -0
- data/lib/zitadel-client/models/settings_service_get_lockout_settings_response.rb +229 -0
- data/lib/zitadel-client/models/settings_service_get_login_settings_response.rb +229 -0
- data/lib/zitadel-client/models/settings_service_get_password_complexity_settings_response.rb +229 -0
- data/lib/zitadel-client/models/settings_service_get_password_expiry_settings_response.rb +229 -0
- data/lib/zitadel-client/models/settings_service_get_security_settings_response.rb +229 -0
- data/lib/zitadel-client/models/settings_service_identity_provider.rb +271 -0
- data/lib/zitadel-client/models/settings_service_identity_provider_type.rb +51 -0
- data/lib/zitadel-client/models/settings_service_legal_and_support_settings.rb +311 -0
- data/lib/zitadel-client/models/settings_service_list_details.rb +239 -0
- data/lib/zitadel-client/models/settings_service_lockout_settings.rb +264 -0
- data/lib/zitadel-client/models/settings_service_login_settings.rb +437 -0
- data/lib/zitadel-client/models/settings_service_multi_factor_type.rb +40 -0
- data/lib/zitadel-client/models/settings_service_options.rb +284 -0
- data/lib/zitadel-client/models/settings_service_passkeys_type.rb +40 -0
- data/lib/zitadel-client/models/settings_service_password_complexity_settings.rb +294 -0
- data/lib/zitadel-client/models/settings_service_password_expiry_settings.rb +264 -0
- data/lib/zitadel-client/models/settings_service_protobuf_any.rb +220 -0
- data/lib/zitadel-client/models/settings_service_resource_owner_type.rb +41 -0
- data/lib/zitadel-client/models/settings_service_rpc_status.rb +240 -0
- data/lib/zitadel-client/models/settings_service_second_factor_type.rb +43 -0
- data/lib/zitadel-client/models/settings_service_security_settings.rb +230 -0
- data/lib/zitadel-client/models/settings_service_set_security_settings_request.rb +230 -0
- data/lib/zitadel-client/models/settings_service_set_security_settings_response.rb +220 -0
- data/lib/zitadel-client/models/settings_service_theme.rb +271 -0
- data/lib/zitadel-client/models/settings_service_theme_mode.rb +42 -0
- data/lib/zitadel-client/models/user_service_access_token_type.rb +40 -0
- data/lib/zitadel-client/models/user_service_add_human_user_request.rb +435 -0
- data/lib/zitadel-client/models/user_service_add_human_user_response.rb +247 -0
- data/lib/zitadel-client/models/user_service_add_i_d_p_link_request.rb +220 -0
- data/lib/zitadel-client/models/user_service_add_i_d_p_link_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_add_o_t_p_email_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_add_o_t_p_s_m_s_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_and_query.rb +224 -0
- data/lib/zitadel-client/models/user_service_auth_factor.rb +258 -0
- data/lib/zitadel-client/models/user_service_auth_factor_state.rb +42 -0
- data/lib/zitadel-client/models/user_service_auth_factor_u2_f.rb +229 -0
- data/lib/zitadel-client/models/user_service_authentication_method_type.rb +46 -0
- data/lib/zitadel-client/models/user_service_create_invite_code_request.rb +229 -0
- data/lib/zitadel-client/models/user_service_create_invite_code_response.rb +230 -0
- data/lib/zitadel-client/models/user_service_create_passkey_registration_link_request.rb +229 -0
- data/lib/zitadel-client/models/user_service_create_passkey_registration_link_response.rb +229 -0
- data/lib/zitadel-client/models/user_service_deactivate_user_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_delete_user_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_details.rb +249 -0
- data/lib/zitadel-client/models/user_service_display_name_query.rb +289 -0
- data/lib/zitadel-client/models/user_service_email_query.rb +281 -0
- data/lib/zitadel-client/models/user_service_first_name_query.rb +289 -0
- data/lib/zitadel-client/models/user_service_gender.rb +42 -0
- data/lib/zitadel-client/models/user_service_get_user_by_i_d_response.rb +229 -0
- data/lib/zitadel-client/models/user_service_hashed_password.rb +265 -0
- data/lib/zitadel-client/models/user_service_human_email.rb +257 -0
- data/lib/zitadel-client/models/user_service_human_m_f_a_init_skipped_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_human_phone.rb +248 -0
- data/lib/zitadel-client/models/user_service_human_profile.rb +412 -0
- data/lib/zitadel-client/models/user_service_human_user.rb +343 -0
- data/lib/zitadel-client/models/user_service_i_d_p_information.rb +278 -0
- data/lib/zitadel-client/models/user_service_i_d_p_intent.rb +316 -0
- data/lib/zitadel-client/models/user_service_i_d_p_l_d_a_p_access_information.rb +220 -0
- data/lib/zitadel-client/models/user_service_i_d_p_link.rb +325 -0
- data/lib/zitadel-client/models/user_service_i_d_p_o_auth_access_information.rb +229 -0
- data/lib/zitadel-client/models/user_service_i_d_p_s_a_m_l_access_information.rb +220 -0
- data/lib/zitadel-client/models/user_service_in_user_emails_query.rb +224 -0
- data/lib/zitadel-client/models/user_service_in_user_i_d_query.rb +224 -0
- data/lib/zitadel-client/models/user_service_l_d_a_p_credentials.rb +287 -0
- data/lib/zitadel-client/models/user_service_last_name_query.rb +289 -0
- data/lib/zitadel-client/models/user_service_list_authentication_factors_response.rb +222 -0
- data/lib/zitadel-client/models/user_service_list_authentication_method_types_response.rb +231 -0
- data/lib/zitadel-client/models/user_service_list_details.rb +239 -0
- data/lib/zitadel-client/models/user_service_list_i_d_p_links_request.rb +220 -0
- data/lib/zitadel-client/models/user_service_list_i_d_p_links_response.rb +231 -0
- data/lib/zitadel-client/models/user_service_list_passkeys_response.rb +231 -0
- data/lib/zitadel-client/models/user_service_list_query.rb +241 -0
- data/lib/zitadel-client/models/user_service_list_users_request.rb +264 -0
- data/lib/zitadel-client/models/user_service_list_users_response.rb +264 -0
- data/lib/zitadel-client/models/user_service_lock_user_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_login_name_query.rb +289 -0
- data/lib/zitadel-client/models/user_service_machine_user.rb +271 -0
- data/lib/zitadel-client/models/user_service_nick_name_query.rb +289 -0
- data/lib/zitadel-client/models/user_service_not_query.rb +221 -0
- data/lib/zitadel-client/models/user_service_notification_type.rb +41 -0
- data/lib/zitadel-client/models/user_service_or_query.rb +224 -0
- data/lib/zitadel-client/models/user_service_organization.rb +229 -0
- data/lib/zitadel-client/models/user_service_organization_id_query.rb +256 -0
- data/lib/zitadel-client/models/user_service_passkey.rb +290 -0
- data/lib/zitadel-client/models/user_service_passkey_authenticator.rb +41 -0
- data/lib/zitadel-client/models/user_service_passkey_registration_code.rb +283 -0
- data/lib/zitadel-client/models/user_service_password.rb +264 -0
- data/lib/zitadel-client/models/user_service_password_reset_request.rb +229 -0
- data/lib/zitadel-client/models/user_service_password_reset_response.rb +229 -0
- data/lib/zitadel-client/models/user_service_phone_query.rb +290 -0
- data/lib/zitadel-client/models/user_service_protobuf_any.rb +220 -0
- data/lib/zitadel-client/models/user_service_reactivate_user_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_redirect_u_r_ls.rb +287 -0
- data/lib/zitadel-client/models/user_service_register_passkey_request.rb +263 -0
- data/lib/zitadel-client/models/user_service_register_passkey_response.rb +239 -0
- data/lib/zitadel-client/models/user_service_register_t_o_t_p_response.rb +238 -0
- data/lib/zitadel-client/models/user_service_register_u2_f_request.rb +221 -0
- data/lib/zitadel-client/models/user_service_register_u2_f_response.rb +239 -0
- data/lib/zitadel-client/models/user_service_remove_i_d_p_link_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_remove_o_t_p_email_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_remove_o_t_p_s_m_s_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_remove_passkey_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_remove_phone_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_remove_t_o_t_p_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_remove_u2_f_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_resend_email_code_request.rb +229 -0
- data/lib/zitadel-client/models/user_service_resend_email_code_response.rb +229 -0
- data/lib/zitadel-client/models/user_service_resend_invite_code_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_resend_phone_code_request.rb +229 -0
- data/lib/zitadel-client/models/user_service_resend_phone_code_response.rb +229 -0
- data/lib/zitadel-client/models/user_service_retrieve_identity_provider_intent_request.rb +249 -0
- data/lib/zitadel-client/models/user_service_retrieve_identity_provider_intent_response.rb +248 -0
- data/lib/zitadel-client/models/user_service_rpc_status.rb +240 -0
- data/lib/zitadel-client/models/user_service_search_query.rb +355 -0
- data/lib/zitadel-client/models/user_service_send_email_code_request.rb +229 -0
- data/lib/zitadel-client/models/user_service_send_email_code_response.rb +229 -0
- data/lib/zitadel-client/models/user_service_send_email_verification_code.rb +249 -0
- data/lib/zitadel-client/models/user_service_send_invite_code.rb +287 -0
- data/lib/zitadel-client/models/user_service_send_passkey_registration_link.rb +249 -0
- data/lib/zitadel-client/models/user_service_send_password_reset_link.rb +282 -0
- data/lib/zitadel-client/models/user_service_set_email_request.rb +282 -0
- data/lib/zitadel-client/models/user_service_set_email_response.rb +229 -0
- data/lib/zitadel-client/models/user_service_set_human_email.rb +282 -0
- data/lib/zitadel-client/models/user_service_set_human_phone.rb +266 -0
- data/lib/zitadel-client/models/user_service_set_human_profile.rb +416 -0
- data/lib/zitadel-client/models/user_service_set_metadata_entry.rb +300 -0
- data/lib/zitadel-client/models/user_service_set_password.rb +318 -0
- data/lib/zitadel-client/models/user_service_set_password_request.rb +309 -0
- data/lib/zitadel-client/models/user_service_set_password_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_set_phone_request.rb +282 -0
- data/lib/zitadel-client/models/user_service_set_phone_response.rb +229 -0
- data/lib/zitadel-client/models/user_service_start_identity_provider_intent_request.rb +267 -0
- data/lib/zitadel-client/models/user_service_start_identity_provider_intent_response.rb +249 -0
- data/lib/zitadel-client/models/user_service_state_query.rb +260 -0
- data/lib/zitadel-client/models/user_service_text_query_method.rb +46 -0
- data/lib/zitadel-client/models/user_service_type.rb +41 -0
- data/lib/zitadel-client/models/user_service_type_query.rb +260 -0
- data/lib/zitadel-client/models/user_service_unlock_user_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_update_human_user_request.rb +284 -0
- data/lib/zitadel-client/models/user_service_update_human_user_response.rb +238 -0
- data/lib/zitadel-client/models/user_service_user.rb +287 -0
- data/lib/zitadel-client/models/user_service_user_field_name.rb +48 -0
- data/lib/zitadel-client/models/user_service_user_name_query.rb +289 -0
- data/lib/zitadel-client/models/user_service_user_state.rb +44 -0
- data/lib/zitadel-client/models/user_service_verify_email_request.rb +256 -0
- data/lib/zitadel-client/models/user_service_verify_email_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_verify_invite_code_request.rb +256 -0
- data/lib/zitadel-client/models/user_service_verify_invite_code_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_verify_passkey_registration_request.rb +282 -0
- data/lib/zitadel-client/models/user_service_verify_passkey_registration_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_verify_phone_request.rb +256 -0
- data/lib/zitadel-client/models/user_service_verify_phone_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_verify_t_o_t_p_registration_request.rb +238 -0
- data/lib/zitadel-client/models/user_service_verify_t_o_t_p_registration_response.rb +220 -0
- data/lib/zitadel-client/models/user_service_verify_u2_f_registration_request.rb +282 -0
- data/lib/zitadel-client/models/user_service_verify_u2_f_registration_response.rb +220 -0
- data/lib/zitadel-client/models/zitadelobjectv2_organization.rb +229 -0
- data/lib/zitadel-client/models/zitadelorgv2_organization.rb +283 -0
- data/lib/zitadel-client/utils/url_util.rb +21 -0
- data/lib/zitadel-client/version.rb +5 -0
- data/lib/zitadel-client/zitadel.rb +82 -0
- data/lib/zitadel-client/zitadel_error.rb +8 -0
- data/lib/zitadel_client.rb +33 -0
- data/sig/lib/oauth2/oauth2.rbs +101 -0
- data/sig/lib/openssl/openssl.rbs +10 -0
- data/sig/lib/typhoeus/typhoeus.rbs +387 -0
- data/sig/lib/warning/warning.rbs +3 -0
- data/sig/lib/zeitwerk/zeitwerk.rbs +21 -0
- data/sig/lib.rbs +284 -0
- metadata +461 -0
@@ -0,0 +1,3210 @@
|
|
1
|
+
=begin
|
2
|
+
#Zitadel SDK
|
3
|
+
|
4
|
+
#The Zitadel SDK is a convenience wrapper around the Zitadel APIs to assist you in integrating with your Zitadel environment. This SDK enables you to handle resources, settings, and configurations within the Zitadel platform.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
Generator version: 7.12.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'cgi'
|
14
|
+
|
15
|
+
module ZitadelClient
|
16
|
+
class UserServiceApi
|
17
|
+
attr_accessor :api_client
|
18
|
+
|
19
|
+
def initialize(api_client = ApiClient.default)
|
20
|
+
@api_client = api_client
|
21
|
+
end
|
22
|
+
# Create a new human user
|
23
|
+
# Create/import a new user with the type human. The newly created user will get a verification email if either the email address is not marked as verified and you did not request the verification to be returned.
|
24
|
+
# @param user_service_add_human_user_request [UserServiceAddHumanUserRequest]
|
25
|
+
# @param [Hash] opts the optional parameters
|
26
|
+
# @return [UserServiceAddHumanUserResponse]
|
27
|
+
def user_service_add_human_user(user_service_add_human_user_request, opts = {})
|
28
|
+
data, _status_code, _headers = user_service_add_human_user_with_http_info(user_service_add_human_user_request, opts)
|
29
|
+
data
|
30
|
+
end
|
31
|
+
|
32
|
+
# Create a new human user
|
33
|
+
# Create/import a new user with the type human. The newly created user will get a verification email if either the email address is not marked as verified and you did not request the verification to be returned.
|
34
|
+
# @param user_service_add_human_user_request [UserServiceAddHumanUserRequest]
|
35
|
+
# @param [Hash] opts the optional parameters
|
36
|
+
# @return [Array<(UserServiceAddHumanUserResponse, Integer, Hash)>] UserServiceAddHumanUserResponse data, response status code and response headers
|
37
|
+
def user_service_add_human_user_with_http_info(user_service_add_human_user_request, opts = {})
|
38
|
+
if @api_client.config.debugging
|
39
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_add_human_user ...'
|
40
|
+
end
|
41
|
+
# verify the required parameter 'user_service_add_human_user_request' is set
|
42
|
+
if @api_client.config.client_side_validation && user_service_add_human_user_request.nil?
|
43
|
+
fail ArgumentError, "Missing the required parameter 'user_service_add_human_user_request' when calling UserServiceApi.user_service_add_human_user"
|
44
|
+
end
|
45
|
+
# resource path
|
46
|
+
local_var_path = '/v2/users/human'
|
47
|
+
|
48
|
+
# query parameters
|
49
|
+
query_params = opts[:query_params] || {}
|
50
|
+
|
51
|
+
# header parameters
|
52
|
+
header_params = opts[:header_params] || {}
|
53
|
+
# HTTP header 'Accept' (if needed)
|
54
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
55
|
+
# HTTP header 'Content-Type'
|
56
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
57
|
+
if !content_type.nil?
|
58
|
+
header_params['Content-Type'] = content_type
|
59
|
+
end
|
60
|
+
|
61
|
+
# form parameters
|
62
|
+
form_params = opts[:form_params] || {}
|
63
|
+
|
64
|
+
# http body (model)
|
65
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_add_human_user_request)
|
66
|
+
|
67
|
+
# return_type
|
68
|
+
return_type = opts[:debug_return_type] || 'UserServiceAddHumanUserResponse'
|
69
|
+
|
70
|
+
# auth_names
|
71
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
72
|
+
|
73
|
+
new_options = opts.merge(
|
74
|
+
:operation => :"UserServiceApi.user_service_add_human_user",
|
75
|
+
:header_params => header_params,
|
76
|
+
:query_params => query_params,
|
77
|
+
:form_params => form_params,
|
78
|
+
:body => post_body,
|
79
|
+
:auth_names => auth_names,
|
80
|
+
:return_type => return_type
|
81
|
+
)
|
82
|
+
|
83
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
84
|
+
if @api_client.config.debugging
|
85
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_add_human_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
86
|
+
end
|
87
|
+
return data, status_code, headers
|
88
|
+
end
|
89
|
+
|
90
|
+
# Add link to an identity provider to an user
|
91
|
+
# Add link to an identity provider to an user..
|
92
|
+
# @param user_id [String]
|
93
|
+
# @param user_service_add_idp_link_request [UserServiceAddIDPLinkRequest]
|
94
|
+
# @param [Hash] opts the optional parameters
|
95
|
+
# @return [UserServiceAddIDPLinkResponse]
|
96
|
+
def user_service_add_idp_link(user_id, user_service_add_idp_link_request, opts = {})
|
97
|
+
data, _status_code, _headers = user_service_add_idp_link_with_http_info(user_id, user_service_add_idp_link_request, opts)
|
98
|
+
data
|
99
|
+
end
|
100
|
+
|
101
|
+
# Add link to an identity provider to an user
|
102
|
+
# Add link to an identity provider to an user..
|
103
|
+
# @param user_id [String]
|
104
|
+
# @param user_service_add_idp_link_request [UserServiceAddIDPLinkRequest]
|
105
|
+
# @param [Hash] opts the optional parameters
|
106
|
+
# @return [Array<(UserServiceAddIDPLinkResponse, Integer, Hash)>] UserServiceAddIDPLinkResponse data, response status code and response headers
|
107
|
+
def user_service_add_idp_link_with_http_info(user_id, user_service_add_idp_link_request, opts = {})
|
108
|
+
if @api_client.config.debugging
|
109
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_add_idp_link ...'
|
110
|
+
end
|
111
|
+
# verify the required parameter 'user_id' is set
|
112
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
113
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_add_idp_link"
|
114
|
+
end
|
115
|
+
# verify the required parameter 'user_service_add_idp_link_request' is set
|
116
|
+
if @api_client.config.client_side_validation && user_service_add_idp_link_request.nil?
|
117
|
+
fail ArgumentError, "Missing the required parameter 'user_service_add_idp_link_request' when calling UserServiceApi.user_service_add_idp_link"
|
118
|
+
end
|
119
|
+
# resource path
|
120
|
+
local_var_path = '/v2/users/{userId}/links'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
121
|
+
|
122
|
+
# query parameters
|
123
|
+
query_params = opts[:query_params] || {}
|
124
|
+
|
125
|
+
# header parameters
|
126
|
+
header_params = opts[:header_params] || {}
|
127
|
+
# HTTP header 'Accept' (if needed)
|
128
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
129
|
+
# HTTP header 'Content-Type'
|
130
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
131
|
+
if !content_type.nil?
|
132
|
+
header_params['Content-Type'] = content_type
|
133
|
+
end
|
134
|
+
|
135
|
+
# form parameters
|
136
|
+
form_params = opts[:form_params] || {}
|
137
|
+
|
138
|
+
# http body (model)
|
139
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_add_idp_link_request)
|
140
|
+
|
141
|
+
# return_type
|
142
|
+
return_type = opts[:debug_return_type] || 'UserServiceAddIDPLinkResponse'
|
143
|
+
|
144
|
+
# auth_names
|
145
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
146
|
+
|
147
|
+
new_options = opts.merge(
|
148
|
+
:operation => :"UserServiceApi.user_service_add_idp_link",
|
149
|
+
:header_params => header_params,
|
150
|
+
:query_params => query_params,
|
151
|
+
:form_params => form_params,
|
152
|
+
:body => post_body,
|
153
|
+
:auth_names => auth_names,
|
154
|
+
:return_type => return_type
|
155
|
+
)
|
156
|
+
|
157
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
158
|
+
if @api_client.config.debugging
|
159
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_add_idp_link\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
160
|
+
end
|
161
|
+
return data, status_code, headers
|
162
|
+
end
|
163
|
+
|
164
|
+
# Add OTP Email for a user
|
165
|
+
# Add a new One-Time Password (OTP) Email factor to the authenticated user. OTP Email will enable the user to verify a OTP with the latest verified email. The email has to be verified to add the second factor..
|
166
|
+
# @param user_id [String]
|
167
|
+
# @param [Hash] opts the optional parameters
|
168
|
+
# @return [UserServiceAddOTPEmailResponse]
|
169
|
+
def user_service_add_otp_email(user_id, opts = {})
|
170
|
+
data, _status_code, _headers = user_service_add_otp_email_with_http_info(user_id, opts)
|
171
|
+
data
|
172
|
+
end
|
173
|
+
|
174
|
+
# Add OTP Email for a user
|
175
|
+
# Add a new One-Time Password (OTP) Email factor to the authenticated user. OTP Email will enable the user to verify a OTP with the latest verified email. The email has to be verified to add the second factor..
|
176
|
+
# @param user_id [String]
|
177
|
+
# @param [Hash] opts the optional parameters
|
178
|
+
# @return [Array<(UserServiceAddOTPEmailResponse, Integer, Hash)>] UserServiceAddOTPEmailResponse data, response status code and response headers
|
179
|
+
def user_service_add_otp_email_with_http_info(user_id, opts = {})
|
180
|
+
if @api_client.config.debugging
|
181
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_add_otp_email ...'
|
182
|
+
end
|
183
|
+
# verify the required parameter 'user_id' is set
|
184
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
185
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_add_otp_email"
|
186
|
+
end
|
187
|
+
# resource path
|
188
|
+
local_var_path = '/v2/users/{userId}/otp_email'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
189
|
+
|
190
|
+
# query parameters
|
191
|
+
query_params = opts[:query_params] || {}
|
192
|
+
|
193
|
+
# header parameters
|
194
|
+
header_params = opts[:header_params] || {}
|
195
|
+
# HTTP header 'Accept' (if needed)
|
196
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
197
|
+
# HTTP header 'Content-Type'
|
198
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
199
|
+
if !content_type.nil?
|
200
|
+
header_params['Content-Type'] = content_type
|
201
|
+
end
|
202
|
+
|
203
|
+
# form parameters
|
204
|
+
form_params = opts[:form_params] || {}
|
205
|
+
|
206
|
+
# http body (model)
|
207
|
+
post_body = opts[:debug_body]
|
208
|
+
|
209
|
+
# return_type
|
210
|
+
return_type = opts[:debug_return_type] || 'UserServiceAddOTPEmailResponse'
|
211
|
+
|
212
|
+
# auth_names
|
213
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
214
|
+
|
215
|
+
new_options = opts.merge(
|
216
|
+
:operation => :"UserServiceApi.user_service_add_otp_email",
|
217
|
+
:header_params => header_params,
|
218
|
+
:query_params => query_params,
|
219
|
+
:form_params => form_params,
|
220
|
+
:body => post_body,
|
221
|
+
:auth_names => auth_names,
|
222
|
+
:return_type => return_type
|
223
|
+
)
|
224
|
+
|
225
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
226
|
+
if @api_client.config.debugging
|
227
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_add_otp_email\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
228
|
+
end
|
229
|
+
return data, status_code, headers
|
230
|
+
end
|
231
|
+
|
232
|
+
# Add OTP SMS for a user
|
233
|
+
# Add a new One-Time Password (OTP) SMS factor to the authenticated user. OTP SMS will enable the user to verify a OTP with the latest verified phone number. The phone number has to be verified to add the second factor..
|
234
|
+
# @param user_id [String]
|
235
|
+
# @param [Hash] opts the optional parameters
|
236
|
+
# @return [UserServiceAddOTPSMSResponse]
|
237
|
+
def user_service_add_otpsms(user_id, opts = {})
|
238
|
+
data, _status_code, _headers = user_service_add_otpsms_with_http_info(user_id, opts)
|
239
|
+
data
|
240
|
+
end
|
241
|
+
|
242
|
+
# Add OTP SMS for a user
|
243
|
+
# Add a new One-Time Password (OTP) SMS factor to the authenticated user. OTP SMS will enable the user to verify a OTP with the latest verified phone number. The phone number has to be verified to add the second factor..
|
244
|
+
# @param user_id [String]
|
245
|
+
# @param [Hash] opts the optional parameters
|
246
|
+
# @return [Array<(UserServiceAddOTPSMSResponse, Integer, Hash)>] UserServiceAddOTPSMSResponse data, response status code and response headers
|
247
|
+
def user_service_add_otpsms_with_http_info(user_id, opts = {})
|
248
|
+
if @api_client.config.debugging
|
249
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_add_otpsms ...'
|
250
|
+
end
|
251
|
+
# verify the required parameter 'user_id' is set
|
252
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
253
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_add_otpsms"
|
254
|
+
end
|
255
|
+
# resource path
|
256
|
+
local_var_path = '/v2/users/{userId}/otp_sms'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
257
|
+
|
258
|
+
# query parameters
|
259
|
+
query_params = opts[:query_params] || {}
|
260
|
+
|
261
|
+
# header parameters
|
262
|
+
header_params = opts[:header_params] || {}
|
263
|
+
# HTTP header 'Accept' (if needed)
|
264
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
265
|
+
# HTTP header 'Content-Type'
|
266
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
267
|
+
if !content_type.nil?
|
268
|
+
header_params['Content-Type'] = content_type
|
269
|
+
end
|
270
|
+
|
271
|
+
# form parameters
|
272
|
+
form_params = opts[:form_params] || {}
|
273
|
+
|
274
|
+
# http body (model)
|
275
|
+
post_body = opts[:debug_body]
|
276
|
+
|
277
|
+
# return_type
|
278
|
+
return_type = opts[:debug_return_type] || 'UserServiceAddOTPSMSResponse'
|
279
|
+
|
280
|
+
# auth_names
|
281
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
282
|
+
|
283
|
+
new_options = opts.merge(
|
284
|
+
:operation => :"UserServiceApi.user_service_add_otpsms",
|
285
|
+
:header_params => header_params,
|
286
|
+
:query_params => query_params,
|
287
|
+
:form_params => form_params,
|
288
|
+
:body => post_body,
|
289
|
+
:auth_names => auth_names,
|
290
|
+
:return_type => return_type
|
291
|
+
)
|
292
|
+
|
293
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
294
|
+
if @api_client.config.debugging
|
295
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_add_otpsms\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
296
|
+
end
|
297
|
+
return data, status_code, headers
|
298
|
+
end
|
299
|
+
|
300
|
+
# Create an invite code for a user
|
301
|
+
# Create an invite code for a user to initialize their first authentication method (password, passkeys, IdP) depending on the organization's available methods.
|
302
|
+
# @param user_id [String]
|
303
|
+
# @param user_service_create_invite_code_request [UserServiceCreateInviteCodeRequest]
|
304
|
+
# @param [Hash] opts the optional parameters
|
305
|
+
# @return [UserServiceCreateInviteCodeResponse]
|
306
|
+
def user_service_create_invite_code(user_id, user_service_create_invite_code_request, opts = {})
|
307
|
+
data, _status_code, _headers = user_service_create_invite_code_with_http_info(user_id, user_service_create_invite_code_request, opts)
|
308
|
+
data
|
309
|
+
end
|
310
|
+
|
311
|
+
# Create an invite code for a user
|
312
|
+
# Create an invite code for a user to initialize their first authentication method (password, passkeys, IdP) depending on the organization's available methods.
|
313
|
+
# @param user_id [String]
|
314
|
+
# @param user_service_create_invite_code_request [UserServiceCreateInviteCodeRequest]
|
315
|
+
# @param [Hash] opts the optional parameters
|
316
|
+
# @return [Array<(UserServiceCreateInviteCodeResponse, Integer, Hash)>] UserServiceCreateInviteCodeResponse data, response status code and response headers
|
317
|
+
def user_service_create_invite_code_with_http_info(user_id, user_service_create_invite_code_request, opts = {})
|
318
|
+
if @api_client.config.debugging
|
319
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_create_invite_code ...'
|
320
|
+
end
|
321
|
+
# verify the required parameter 'user_id' is set
|
322
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
323
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_create_invite_code"
|
324
|
+
end
|
325
|
+
# verify the required parameter 'user_service_create_invite_code_request' is set
|
326
|
+
if @api_client.config.client_side_validation && user_service_create_invite_code_request.nil?
|
327
|
+
fail ArgumentError, "Missing the required parameter 'user_service_create_invite_code_request' when calling UserServiceApi.user_service_create_invite_code"
|
328
|
+
end
|
329
|
+
# resource path
|
330
|
+
local_var_path = '/v2/users/{userId}/invite_code'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
331
|
+
|
332
|
+
# query parameters
|
333
|
+
query_params = opts[:query_params] || {}
|
334
|
+
|
335
|
+
# header parameters
|
336
|
+
header_params = opts[:header_params] || {}
|
337
|
+
# HTTP header 'Accept' (if needed)
|
338
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
339
|
+
# HTTP header 'Content-Type'
|
340
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
341
|
+
if !content_type.nil?
|
342
|
+
header_params['Content-Type'] = content_type
|
343
|
+
end
|
344
|
+
|
345
|
+
# form parameters
|
346
|
+
form_params = opts[:form_params] || {}
|
347
|
+
|
348
|
+
# http body (model)
|
349
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_create_invite_code_request)
|
350
|
+
|
351
|
+
# return_type
|
352
|
+
return_type = opts[:debug_return_type] || 'UserServiceCreateInviteCodeResponse'
|
353
|
+
|
354
|
+
# auth_names
|
355
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
356
|
+
|
357
|
+
new_options = opts.merge(
|
358
|
+
:operation => :"UserServiceApi.user_service_create_invite_code",
|
359
|
+
:header_params => header_params,
|
360
|
+
:query_params => query_params,
|
361
|
+
:form_params => form_params,
|
362
|
+
:body => post_body,
|
363
|
+
:auth_names => auth_names,
|
364
|
+
:return_type => return_type
|
365
|
+
)
|
366
|
+
|
367
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
368
|
+
if @api_client.config.debugging
|
369
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_create_invite_code\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
370
|
+
end
|
371
|
+
return data, status_code, headers
|
372
|
+
end
|
373
|
+
|
374
|
+
# Create a passkey registration link for a user
|
375
|
+
# Create a passkey registration link which includes a code and either return it or send it to the user..
|
376
|
+
# @param user_id [String]
|
377
|
+
# @param user_service_create_passkey_registration_link_request [UserServiceCreatePasskeyRegistrationLinkRequest]
|
378
|
+
# @param [Hash] opts the optional parameters
|
379
|
+
# @return [UserServiceCreatePasskeyRegistrationLinkResponse]
|
380
|
+
def user_service_create_passkey_registration_link(user_id, user_service_create_passkey_registration_link_request, opts = {})
|
381
|
+
data, _status_code, _headers = user_service_create_passkey_registration_link_with_http_info(user_id, user_service_create_passkey_registration_link_request, opts)
|
382
|
+
data
|
383
|
+
end
|
384
|
+
|
385
|
+
# Create a passkey registration link for a user
|
386
|
+
# Create a passkey registration link which includes a code and either return it or send it to the user..
|
387
|
+
# @param user_id [String]
|
388
|
+
# @param user_service_create_passkey_registration_link_request [UserServiceCreatePasskeyRegistrationLinkRequest]
|
389
|
+
# @param [Hash] opts the optional parameters
|
390
|
+
# @return [Array<(UserServiceCreatePasskeyRegistrationLinkResponse, Integer, Hash)>] UserServiceCreatePasskeyRegistrationLinkResponse data, response status code and response headers
|
391
|
+
def user_service_create_passkey_registration_link_with_http_info(user_id, user_service_create_passkey_registration_link_request, opts = {})
|
392
|
+
if @api_client.config.debugging
|
393
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_create_passkey_registration_link ...'
|
394
|
+
end
|
395
|
+
# verify the required parameter 'user_id' is set
|
396
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
397
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_create_passkey_registration_link"
|
398
|
+
end
|
399
|
+
# verify the required parameter 'user_service_create_passkey_registration_link_request' is set
|
400
|
+
if @api_client.config.client_side_validation && user_service_create_passkey_registration_link_request.nil?
|
401
|
+
fail ArgumentError, "Missing the required parameter 'user_service_create_passkey_registration_link_request' when calling UserServiceApi.user_service_create_passkey_registration_link"
|
402
|
+
end
|
403
|
+
# resource path
|
404
|
+
local_var_path = '/v2/users/{userId}/passkeys/registration_link'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
405
|
+
|
406
|
+
# query parameters
|
407
|
+
query_params = opts[:query_params] || {}
|
408
|
+
|
409
|
+
# header parameters
|
410
|
+
header_params = opts[:header_params] || {}
|
411
|
+
# HTTP header 'Accept' (if needed)
|
412
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
413
|
+
# HTTP header 'Content-Type'
|
414
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
415
|
+
if !content_type.nil?
|
416
|
+
header_params['Content-Type'] = content_type
|
417
|
+
end
|
418
|
+
|
419
|
+
# form parameters
|
420
|
+
form_params = opts[:form_params] || {}
|
421
|
+
|
422
|
+
# http body (model)
|
423
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_create_passkey_registration_link_request)
|
424
|
+
|
425
|
+
# return_type
|
426
|
+
return_type = opts[:debug_return_type] || 'UserServiceCreatePasskeyRegistrationLinkResponse'
|
427
|
+
|
428
|
+
# auth_names
|
429
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
430
|
+
|
431
|
+
new_options = opts.merge(
|
432
|
+
:operation => :"UserServiceApi.user_service_create_passkey_registration_link",
|
433
|
+
:header_params => header_params,
|
434
|
+
:query_params => query_params,
|
435
|
+
:form_params => form_params,
|
436
|
+
:body => post_body,
|
437
|
+
:auth_names => auth_names,
|
438
|
+
:return_type => return_type
|
439
|
+
)
|
440
|
+
|
441
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
442
|
+
if @api_client.config.debugging
|
443
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_create_passkey_registration_link\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
444
|
+
end
|
445
|
+
return data, status_code, headers
|
446
|
+
end
|
447
|
+
|
448
|
+
# Deactivate user
|
449
|
+
# The state of the user will be changed to 'deactivated'. The user will not be able to log in anymore. The endpoint returns an error if the user is already in the state 'deactivated'. Use deactivate user when the user should not be able to use the account anymore, but you still need access to the user data..
|
450
|
+
# @param user_id [String]
|
451
|
+
# @param [Hash] opts the optional parameters
|
452
|
+
# @return [UserServiceDeactivateUserResponse]
|
453
|
+
def user_service_deactivate_user(user_id, opts = {})
|
454
|
+
data, _status_code, _headers = user_service_deactivate_user_with_http_info(user_id, opts)
|
455
|
+
data
|
456
|
+
end
|
457
|
+
|
458
|
+
# Deactivate user
|
459
|
+
# The state of the user will be changed to 'deactivated'. The user will not be able to log in anymore. The endpoint returns an error if the user is already in the state 'deactivated'. Use deactivate user when the user should not be able to use the account anymore, but you still need access to the user data..
|
460
|
+
# @param user_id [String]
|
461
|
+
# @param [Hash] opts the optional parameters
|
462
|
+
# @return [Array<(UserServiceDeactivateUserResponse, Integer, Hash)>] UserServiceDeactivateUserResponse data, response status code and response headers
|
463
|
+
def user_service_deactivate_user_with_http_info(user_id, opts = {})
|
464
|
+
if @api_client.config.debugging
|
465
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_deactivate_user ...'
|
466
|
+
end
|
467
|
+
# verify the required parameter 'user_id' is set
|
468
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
469
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_deactivate_user"
|
470
|
+
end
|
471
|
+
# resource path
|
472
|
+
local_var_path = '/v2/users/{userId}/deactivate'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
473
|
+
|
474
|
+
# query parameters
|
475
|
+
query_params = opts[:query_params] || {}
|
476
|
+
|
477
|
+
# header parameters
|
478
|
+
header_params = opts[:header_params] || {}
|
479
|
+
# HTTP header 'Accept' (if needed)
|
480
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
481
|
+
# HTTP header 'Content-Type'
|
482
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
483
|
+
if !content_type.nil?
|
484
|
+
header_params['Content-Type'] = content_type
|
485
|
+
end
|
486
|
+
|
487
|
+
# form parameters
|
488
|
+
form_params = opts[:form_params] || {}
|
489
|
+
|
490
|
+
# http body (model)
|
491
|
+
post_body = opts[:debug_body]
|
492
|
+
|
493
|
+
# return_type
|
494
|
+
return_type = opts[:debug_return_type] || 'UserServiceDeactivateUserResponse'
|
495
|
+
|
496
|
+
# auth_names
|
497
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
498
|
+
|
499
|
+
new_options = opts.merge(
|
500
|
+
:operation => :"UserServiceApi.user_service_deactivate_user",
|
501
|
+
:header_params => header_params,
|
502
|
+
:query_params => query_params,
|
503
|
+
:form_params => form_params,
|
504
|
+
:body => post_body,
|
505
|
+
:auth_names => auth_names,
|
506
|
+
:return_type => return_type
|
507
|
+
)
|
508
|
+
|
509
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
510
|
+
if @api_client.config.debugging
|
511
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_deactivate_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
512
|
+
end
|
513
|
+
return data, status_code, headers
|
514
|
+
end
|
515
|
+
|
516
|
+
# Delete user
|
517
|
+
# The state of the user will be changed to 'deleted'. The user will not be able to log in anymore. Endpoints requesting this user will return an error 'User not found..
|
518
|
+
# @param user_id [String]
|
519
|
+
# @param [Hash] opts the optional parameters
|
520
|
+
# @return [UserServiceDeleteUserResponse]
|
521
|
+
def user_service_delete_user(user_id, opts = {})
|
522
|
+
data, _status_code, _headers = user_service_delete_user_with_http_info(user_id, opts)
|
523
|
+
data
|
524
|
+
end
|
525
|
+
|
526
|
+
# Delete user
|
527
|
+
# The state of the user will be changed to 'deleted'. The user will not be able to log in anymore. Endpoints requesting this user will return an error 'User not found..
|
528
|
+
# @param user_id [String]
|
529
|
+
# @param [Hash] opts the optional parameters
|
530
|
+
# @return [Array<(UserServiceDeleteUserResponse, Integer, Hash)>] UserServiceDeleteUserResponse data, response status code and response headers
|
531
|
+
def user_service_delete_user_with_http_info(user_id, opts = {})
|
532
|
+
if @api_client.config.debugging
|
533
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_delete_user ...'
|
534
|
+
end
|
535
|
+
# verify the required parameter 'user_id' is set
|
536
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
537
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_delete_user"
|
538
|
+
end
|
539
|
+
# resource path
|
540
|
+
local_var_path = '/v2/users/{userId}'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
541
|
+
|
542
|
+
# query parameters
|
543
|
+
query_params = opts[:query_params] || {}
|
544
|
+
|
545
|
+
# header parameters
|
546
|
+
header_params = opts[:header_params] || {}
|
547
|
+
# HTTP header 'Accept' (if needed)
|
548
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
549
|
+
|
550
|
+
# form parameters
|
551
|
+
form_params = opts[:form_params] || {}
|
552
|
+
|
553
|
+
# http body (model)
|
554
|
+
post_body = opts[:debug_body]
|
555
|
+
|
556
|
+
# return_type
|
557
|
+
return_type = opts[:debug_return_type] || 'UserServiceDeleteUserResponse'
|
558
|
+
|
559
|
+
# auth_names
|
560
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
561
|
+
|
562
|
+
new_options = opts.merge(
|
563
|
+
:operation => :"UserServiceApi.user_service_delete_user",
|
564
|
+
:header_params => header_params,
|
565
|
+
:query_params => query_params,
|
566
|
+
:form_params => form_params,
|
567
|
+
:body => post_body,
|
568
|
+
:auth_names => auth_names,
|
569
|
+
:return_type => return_type
|
570
|
+
)
|
571
|
+
|
572
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
573
|
+
if @api_client.config.debugging
|
574
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_delete_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
575
|
+
end
|
576
|
+
return data, status_code, headers
|
577
|
+
end
|
578
|
+
|
579
|
+
# User by ID
|
580
|
+
# Returns the full user object (human or machine) including the profile, email, etc..
|
581
|
+
# @param user_id [String] User ID of the user you like to get.
|
582
|
+
# @param [Hash] opts the optional parameters
|
583
|
+
# @return [UserServiceGetUserByIDResponse]
|
584
|
+
def user_service_get_user_by_id(user_id, opts = {})
|
585
|
+
data, _status_code, _headers = user_service_get_user_by_id_with_http_info(user_id, opts)
|
586
|
+
data
|
587
|
+
end
|
588
|
+
|
589
|
+
# User by ID
|
590
|
+
# Returns the full user object (human or machine) including the profile, email, etc..
|
591
|
+
# @param user_id [String] User ID of the user you like to get.
|
592
|
+
# @param [Hash] opts the optional parameters
|
593
|
+
# @return [Array<(UserServiceGetUserByIDResponse, Integer, Hash)>] UserServiceGetUserByIDResponse data, response status code and response headers
|
594
|
+
def user_service_get_user_by_id_with_http_info(user_id, opts = {})
|
595
|
+
if @api_client.config.debugging
|
596
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_get_user_by_id ...'
|
597
|
+
end
|
598
|
+
# verify the required parameter 'user_id' is set
|
599
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
600
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_get_user_by_id"
|
601
|
+
end
|
602
|
+
# resource path
|
603
|
+
local_var_path = '/v2/users/{userId}'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
604
|
+
|
605
|
+
# query parameters
|
606
|
+
query_params = opts[:query_params] || {}
|
607
|
+
|
608
|
+
# header parameters
|
609
|
+
header_params = opts[:header_params] || {}
|
610
|
+
# HTTP header 'Accept' (if needed)
|
611
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
612
|
+
|
613
|
+
# form parameters
|
614
|
+
form_params = opts[:form_params] || {}
|
615
|
+
|
616
|
+
# http body (model)
|
617
|
+
post_body = opts[:debug_body]
|
618
|
+
|
619
|
+
# return_type
|
620
|
+
return_type = opts[:debug_return_type] || 'UserServiceGetUserByIDResponse'
|
621
|
+
|
622
|
+
# auth_names
|
623
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
624
|
+
|
625
|
+
new_options = opts.merge(
|
626
|
+
:operation => :"UserServiceApi.user_service_get_user_by_id",
|
627
|
+
:header_params => header_params,
|
628
|
+
:query_params => query_params,
|
629
|
+
:form_params => form_params,
|
630
|
+
:body => post_body,
|
631
|
+
:auth_names => auth_names,
|
632
|
+
:return_type => return_type
|
633
|
+
)
|
634
|
+
|
635
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
636
|
+
if @api_client.config.debugging
|
637
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_get_user_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
638
|
+
end
|
639
|
+
return data, status_code, headers
|
640
|
+
end
|
641
|
+
|
642
|
+
# MFA Init Skipped
|
643
|
+
# Update the last time the user has skipped MFA initialization. The server timestamp is used.
|
644
|
+
# @param user_id [String]
|
645
|
+
# @param [Hash] opts the optional parameters
|
646
|
+
# @return [UserServiceHumanMFAInitSkippedResponse]
|
647
|
+
def user_service_human_mfa_init_skipped(user_id, opts = {})
|
648
|
+
data, _status_code, _headers = user_service_human_mfa_init_skipped_with_http_info(user_id, opts)
|
649
|
+
data
|
650
|
+
end
|
651
|
+
|
652
|
+
# MFA Init Skipped
|
653
|
+
# Update the last time the user has skipped MFA initialization. The server timestamp is used.
|
654
|
+
# @param user_id [String]
|
655
|
+
# @param [Hash] opts the optional parameters
|
656
|
+
# @return [Array<(UserServiceHumanMFAInitSkippedResponse, Integer, Hash)>] UserServiceHumanMFAInitSkippedResponse data, response status code and response headers
|
657
|
+
def user_service_human_mfa_init_skipped_with_http_info(user_id, opts = {})
|
658
|
+
if @api_client.config.debugging
|
659
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_human_mfa_init_skipped ...'
|
660
|
+
end
|
661
|
+
# verify the required parameter 'user_id' is set
|
662
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
663
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_human_mfa_init_skipped"
|
664
|
+
end
|
665
|
+
# resource path
|
666
|
+
local_var_path = '/v2/users/{userId}/mfa_init_skipped'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
667
|
+
|
668
|
+
# query parameters
|
669
|
+
query_params = opts[:query_params] || {}
|
670
|
+
|
671
|
+
# header parameters
|
672
|
+
header_params = opts[:header_params] || {}
|
673
|
+
# HTTP header 'Accept' (if needed)
|
674
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
675
|
+
# HTTP header 'Content-Type'
|
676
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
677
|
+
if !content_type.nil?
|
678
|
+
header_params['Content-Type'] = content_type
|
679
|
+
end
|
680
|
+
|
681
|
+
# form parameters
|
682
|
+
form_params = opts[:form_params] || {}
|
683
|
+
|
684
|
+
# http body (model)
|
685
|
+
post_body = opts[:debug_body]
|
686
|
+
|
687
|
+
# return_type
|
688
|
+
return_type = opts[:debug_return_type] || 'UserServiceHumanMFAInitSkippedResponse'
|
689
|
+
|
690
|
+
# auth_names
|
691
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
692
|
+
|
693
|
+
new_options = opts.merge(
|
694
|
+
:operation => :"UserServiceApi.user_service_human_mfa_init_skipped",
|
695
|
+
:header_params => header_params,
|
696
|
+
:query_params => query_params,
|
697
|
+
:form_params => form_params,
|
698
|
+
:body => post_body,
|
699
|
+
:auth_names => auth_names,
|
700
|
+
:return_type => return_type
|
701
|
+
)
|
702
|
+
|
703
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
704
|
+
if @api_client.config.debugging
|
705
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_human_mfa_init_skipped\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
706
|
+
end
|
707
|
+
return data, status_code, headers
|
708
|
+
end
|
709
|
+
|
710
|
+
# @param user_id [String]
|
711
|
+
# @param [Hash] opts the optional parameters
|
712
|
+
# @option opts [Array<String>] :auth_factors Specify the Auth Factors you are interested in
|
713
|
+
# @option opts [Array<String>] :states Specify the state of the Auth Factors
|
714
|
+
# @return [UserServiceListAuthenticationFactorsResponse]
|
715
|
+
def user_service_list_authentication_factors(user_id, opts = {})
|
716
|
+
data, _status_code, _headers = user_service_list_authentication_factors_with_http_info(user_id, opts)
|
717
|
+
data
|
718
|
+
end
|
719
|
+
|
720
|
+
# @param user_id [String]
|
721
|
+
# @param [Hash] opts the optional parameters
|
722
|
+
# @option opts [Array<String>] :auth_factors Specify the Auth Factors you are interested in
|
723
|
+
# @option opts [Array<String>] :states Specify the state of the Auth Factors
|
724
|
+
# @return [Array<(UserServiceListAuthenticationFactorsResponse, Integer, Hash)>] UserServiceListAuthenticationFactorsResponse data, response status code and response headers
|
725
|
+
def user_service_list_authentication_factors_with_http_info(user_id, opts = {})
|
726
|
+
if @api_client.config.debugging
|
727
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_list_authentication_factors ...'
|
728
|
+
end
|
729
|
+
# verify the required parameter 'user_id' is set
|
730
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
731
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_list_authentication_factors"
|
732
|
+
end
|
733
|
+
allowable_values = ["OTP", "OTP_SMS", "OTP_EMAIL", "U2F"]
|
734
|
+
if @api_client.config.client_side_validation && opts[:'auth_factors'] && !opts[:'auth_factors'].all? { |item| allowable_values.include?(item) }
|
735
|
+
fail ArgumentError, "invalid value for \"auth_factors\", must include one of #{allowable_values}"
|
736
|
+
end
|
737
|
+
allowable_values = ["AUTH_FACTOR_STATE_UNSPECIFIED", "AUTH_FACTOR_STATE_NOT_READY", "AUTH_FACTOR_STATE_READY", "AUTH_FACTOR_STATE_REMOVED"]
|
738
|
+
if @api_client.config.client_side_validation && opts[:'states'] && !opts[:'states'].all? { |item| allowable_values.include?(item) }
|
739
|
+
fail ArgumentError, "invalid value for \"states\", must include one of #{allowable_values}"
|
740
|
+
end
|
741
|
+
# resource path
|
742
|
+
local_var_path = '/v2/users/{userId}/authentication_factors/_search'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
743
|
+
|
744
|
+
# query parameters
|
745
|
+
query_params = opts[:query_params] || {}
|
746
|
+
query_params[:'authFactors'] = @api_client.build_collection_param(opts[:'auth_factors'], :csv) if !opts[:'auth_factors'].nil?
|
747
|
+
query_params[:'states'] = @api_client.build_collection_param(opts[:'states'], :csv) if !opts[:'states'].nil?
|
748
|
+
|
749
|
+
# header parameters
|
750
|
+
header_params = opts[:header_params] || {}
|
751
|
+
# HTTP header 'Accept' (if needed)
|
752
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
753
|
+
|
754
|
+
# form parameters
|
755
|
+
form_params = opts[:form_params] || {}
|
756
|
+
|
757
|
+
# http body (model)
|
758
|
+
post_body = opts[:debug_body]
|
759
|
+
|
760
|
+
# return_type
|
761
|
+
return_type = opts[:debug_return_type] || 'UserServiceListAuthenticationFactorsResponse'
|
762
|
+
|
763
|
+
# auth_names
|
764
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
765
|
+
|
766
|
+
new_options = opts.merge(
|
767
|
+
:operation => :"UserServiceApi.user_service_list_authentication_factors",
|
768
|
+
:header_params => header_params,
|
769
|
+
:query_params => query_params,
|
770
|
+
:form_params => form_params,
|
771
|
+
:body => post_body,
|
772
|
+
:auth_names => auth_names,
|
773
|
+
:return_type => return_type
|
774
|
+
)
|
775
|
+
|
776
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
777
|
+
if @api_client.config.debugging
|
778
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_list_authentication_factors\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
779
|
+
end
|
780
|
+
return data, status_code, headers
|
781
|
+
end
|
782
|
+
|
783
|
+
# List all possible authentication methods of a user
|
784
|
+
# List all possible authentication methods of a user like password, passwordless, (T)OTP and more..
|
785
|
+
# @param user_id [String]
|
786
|
+
# @param [Hash] opts the optional parameters
|
787
|
+
# @option opts [Boolean] :domain_query_include_without_domain List also auth method types without domain information like passkey and U2F added through V1 APIs / Login UI.
|
788
|
+
# @option opts [String] :domain_query_domain List only auth methods with specific domain.
|
789
|
+
# @return [UserServiceListAuthenticationMethodTypesResponse]
|
790
|
+
def user_service_list_authentication_method_types(user_id, opts = {})
|
791
|
+
data, _status_code, _headers = user_service_list_authentication_method_types_with_http_info(user_id, opts)
|
792
|
+
data
|
793
|
+
end
|
794
|
+
|
795
|
+
# List all possible authentication methods of a user
|
796
|
+
# List all possible authentication methods of a user like password, passwordless, (T)OTP and more..
|
797
|
+
# @param user_id [String]
|
798
|
+
# @param [Hash] opts the optional parameters
|
799
|
+
# @option opts [Boolean] :domain_query_include_without_domain List also auth method types without domain information like passkey and U2F added through V1 APIs / Login UI.
|
800
|
+
# @option opts [String] :domain_query_domain List only auth methods with specific domain.
|
801
|
+
# @return [Array<(UserServiceListAuthenticationMethodTypesResponse, Integer, Hash)>] UserServiceListAuthenticationMethodTypesResponse data, response status code and response headers
|
802
|
+
def user_service_list_authentication_method_types_with_http_info(user_id, opts = {})
|
803
|
+
if @api_client.config.debugging
|
804
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_list_authentication_method_types ...'
|
805
|
+
end
|
806
|
+
# verify the required parameter 'user_id' is set
|
807
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
808
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_list_authentication_method_types"
|
809
|
+
end
|
810
|
+
# resource path
|
811
|
+
local_var_path = '/v2/users/{userId}/authentication_methods'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
812
|
+
|
813
|
+
# query parameters
|
814
|
+
query_params = opts[:query_params] || {}
|
815
|
+
query_params[:'domainQuery.includeWithoutDomain'] = opts[:'domain_query_include_without_domain'] if !opts[:'domain_query_include_without_domain'].nil?
|
816
|
+
query_params[:'domainQuery.domain'] = opts[:'domain_query_domain'] if !opts[:'domain_query_domain'].nil?
|
817
|
+
|
818
|
+
# header parameters
|
819
|
+
header_params = opts[:header_params] || {}
|
820
|
+
# HTTP header 'Accept' (if needed)
|
821
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
822
|
+
|
823
|
+
# form parameters
|
824
|
+
form_params = opts[:form_params] || {}
|
825
|
+
|
826
|
+
# http body (model)
|
827
|
+
post_body = opts[:debug_body]
|
828
|
+
|
829
|
+
# return_type
|
830
|
+
return_type = opts[:debug_return_type] || 'UserServiceListAuthenticationMethodTypesResponse'
|
831
|
+
|
832
|
+
# auth_names
|
833
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
834
|
+
|
835
|
+
new_options = opts.merge(
|
836
|
+
:operation => :"UserServiceApi.user_service_list_authentication_method_types",
|
837
|
+
:header_params => header_params,
|
838
|
+
:query_params => query_params,
|
839
|
+
:form_params => form_params,
|
840
|
+
:body => post_body,
|
841
|
+
:auth_names => auth_names,
|
842
|
+
:return_type => return_type
|
843
|
+
)
|
844
|
+
|
845
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
846
|
+
if @api_client.config.debugging
|
847
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_list_authentication_method_types\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
848
|
+
end
|
849
|
+
return data, status_code, headers
|
850
|
+
end
|
851
|
+
|
852
|
+
# List links to an identity provider of an user
|
853
|
+
# List links to an identity provider of an user.
|
854
|
+
# @param user_id [String]
|
855
|
+
# @param user_service_list_idp_links_request [UserServiceListIDPLinksRequest]
|
856
|
+
# @param [Hash] opts the optional parameters
|
857
|
+
# @return [UserServiceListIDPLinksResponse]
|
858
|
+
def user_service_list_idp_links(user_id, user_service_list_idp_links_request, opts = {})
|
859
|
+
data, _status_code, _headers = user_service_list_idp_links_with_http_info(user_id, user_service_list_idp_links_request, opts)
|
860
|
+
data
|
861
|
+
end
|
862
|
+
|
863
|
+
# List links to an identity provider of an user
|
864
|
+
# List links to an identity provider of an user.
|
865
|
+
# @param user_id [String]
|
866
|
+
# @param user_service_list_idp_links_request [UserServiceListIDPLinksRequest]
|
867
|
+
# @param [Hash] opts the optional parameters
|
868
|
+
# @return [Array<(UserServiceListIDPLinksResponse, Integer, Hash)>] UserServiceListIDPLinksResponse data, response status code and response headers
|
869
|
+
def user_service_list_idp_links_with_http_info(user_id, user_service_list_idp_links_request, opts = {})
|
870
|
+
if @api_client.config.debugging
|
871
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_list_idp_links ...'
|
872
|
+
end
|
873
|
+
# verify the required parameter 'user_id' is set
|
874
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
875
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_list_idp_links"
|
876
|
+
end
|
877
|
+
# verify the required parameter 'user_service_list_idp_links_request' is set
|
878
|
+
if @api_client.config.client_side_validation && user_service_list_idp_links_request.nil?
|
879
|
+
fail ArgumentError, "Missing the required parameter 'user_service_list_idp_links_request' when calling UserServiceApi.user_service_list_idp_links"
|
880
|
+
end
|
881
|
+
# resource path
|
882
|
+
local_var_path = '/v2/users/{userId}/links/_search'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
883
|
+
|
884
|
+
# query parameters
|
885
|
+
query_params = opts[:query_params] || {}
|
886
|
+
|
887
|
+
# header parameters
|
888
|
+
header_params = opts[:header_params] || {}
|
889
|
+
# HTTP header 'Accept' (if needed)
|
890
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
891
|
+
# HTTP header 'Content-Type'
|
892
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
893
|
+
if !content_type.nil?
|
894
|
+
header_params['Content-Type'] = content_type
|
895
|
+
end
|
896
|
+
|
897
|
+
# form parameters
|
898
|
+
form_params = opts[:form_params] || {}
|
899
|
+
|
900
|
+
# http body (model)
|
901
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_list_idp_links_request)
|
902
|
+
|
903
|
+
# return_type
|
904
|
+
return_type = opts[:debug_return_type] || 'UserServiceListIDPLinksResponse'
|
905
|
+
|
906
|
+
# auth_names
|
907
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
908
|
+
|
909
|
+
new_options = opts.merge(
|
910
|
+
:operation => :"UserServiceApi.user_service_list_idp_links",
|
911
|
+
:header_params => header_params,
|
912
|
+
:query_params => query_params,
|
913
|
+
:form_params => form_params,
|
914
|
+
:body => post_body,
|
915
|
+
:auth_names => auth_names,
|
916
|
+
:return_type => return_type
|
917
|
+
)
|
918
|
+
|
919
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
920
|
+
if @api_client.config.debugging
|
921
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_list_idp_links\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
922
|
+
end
|
923
|
+
return data, status_code, headers
|
924
|
+
end
|
925
|
+
|
926
|
+
# List passkeys of an user
|
927
|
+
# List passkeys of an user
|
928
|
+
# @param user_id [String]
|
929
|
+
# @param [Hash] opts the optional parameters
|
930
|
+
# @return [UserServiceListPasskeysResponse]
|
931
|
+
def user_service_list_passkeys(user_id, opts = {})
|
932
|
+
data, _status_code, _headers = user_service_list_passkeys_with_http_info(user_id, opts)
|
933
|
+
data
|
934
|
+
end
|
935
|
+
|
936
|
+
# List passkeys of an user
|
937
|
+
# List passkeys of an user
|
938
|
+
# @param user_id [String]
|
939
|
+
# @param [Hash] opts the optional parameters
|
940
|
+
# @return [Array<(UserServiceListPasskeysResponse, Integer, Hash)>] UserServiceListPasskeysResponse data, response status code and response headers
|
941
|
+
def user_service_list_passkeys_with_http_info(user_id, opts = {})
|
942
|
+
if @api_client.config.debugging
|
943
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_list_passkeys ...'
|
944
|
+
end
|
945
|
+
# verify the required parameter 'user_id' is set
|
946
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
947
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_list_passkeys"
|
948
|
+
end
|
949
|
+
# resource path
|
950
|
+
local_var_path = '/v2/users/{userId}/passkeys/_search'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
951
|
+
|
952
|
+
# query parameters
|
953
|
+
query_params = opts[:query_params] || {}
|
954
|
+
|
955
|
+
# header parameters
|
956
|
+
header_params = opts[:header_params] || {}
|
957
|
+
# HTTP header 'Accept' (if needed)
|
958
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
959
|
+
# HTTP header 'Content-Type'
|
960
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
961
|
+
if !content_type.nil?
|
962
|
+
header_params['Content-Type'] = content_type
|
963
|
+
end
|
964
|
+
|
965
|
+
# form parameters
|
966
|
+
form_params = opts[:form_params] || {}
|
967
|
+
|
968
|
+
# http body (model)
|
969
|
+
post_body = opts[:debug_body]
|
970
|
+
|
971
|
+
# return_type
|
972
|
+
return_type = opts[:debug_return_type] || 'UserServiceListPasskeysResponse'
|
973
|
+
|
974
|
+
# auth_names
|
975
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
976
|
+
|
977
|
+
new_options = opts.merge(
|
978
|
+
:operation => :"UserServiceApi.user_service_list_passkeys",
|
979
|
+
:header_params => header_params,
|
980
|
+
:query_params => query_params,
|
981
|
+
:form_params => form_params,
|
982
|
+
:body => post_body,
|
983
|
+
:auth_names => auth_names,
|
984
|
+
:return_type => return_type
|
985
|
+
)
|
986
|
+
|
987
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
988
|
+
if @api_client.config.debugging
|
989
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_list_passkeys\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
990
|
+
end
|
991
|
+
return data, status_code, headers
|
992
|
+
end
|
993
|
+
|
994
|
+
# Search Users
|
995
|
+
# Search for users. By default, we will return all users of your instance that you have permission to read. Make sure to include a limit and sorting for pagination.
|
996
|
+
# @param user_service_list_users_request [UserServiceListUsersRequest]
|
997
|
+
# @param [Hash] opts the optional parameters
|
998
|
+
# @return [UserServiceListUsersResponse]
|
999
|
+
def user_service_list_users(user_service_list_users_request, opts = {})
|
1000
|
+
data, _status_code, _headers = user_service_list_users_with_http_info(user_service_list_users_request, opts)
|
1001
|
+
data
|
1002
|
+
end
|
1003
|
+
|
1004
|
+
# Search Users
|
1005
|
+
# Search for users. By default, we will return all users of your instance that you have permission to read. Make sure to include a limit and sorting for pagination.
|
1006
|
+
# @param user_service_list_users_request [UserServiceListUsersRequest]
|
1007
|
+
# @param [Hash] opts the optional parameters
|
1008
|
+
# @return [Array<(UserServiceListUsersResponse, Integer, Hash)>] UserServiceListUsersResponse data, response status code and response headers
|
1009
|
+
def user_service_list_users_with_http_info(user_service_list_users_request, opts = {})
|
1010
|
+
if @api_client.config.debugging
|
1011
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_list_users ...'
|
1012
|
+
end
|
1013
|
+
# verify the required parameter 'user_service_list_users_request' is set
|
1014
|
+
if @api_client.config.client_side_validation && user_service_list_users_request.nil?
|
1015
|
+
fail ArgumentError, "Missing the required parameter 'user_service_list_users_request' when calling UserServiceApi.user_service_list_users"
|
1016
|
+
end
|
1017
|
+
# resource path
|
1018
|
+
local_var_path = '/v2/users'
|
1019
|
+
|
1020
|
+
# query parameters
|
1021
|
+
query_params = opts[:query_params] || {}
|
1022
|
+
|
1023
|
+
# header parameters
|
1024
|
+
header_params = opts[:header_params] || {}
|
1025
|
+
# HTTP header 'Accept' (if needed)
|
1026
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
1027
|
+
# HTTP header 'Content-Type'
|
1028
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
1029
|
+
if !content_type.nil?
|
1030
|
+
header_params['Content-Type'] = content_type
|
1031
|
+
end
|
1032
|
+
|
1033
|
+
# form parameters
|
1034
|
+
form_params = opts[:form_params] || {}
|
1035
|
+
|
1036
|
+
# http body (model)
|
1037
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_list_users_request)
|
1038
|
+
|
1039
|
+
# return_type
|
1040
|
+
return_type = opts[:debug_return_type] || 'UserServiceListUsersResponse'
|
1041
|
+
|
1042
|
+
# auth_names
|
1043
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
1044
|
+
|
1045
|
+
new_options = opts.merge(
|
1046
|
+
:operation => :"UserServiceApi.user_service_list_users",
|
1047
|
+
:header_params => header_params,
|
1048
|
+
:query_params => query_params,
|
1049
|
+
:form_params => form_params,
|
1050
|
+
:body => post_body,
|
1051
|
+
:auth_names => auth_names,
|
1052
|
+
:return_type => return_type
|
1053
|
+
)
|
1054
|
+
|
1055
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1056
|
+
if @api_client.config.debugging
|
1057
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_list_users\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1058
|
+
end
|
1059
|
+
return data, status_code, headers
|
1060
|
+
end
|
1061
|
+
|
1062
|
+
# Lock user
|
1063
|
+
# The state of the user will be changed to 'locked'. The user will not be able to log in anymore. The endpoint returns an error if the user is already in the state 'locked'. Use this endpoint if the user should not be able to log in temporarily because of an event that happened (wrong password, etc.)..
|
1064
|
+
# @param user_id [String]
|
1065
|
+
# @param [Hash] opts the optional parameters
|
1066
|
+
# @return [UserServiceLockUserResponse]
|
1067
|
+
def user_service_lock_user(user_id, opts = {})
|
1068
|
+
data, _status_code, _headers = user_service_lock_user_with_http_info(user_id, opts)
|
1069
|
+
data
|
1070
|
+
end
|
1071
|
+
|
1072
|
+
# Lock user
|
1073
|
+
# The state of the user will be changed to 'locked'. The user will not be able to log in anymore. The endpoint returns an error if the user is already in the state 'locked'. Use this endpoint if the user should not be able to log in temporarily because of an event that happened (wrong password, etc.)..
|
1074
|
+
# @param user_id [String]
|
1075
|
+
# @param [Hash] opts the optional parameters
|
1076
|
+
# @return [Array<(UserServiceLockUserResponse, Integer, Hash)>] UserServiceLockUserResponse data, response status code and response headers
|
1077
|
+
def user_service_lock_user_with_http_info(user_id, opts = {})
|
1078
|
+
if @api_client.config.debugging
|
1079
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_lock_user ...'
|
1080
|
+
end
|
1081
|
+
# verify the required parameter 'user_id' is set
|
1082
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
1083
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_lock_user"
|
1084
|
+
end
|
1085
|
+
# resource path
|
1086
|
+
local_var_path = '/v2/users/{userId}/lock'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
1087
|
+
|
1088
|
+
# query parameters
|
1089
|
+
query_params = opts[:query_params] || {}
|
1090
|
+
|
1091
|
+
# header parameters
|
1092
|
+
header_params = opts[:header_params] || {}
|
1093
|
+
# HTTP header 'Accept' (if needed)
|
1094
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
1095
|
+
# HTTP header 'Content-Type'
|
1096
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
1097
|
+
if !content_type.nil?
|
1098
|
+
header_params['Content-Type'] = content_type
|
1099
|
+
end
|
1100
|
+
|
1101
|
+
# form parameters
|
1102
|
+
form_params = opts[:form_params] || {}
|
1103
|
+
|
1104
|
+
# http body (model)
|
1105
|
+
post_body = opts[:debug_body]
|
1106
|
+
|
1107
|
+
# return_type
|
1108
|
+
return_type = opts[:debug_return_type] || 'UserServiceLockUserResponse'
|
1109
|
+
|
1110
|
+
# auth_names
|
1111
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
1112
|
+
|
1113
|
+
new_options = opts.merge(
|
1114
|
+
:operation => :"UserServiceApi.user_service_lock_user",
|
1115
|
+
:header_params => header_params,
|
1116
|
+
:query_params => query_params,
|
1117
|
+
:form_params => form_params,
|
1118
|
+
:body => post_body,
|
1119
|
+
:auth_names => auth_names,
|
1120
|
+
:return_type => return_type
|
1121
|
+
)
|
1122
|
+
|
1123
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1124
|
+
if @api_client.config.debugging
|
1125
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_lock_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1126
|
+
end
|
1127
|
+
return data, status_code, headers
|
1128
|
+
end
|
1129
|
+
|
1130
|
+
# Request a code to reset a password
|
1131
|
+
# Request a code to reset a password..
|
1132
|
+
# @param user_id [String]
|
1133
|
+
# @param user_service_password_reset_request [UserServicePasswordResetRequest]
|
1134
|
+
# @param [Hash] opts the optional parameters
|
1135
|
+
# @return [UserServicePasswordResetResponse]
|
1136
|
+
def user_service_password_reset(user_id, user_service_password_reset_request, opts = {})
|
1137
|
+
data, _status_code, _headers = user_service_password_reset_with_http_info(user_id, user_service_password_reset_request, opts)
|
1138
|
+
data
|
1139
|
+
end
|
1140
|
+
|
1141
|
+
# Request a code to reset a password
|
1142
|
+
# Request a code to reset a password..
|
1143
|
+
# @param user_id [String]
|
1144
|
+
# @param user_service_password_reset_request [UserServicePasswordResetRequest]
|
1145
|
+
# @param [Hash] opts the optional parameters
|
1146
|
+
# @return [Array<(UserServicePasswordResetResponse, Integer, Hash)>] UserServicePasswordResetResponse data, response status code and response headers
|
1147
|
+
def user_service_password_reset_with_http_info(user_id, user_service_password_reset_request, opts = {})
|
1148
|
+
if @api_client.config.debugging
|
1149
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_password_reset ...'
|
1150
|
+
end
|
1151
|
+
# verify the required parameter 'user_id' is set
|
1152
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
1153
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_password_reset"
|
1154
|
+
end
|
1155
|
+
# verify the required parameter 'user_service_password_reset_request' is set
|
1156
|
+
if @api_client.config.client_side_validation && user_service_password_reset_request.nil?
|
1157
|
+
fail ArgumentError, "Missing the required parameter 'user_service_password_reset_request' when calling UserServiceApi.user_service_password_reset"
|
1158
|
+
end
|
1159
|
+
# resource path
|
1160
|
+
local_var_path = '/v2/users/{userId}/password_reset'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
1161
|
+
|
1162
|
+
# query parameters
|
1163
|
+
query_params = opts[:query_params] || {}
|
1164
|
+
|
1165
|
+
# header parameters
|
1166
|
+
header_params = opts[:header_params] || {}
|
1167
|
+
# HTTP header 'Accept' (if needed)
|
1168
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
1169
|
+
# HTTP header 'Content-Type'
|
1170
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
1171
|
+
if !content_type.nil?
|
1172
|
+
header_params['Content-Type'] = content_type
|
1173
|
+
end
|
1174
|
+
|
1175
|
+
# form parameters
|
1176
|
+
form_params = opts[:form_params] || {}
|
1177
|
+
|
1178
|
+
# http body (model)
|
1179
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_password_reset_request)
|
1180
|
+
|
1181
|
+
# return_type
|
1182
|
+
return_type = opts[:debug_return_type] || 'UserServicePasswordResetResponse'
|
1183
|
+
|
1184
|
+
# auth_names
|
1185
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
1186
|
+
|
1187
|
+
new_options = opts.merge(
|
1188
|
+
:operation => :"UserServiceApi.user_service_password_reset",
|
1189
|
+
:header_params => header_params,
|
1190
|
+
:query_params => query_params,
|
1191
|
+
:form_params => form_params,
|
1192
|
+
:body => post_body,
|
1193
|
+
:auth_names => auth_names,
|
1194
|
+
:return_type => return_type
|
1195
|
+
)
|
1196
|
+
|
1197
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1198
|
+
if @api_client.config.debugging
|
1199
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_password_reset\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1200
|
+
end
|
1201
|
+
return data, status_code, headers
|
1202
|
+
end
|
1203
|
+
|
1204
|
+
# Reactivate user
|
1205
|
+
# Reactivate a user with the state 'deactivated'. The user will be able to log in again afterward. The endpoint returns an error if the user is not in the state 'deactivated'..
|
1206
|
+
# @param user_id [String]
|
1207
|
+
# @param [Hash] opts the optional parameters
|
1208
|
+
# @return [UserServiceReactivateUserResponse]
|
1209
|
+
def user_service_reactivate_user(user_id, opts = {})
|
1210
|
+
data, _status_code, _headers = user_service_reactivate_user_with_http_info(user_id, opts)
|
1211
|
+
data
|
1212
|
+
end
|
1213
|
+
|
1214
|
+
# Reactivate user
|
1215
|
+
# Reactivate a user with the state 'deactivated'. The user will be able to log in again afterward. The endpoint returns an error if the user is not in the state 'deactivated'..
|
1216
|
+
# @param user_id [String]
|
1217
|
+
# @param [Hash] opts the optional parameters
|
1218
|
+
# @return [Array<(UserServiceReactivateUserResponse, Integer, Hash)>] UserServiceReactivateUserResponse data, response status code and response headers
|
1219
|
+
def user_service_reactivate_user_with_http_info(user_id, opts = {})
|
1220
|
+
if @api_client.config.debugging
|
1221
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_reactivate_user ...'
|
1222
|
+
end
|
1223
|
+
# verify the required parameter 'user_id' is set
|
1224
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
1225
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_reactivate_user"
|
1226
|
+
end
|
1227
|
+
# resource path
|
1228
|
+
local_var_path = '/v2/users/{userId}/reactivate'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
1229
|
+
|
1230
|
+
# query parameters
|
1231
|
+
query_params = opts[:query_params] || {}
|
1232
|
+
|
1233
|
+
# header parameters
|
1234
|
+
header_params = opts[:header_params] || {}
|
1235
|
+
# HTTP header 'Accept' (if needed)
|
1236
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
1237
|
+
# HTTP header 'Content-Type'
|
1238
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
1239
|
+
if !content_type.nil?
|
1240
|
+
header_params['Content-Type'] = content_type
|
1241
|
+
end
|
1242
|
+
|
1243
|
+
# form parameters
|
1244
|
+
form_params = opts[:form_params] || {}
|
1245
|
+
|
1246
|
+
# http body (model)
|
1247
|
+
post_body = opts[:debug_body]
|
1248
|
+
|
1249
|
+
# return_type
|
1250
|
+
return_type = opts[:debug_return_type] || 'UserServiceReactivateUserResponse'
|
1251
|
+
|
1252
|
+
# auth_names
|
1253
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
1254
|
+
|
1255
|
+
new_options = opts.merge(
|
1256
|
+
:operation => :"UserServiceApi.user_service_reactivate_user",
|
1257
|
+
:header_params => header_params,
|
1258
|
+
:query_params => query_params,
|
1259
|
+
:form_params => form_params,
|
1260
|
+
:body => post_body,
|
1261
|
+
:auth_names => auth_names,
|
1262
|
+
:return_type => return_type
|
1263
|
+
)
|
1264
|
+
|
1265
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1266
|
+
if @api_client.config.debugging
|
1267
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_reactivate_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1268
|
+
end
|
1269
|
+
return data, status_code, headers
|
1270
|
+
end
|
1271
|
+
|
1272
|
+
# Start the registration of passkey for a user
|
1273
|
+
# Start the registration of a passkey for a user, as a response the public key credential creation options are returned, which are used to verify the passkey..
|
1274
|
+
# @param user_id [String]
|
1275
|
+
# @param user_service_register_passkey_request [UserServiceRegisterPasskeyRequest]
|
1276
|
+
# @param [Hash] opts the optional parameters
|
1277
|
+
# @return [UserServiceRegisterPasskeyResponse]
|
1278
|
+
def user_service_register_passkey(user_id, user_service_register_passkey_request, opts = {})
|
1279
|
+
data, _status_code, _headers = user_service_register_passkey_with_http_info(user_id, user_service_register_passkey_request, opts)
|
1280
|
+
data
|
1281
|
+
end
|
1282
|
+
|
1283
|
+
# Start the registration of passkey for a user
|
1284
|
+
# Start the registration of a passkey for a user, as a response the public key credential creation options are returned, which are used to verify the passkey..
|
1285
|
+
# @param user_id [String]
|
1286
|
+
# @param user_service_register_passkey_request [UserServiceRegisterPasskeyRequest]
|
1287
|
+
# @param [Hash] opts the optional parameters
|
1288
|
+
# @return [Array<(UserServiceRegisterPasskeyResponse, Integer, Hash)>] UserServiceRegisterPasskeyResponse data, response status code and response headers
|
1289
|
+
def user_service_register_passkey_with_http_info(user_id, user_service_register_passkey_request, opts = {})
|
1290
|
+
if @api_client.config.debugging
|
1291
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_register_passkey ...'
|
1292
|
+
end
|
1293
|
+
# verify the required parameter 'user_id' is set
|
1294
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
1295
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_register_passkey"
|
1296
|
+
end
|
1297
|
+
# verify the required parameter 'user_service_register_passkey_request' is set
|
1298
|
+
if @api_client.config.client_side_validation && user_service_register_passkey_request.nil?
|
1299
|
+
fail ArgumentError, "Missing the required parameter 'user_service_register_passkey_request' when calling UserServiceApi.user_service_register_passkey"
|
1300
|
+
end
|
1301
|
+
# resource path
|
1302
|
+
local_var_path = '/v2/users/{userId}/passkeys'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
1303
|
+
|
1304
|
+
# query parameters
|
1305
|
+
query_params = opts[:query_params] || {}
|
1306
|
+
|
1307
|
+
# header parameters
|
1308
|
+
header_params = opts[:header_params] || {}
|
1309
|
+
# HTTP header 'Accept' (if needed)
|
1310
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
1311
|
+
# HTTP header 'Content-Type'
|
1312
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
1313
|
+
if !content_type.nil?
|
1314
|
+
header_params['Content-Type'] = content_type
|
1315
|
+
end
|
1316
|
+
|
1317
|
+
# form parameters
|
1318
|
+
form_params = opts[:form_params] || {}
|
1319
|
+
|
1320
|
+
# http body (model)
|
1321
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_register_passkey_request)
|
1322
|
+
|
1323
|
+
# return_type
|
1324
|
+
return_type = opts[:debug_return_type] || 'UserServiceRegisterPasskeyResponse'
|
1325
|
+
|
1326
|
+
# auth_names
|
1327
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
1328
|
+
|
1329
|
+
new_options = opts.merge(
|
1330
|
+
:operation => :"UserServiceApi.user_service_register_passkey",
|
1331
|
+
:header_params => header_params,
|
1332
|
+
:query_params => query_params,
|
1333
|
+
:form_params => form_params,
|
1334
|
+
:body => post_body,
|
1335
|
+
:auth_names => auth_names,
|
1336
|
+
:return_type => return_type
|
1337
|
+
)
|
1338
|
+
|
1339
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1340
|
+
if @api_client.config.debugging
|
1341
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_register_passkey\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1342
|
+
end
|
1343
|
+
return data, status_code, headers
|
1344
|
+
end
|
1345
|
+
|
1346
|
+
# Start the registration of a TOTP generator for a user
|
1347
|
+
# Start the registration of a TOTP generator for a user, as a response a secret returned, which is used to initialize a TOTP app or device..
|
1348
|
+
# @param user_id [String]
|
1349
|
+
# @param [Hash] opts the optional parameters
|
1350
|
+
# @return [UserServiceRegisterTOTPResponse]
|
1351
|
+
def user_service_register_totp(user_id, opts = {})
|
1352
|
+
data, _status_code, _headers = user_service_register_totp_with_http_info(user_id, opts)
|
1353
|
+
data
|
1354
|
+
end
|
1355
|
+
|
1356
|
+
# Start the registration of a TOTP generator for a user
|
1357
|
+
# Start the registration of a TOTP generator for a user, as a response a secret returned, which is used to initialize a TOTP app or device..
|
1358
|
+
# @param user_id [String]
|
1359
|
+
# @param [Hash] opts the optional parameters
|
1360
|
+
# @return [Array<(UserServiceRegisterTOTPResponse, Integer, Hash)>] UserServiceRegisterTOTPResponse data, response status code and response headers
|
1361
|
+
def user_service_register_totp_with_http_info(user_id, opts = {})
|
1362
|
+
if @api_client.config.debugging
|
1363
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_register_totp ...'
|
1364
|
+
end
|
1365
|
+
# verify the required parameter 'user_id' is set
|
1366
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
1367
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_register_totp"
|
1368
|
+
end
|
1369
|
+
# resource path
|
1370
|
+
local_var_path = '/v2/users/{userId}/totp'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
1371
|
+
|
1372
|
+
# query parameters
|
1373
|
+
query_params = opts[:query_params] || {}
|
1374
|
+
|
1375
|
+
# header parameters
|
1376
|
+
header_params = opts[:header_params] || {}
|
1377
|
+
# HTTP header 'Accept' (if needed)
|
1378
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
1379
|
+
# HTTP header 'Content-Type'
|
1380
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
1381
|
+
if !content_type.nil?
|
1382
|
+
header_params['Content-Type'] = content_type
|
1383
|
+
end
|
1384
|
+
|
1385
|
+
# form parameters
|
1386
|
+
form_params = opts[:form_params] || {}
|
1387
|
+
|
1388
|
+
# http body (model)
|
1389
|
+
post_body = opts[:debug_body]
|
1390
|
+
|
1391
|
+
# return_type
|
1392
|
+
return_type = opts[:debug_return_type] || 'UserServiceRegisterTOTPResponse'
|
1393
|
+
|
1394
|
+
# auth_names
|
1395
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
1396
|
+
|
1397
|
+
new_options = opts.merge(
|
1398
|
+
:operation => :"UserServiceApi.user_service_register_totp",
|
1399
|
+
:header_params => header_params,
|
1400
|
+
:query_params => query_params,
|
1401
|
+
:form_params => form_params,
|
1402
|
+
:body => post_body,
|
1403
|
+
:auth_names => auth_names,
|
1404
|
+
:return_type => return_type
|
1405
|
+
)
|
1406
|
+
|
1407
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1408
|
+
if @api_client.config.debugging
|
1409
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_register_totp\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1410
|
+
end
|
1411
|
+
return data, status_code, headers
|
1412
|
+
end
|
1413
|
+
|
1414
|
+
# Start the registration of a u2f token for a user
|
1415
|
+
# Start the registration of a u2f token for a user, as a response the public key credential creation options are returned, which are used to verify the u2f token..
|
1416
|
+
# @param user_id [String]
|
1417
|
+
# @param user_service_register_u2_f_request [UserServiceRegisterU2FRequest]
|
1418
|
+
# @param [Hash] opts the optional parameters
|
1419
|
+
# @return [UserServiceRegisterU2FResponse]
|
1420
|
+
def user_service_register_u2_f(user_id, user_service_register_u2_f_request, opts = {})
|
1421
|
+
data, _status_code, _headers = user_service_register_u2_f_with_http_info(user_id, user_service_register_u2_f_request, opts)
|
1422
|
+
data
|
1423
|
+
end
|
1424
|
+
|
1425
|
+
# Start the registration of a u2f token for a user
|
1426
|
+
# Start the registration of a u2f token for a user, as a response the public key credential creation options are returned, which are used to verify the u2f token..
|
1427
|
+
# @param user_id [String]
|
1428
|
+
# @param user_service_register_u2_f_request [UserServiceRegisterU2FRequest]
|
1429
|
+
# @param [Hash] opts the optional parameters
|
1430
|
+
# @return [Array<(UserServiceRegisterU2FResponse, Integer, Hash)>] UserServiceRegisterU2FResponse data, response status code and response headers
|
1431
|
+
def user_service_register_u2_f_with_http_info(user_id, user_service_register_u2_f_request, opts = {})
|
1432
|
+
if @api_client.config.debugging
|
1433
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_register_u2_f ...'
|
1434
|
+
end
|
1435
|
+
# verify the required parameter 'user_id' is set
|
1436
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
1437
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_register_u2_f"
|
1438
|
+
end
|
1439
|
+
# verify the required parameter 'user_service_register_u2_f_request' is set
|
1440
|
+
if @api_client.config.client_side_validation && user_service_register_u2_f_request.nil?
|
1441
|
+
fail ArgumentError, "Missing the required parameter 'user_service_register_u2_f_request' when calling UserServiceApi.user_service_register_u2_f"
|
1442
|
+
end
|
1443
|
+
# resource path
|
1444
|
+
local_var_path = '/v2/users/{userId}/u2f'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
1445
|
+
|
1446
|
+
# query parameters
|
1447
|
+
query_params = opts[:query_params] || {}
|
1448
|
+
|
1449
|
+
# header parameters
|
1450
|
+
header_params = opts[:header_params] || {}
|
1451
|
+
# HTTP header 'Accept' (if needed)
|
1452
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
1453
|
+
# HTTP header 'Content-Type'
|
1454
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
1455
|
+
if !content_type.nil?
|
1456
|
+
header_params['Content-Type'] = content_type
|
1457
|
+
end
|
1458
|
+
|
1459
|
+
# form parameters
|
1460
|
+
form_params = opts[:form_params] || {}
|
1461
|
+
|
1462
|
+
# http body (model)
|
1463
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_register_u2_f_request)
|
1464
|
+
|
1465
|
+
# return_type
|
1466
|
+
return_type = opts[:debug_return_type] || 'UserServiceRegisterU2FResponse'
|
1467
|
+
|
1468
|
+
# auth_names
|
1469
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
1470
|
+
|
1471
|
+
new_options = opts.merge(
|
1472
|
+
:operation => :"UserServiceApi.user_service_register_u2_f",
|
1473
|
+
:header_params => header_params,
|
1474
|
+
:query_params => query_params,
|
1475
|
+
:form_params => form_params,
|
1476
|
+
:body => post_body,
|
1477
|
+
:auth_names => auth_names,
|
1478
|
+
:return_type => return_type
|
1479
|
+
)
|
1480
|
+
|
1481
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1482
|
+
if @api_client.config.debugging
|
1483
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_register_u2_f\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1484
|
+
end
|
1485
|
+
return data, status_code, headers
|
1486
|
+
end
|
1487
|
+
|
1488
|
+
# Remove link of an identity provider to an user
|
1489
|
+
# Remove link of an identity provider to an user.
|
1490
|
+
# @param user_id [String]
|
1491
|
+
# @param idp_id [String]
|
1492
|
+
# @param linked_user_id [String]
|
1493
|
+
# @param [Hash] opts the optional parameters
|
1494
|
+
# @return [UserServiceRemoveIDPLinkResponse]
|
1495
|
+
def user_service_remove_idp_link(user_id, idp_id, linked_user_id, opts = {})
|
1496
|
+
data, _status_code, _headers = user_service_remove_idp_link_with_http_info(user_id, idp_id, linked_user_id, opts)
|
1497
|
+
data
|
1498
|
+
end
|
1499
|
+
|
1500
|
+
# Remove link of an identity provider to an user
|
1501
|
+
# Remove link of an identity provider to an user.
|
1502
|
+
# @param user_id [String]
|
1503
|
+
# @param idp_id [String]
|
1504
|
+
# @param linked_user_id [String]
|
1505
|
+
# @param [Hash] opts the optional parameters
|
1506
|
+
# @return [Array<(UserServiceRemoveIDPLinkResponse, Integer, Hash)>] UserServiceRemoveIDPLinkResponse data, response status code and response headers
|
1507
|
+
def user_service_remove_idp_link_with_http_info(user_id, idp_id, linked_user_id, opts = {})
|
1508
|
+
if @api_client.config.debugging
|
1509
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_remove_idp_link ...'
|
1510
|
+
end
|
1511
|
+
# verify the required parameter 'user_id' is set
|
1512
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
1513
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_remove_idp_link"
|
1514
|
+
end
|
1515
|
+
# verify the required parameter 'idp_id' is set
|
1516
|
+
if @api_client.config.client_side_validation && idp_id.nil?
|
1517
|
+
fail ArgumentError, "Missing the required parameter 'idp_id' when calling UserServiceApi.user_service_remove_idp_link"
|
1518
|
+
end
|
1519
|
+
# verify the required parameter 'linked_user_id' is set
|
1520
|
+
if @api_client.config.client_side_validation && linked_user_id.nil?
|
1521
|
+
fail ArgumentError, "Missing the required parameter 'linked_user_id' when calling UserServiceApi.user_service_remove_idp_link"
|
1522
|
+
end
|
1523
|
+
# resource path
|
1524
|
+
local_var_path = '/v2/users/{userId}/links/{idpId}/{linkedUserId}'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s)).sub('{' + 'idpId' + '}', CGI.escape(idp_id.to_s)).sub('{' + 'linkedUserId' + '}', CGI.escape(linked_user_id.to_s))
|
1525
|
+
|
1526
|
+
# query parameters
|
1527
|
+
query_params = opts[:query_params] || {}
|
1528
|
+
|
1529
|
+
# header parameters
|
1530
|
+
header_params = opts[:header_params] || {}
|
1531
|
+
# HTTP header 'Accept' (if needed)
|
1532
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
1533
|
+
# HTTP header 'Content-Type'
|
1534
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
1535
|
+
if !content_type.nil?
|
1536
|
+
header_params['Content-Type'] = content_type
|
1537
|
+
end
|
1538
|
+
|
1539
|
+
# form parameters
|
1540
|
+
form_params = opts[:form_params] || {}
|
1541
|
+
|
1542
|
+
# http body (model)
|
1543
|
+
post_body = opts[:debug_body]
|
1544
|
+
|
1545
|
+
# return_type
|
1546
|
+
return_type = opts[:debug_return_type] || 'UserServiceRemoveIDPLinkResponse'
|
1547
|
+
|
1548
|
+
# auth_names
|
1549
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
1550
|
+
|
1551
|
+
new_options = opts.merge(
|
1552
|
+
:operation => :"UserServiceApi.user_service_remove_idp_link",
|
1553
|
+
:header_params => header_params,
|
1554
|
+
:query_params => query_params,
|
1555
|
+
:form_params => form_params,
|
1556
|
+
:body => post_body,
|
1557
|
+
:auth_names => auth_names,
|
1558
|
+
:return_type => return_type
|
1559
|
+
)
|
1560
|
+
|
1561
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
1562
|
+
if @api_client.config.debugging
|
1563
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_remove_idp_link\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1564
|
+
end
|
1565
|
+
return data, status_code, headers
|
1566
|
+
end
|
1567
|
+
|
1568
|
+
# Remove One-Time Password (OTP) Email from a user
|
1569
|
+
# Remove the configured One-Time Password (OTP) Email factor of a user. As only one OTP Email per user is allowed, the user will not have OTP Email as a second factor afterward.
|
1570
|
+
# @param user_id [String]
|
1571
|
+
# @param [Hash] opts the optional parameters
|
1572
|
+
# @return [UserServiceRemoveOTPEmailResponse]
|
1573
|
+
def user_service_remove_otp_email(user_id, opts = {})
|
1574
|
+
data, _status_code, _headers = user_service_remove_otp_email_with_http_info(user_id, opts)
|
1575
|
+
data
|
1576
|
+
end
|
1577
|
+
|
1578
|
+
# Remove One-Time Password (OTP) Email from a user
|
1579
|
+
# Remove the configured One-Time Password (OTP) Email factor of a user. As only one OTP Email per user is allowed, the user will not have OTP Email as a second factor afterward.
|
1580
|
+
# @param user_id [String]
|
1581
|
+
# @param [Hash] opts the optional parameters
|
1582
|
+
# @return [Array<(UserServiceRemoveOTPEmailResponse, Integer, Hash)>] UserServiceRemoveOTPEmailResponse data, response status code and response headers
|
1583
|
+
def user_service_remove_otp_email_with_http_info(user_id, opts = {})
|
1584
|
+
if @api_client.config.debugging
|
1585
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_remove_otp_email ...'
|
1586
|
+
end
|
1587
|
+
# verify the required parameter 'user_id' is set
|
1588
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
1589
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_remove_otp_email"
|
1590
|
+
end
|
1591
|
+
# resource path
|
1592
|
+
local_var_path = '/v2/users/{userId}/otp_email'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
1593
|
+
|
1594
|
+
# query parameters
|
1595
|
+
query_params = opts[:query_params] || {}
|
1596
|
+
|
1597
|
+
# header parameters
|
1598
|
+
header_params = opts[:header_params] || {}
|
1599
|
+
# HTTP header 'Accept' (if needed)
|
1600
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
1601
|
+
|
1602
|
+
# form parameters
|
1603
|
+
form_params = opts[:form_params] || {}
|
1604
|
+
|
1605
|
+
# http body (model)
|
1606
|
+
post_body = opts[:debug_body]
|
1607
|
+
|
1608
|
+
# return_type
|
1609
|
+
return_type = opts[:debug_return_type] || 'UserServiceRemoveOTPEmailResponse'
|
1610
|
+
|
1611
|
+
# auth_names
|
1612
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
1613
|
+
|
1614
|
+
new_options = opts.merge(
|
1615
|
+
:operation => :"UserServiceApi.user_service_remove_otp_email",
|
1616
|
+
:header_params => header_params,
|
1617
|
+
:query_params => query_params,
|
1618
|
+
:form_params => form_params,
|
1619
|
+
:body => post_body,
|
1620
|
+
:auth_names => auth_names,
|
1621
|
+
:return_type => return_type
|
1622
|
+
)
|
1623
|
+
|
1624
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
1625
|
+
if @api_client.config.debugging
|
1626
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_remove_otp_email\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1627
|
+
end
|
1628
|
+
return data, status_code, headers
|
1629
|
+
end
|
1630
|
+
|
1631
|
+
# Remove One-Time Password (OTP) SMS from a user
|
1632
|
+
# Remove the configured One-Time Password (OTP) SMS factor of a user. As only one OTP SMS per user is allowed, the user will not have OTP SMS as a second factor afterward.
|
1633
|
+
# @param user_id [String]
|
1634
|
+
# @param [Hash] opts the optional parameters
|
1635
|
+
# @return [UserServiceRemoveOTPSMSResponse]
|
1636
|
+
def user_service_remove_otpsms(user_id, opts = {})
|
1637
|
+
data, _status_code, _headers = user_service_remove_otpsms_with_http_info(user_id, opts)
|
1638
|
+
data
|
1639
|
+
end
|
1640
|
+
|
1641
|
+
# Remove One-Time Password (OTP) SMS from a user
|
1642
|
+
# Remove the configured One-Time Password (OTP) SMS factor of a user. As only one OTP SMS per user is allowed, the user will not have OTP SMS as a second factor afterward.
|
1643
|
+
# @param user_id [String]
|
1644
|
+
# @param [Hash] opts the optional parameters
|
1645
|
+
# @return [Array<(UserServiceRemoveOTPSMSResponse, Integer, Hash)>] UserServiceRemoveOTPSMSResponse data, response status code and response headers
|
1646
|
+
def user_service_remove_otpsms_with_http_info(user_id, opts = {})
|
1647
|
+
if @api_client.config.debugging
|
1648
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_remove_otpsms ...'
|
1649
|
+
end
|
1650
|
+
# verify the required parameter 'user_id' is set
|
1651
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
1652
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_remove_otpsms"
|
1653
|
+
end
|
1654
|
+
# resource path
|
1655
|
+
local_var_path = '/v2/users/{userId}/otp_sms'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
1656
|
+
|
1657
|
+
# query parameters
|
1658
|
+
query_params = opts[:query_params] || {}
|
1659
|
+
|
1660
|
+
# header parameters
|
1661
|
+
header_params = opts[:header_params] || {}
|
1662
|
+
# HTTP header 'Accept' (if needed)
|
1663
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
1664
|
+
|
1665
|
+
# form parameters
|
1666
|
+
form_params = opts[:form_params] || {}
|
1667
|
+
|
1668
|
+
# http body (model)
|
1669
|
+
post_body = opts[:debug_body]
|
1670
|
+
|
1671
|
+
# return_type
|
1672
|
+
return_type = opts[:debug_return_type] || 'UserServiceRemoveOTPSMSResponse'
|
1673
|
+
|
1674
|
+
# auth_names
|
1675
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
1676
|
+
|
1677
|
+
new_options = opts.merge(
|
1678
|
+
:operation => :"UserServiceApi.user_service_remove_otpsms",
|
1679
|
+
:header_params => header_params,
|
1680
|
+
:query_params => query_params,
|
1681
|
+
:form_params => form_params,
|
1682
|
+
:body => post_body,
|
1683
|
+
:auth_names => auth_names,
|
1684
|
+
:return_type => return_type
|
1685
|
+
)
|
1686
|
+
|
1687
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
1688
|
+
if @api_client.config.debugging
|
1689
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_remove_otpsms\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1690
|
+
end
|
1691
|
+
return data, status_code, headers
|
1692
|
+
end
|
1693
|
+
|
1694
|
+
# Remove passkey from a user
|
1695
|
+
# Remove passkey from a user.
|
1696
|
+
# @param user_id [String]
|
1697
|
+
# @param passkey_id [String]
|
1698
|
+
# @param [Hash] opts the optional parameters
|
1699
|
+
# @return [UserServiceRemovePasskeyResponse]
|
1700
|
+
def user_service_remove_passkey(user_id, passkey_id, opts = {})
|
1701
|
+
data, _status_code, _headers = user_service_remove_passkey_with_http_info(user_id, passkey_id, opts)
|
1702
|
+
data
|
1703
|
+
end
|
1704
|
+
|
1705
|
+
# Remove passkey from a user
|
1706
|
+
# Remove passkey from a user.
|
1707
|
+
# @param user_id [String]
|
1708
|
+
# @param passkey_id [String]
|
1709
|
+
# @param [Hash] opts the optional parameters
|
1710
|
+
# @return [Array<(UserServiceRemovePasskeyResponse, Integer, Hash)>] UserServiceRemovePasskeyResponse data, response status code and response headers
|
1711
|
+
def user_service_remove_passkey_with_http_info(user_id, passkey_id, opts = {})
|
1712
|
+
if @api_client.config.debugging
|
1713
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_remove_passkey ...'
|
1714
|
+
end
|
1715
|
+
# verify the required parameter 'user_id' is set
|
1716
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
1717
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_remove_passkey"
|
1718
|
+
end
|
1719
|
+
# verify the required parameter 'passkey_id' is set
|
1720
|
+
if @api_client.config.client_side_validation && passkey_id.nil?
|
1721
|
+
fail ArgumentError, "Missing the required parameter 'passkey_id' when calling UserServiceApi.user_service_remove_passkey"
|
1722
|
+
end
|
1723
|
+
# resource path
|
1724
|
+
local_var_path = '/v2/users/{userId}/passkeys/{passkeyId}'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s)).sub('{' + 'passkeyId' + '}', CGI.escape(passkey_id.to_s))
|
1725
|
+
|
1726
|
+
# query parameters
|
1727
|
+
query_params = opts[:query_params] || {}
|
1728
|
+
|
1729
|
+
# header parameters
|
1730
|
+
header_params = opts[:header_params] || {}
|
1731
|
+
# HTTP header 'Accept' (if needed)
|
1732
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
1733
|
+
|
1734
|
+
# form parameters
|
1735
|
+
form_params = opts[:form_params] || {}
|
1736
|
+
|
1737
|
+
# http body (model)
|
1738
|
+
post_body = opts[:debug_body]
|
1739
|
+
|
1740
|
+
# return_type
|
1741
|
+
return_type = opts[:debug_return_type] || 'UserServiceRemovePasskeyResponse'
|
1742
|
+
|
1743
|
+
# auth_names
|
1744
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
1745
|
+
|
1746
|
+
new_options = opts.merge(
|
1747
|
+
:operation => :"UserServiceApi.user_service_remove_passkey",
|
1748
|
+
:header_params => header_params,
|
1749
|
+
:query_params => query_params,
|
1750
|
+
:form_params => form_params,
|
1751
|
+
:body => post_body,
|
1752
|
+
:auth_names => auth_names,
|
1753
|
+
:return_type => return_type
|
1754
|
+
)
|
1755
|
+
|
1756
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
1757
|
+
if @api_client.config.debugging
|
1758
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_remove_passkey\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1759
|
+
end
|
1760
|
+
return data, status_code, headers
|
1761
|
+
end
|
1762
|
+
|
1763
|
+
# Delete the user phone
|
1764
|
+
# Delete the phone number of a user.
|
1765
|
+
# @param user_id [String]
|
1766
|
+
# @param [Hash] opts the optional parameters
|
1767
|
+
# @return [UserServiceRemovePhoneResponse]
|
1768
|
+
def user_service_remove_phone(user_id, opts = {})
|
1769
|
+
data, _status_code, _headers = user_service_remove_phone_with_http_info(user_id, opts)
|
1770
|
+
data
|
1771
|
+
end
|
1772
|
+
|
1773
|
+
# Delete the user phone
|
1774
|
+
# Delete the phone number of a user.
|
1775
|
+
# @param user_id [String]
|
1776
|
+
# @param [Hash] opts the optional parameters
|
1777
|
+
# @return [Array<(UserServiceRemovePhoneResponse, Integer, Hash)>] UserServiceRemovePhoneResponse data, response status code and response headers
|
1778
|
+
def user_service_remove_phone_with_http_info(user_id, opts = {})
|
1779
|
+
if @api_client.config.debugging
|
1780
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_remove_phone ...'
|
1781
|
+
end
|
1782
|
+
# verify the required parameter 'user_id' is set
|
1783
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
1784
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_remove_phone"
|
1785
|
+
end
|
1786
|
+
# resource path
|
1787
|
+
local_var_path = '/v2/users/{userId}/phone'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
1788
|
+
|
1789
|
+
# query parameters
|
1790
|
+
query_params = opts[:query_params] || {}
|
1791
|
+
|
1792
|
+
# header parameters
|
1793
|
+
header_params = opts[:header_params] || {}
|
1794
|
+
# HTTP header 'Accept' (if needed)
|
1795
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
1796
|
+
# HTTP header 'Content-Type'
|
1797
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
1798
|
+
if !content_type.nil?
|
1799
|
+
header_params['Content-Type'] = content_type
|
1800
|
+
end
|
1801
|
+
|
1802
|
+
# form parameters
|
1803
|
+
form_params = opts[:form_params] || {}
|
1804
|
+
|
1805
|
+
# http body (model)
|
1806
|
+
post_body = opts[:debug_body]
|
1807
|
+
|
1808
|
+
# return_type
|
1809
|
+
return_type = opts[:debug_return_type] || 'UserServiceRemovePhoneResponse'
|
1810
|
+
|
1811
|
+
# auth_names
|
1812
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
1813
|
+
|
1814
|
+
new_options = opts.merge(
|
1815
|
+
:operation => :"UserServiceApi.user_service_remove_phone",
|
1816
|
+
:header_params => header_params,
|
1817
|
+
:query_params => query_params,
|
1818
|
+
:form_params => form_params,
|
1819
|
+
:body => post_body,
|
1820
|
+
:auth_names => auth_names,
|
1821
|
+
:return_type => return_type
|
1822
|
+
)
|
1823
|
+
|
1824
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
1825
|
+
if @api_client.config.debugging
|
1826
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_remove_phone\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1827
|
+
end
|
1828
|
+
return data, status_code, headers
|
1829
|
+
end
|
1830
|
+
|
1831
|
+
# Remove TOTP generator from a user
|
1832
|
+
# Remove the configured TOTP generator of a user. As only one TOTP generator per user is allowed, the user will not have TOTP as a second factor afterward.
|
1833
|
+
# @param user_id [String]
|
1834
|
+
# @param [Hash] opts the optional parameters
|
1835
|
+
# @return [UserServiceRemoveTOTPResponse]
|
1836
|
+
def user_service_remove_totp(user_id, opts = {})
|
1837
|
+
data, _status_code, _headers = user_service_remove_totp_with_http_info(user_id, opts)
|
1838
|
+
data
|
1839
|
+
end
|
1840
|
+
|
1841
|
+
# Remove TOTP generator from a user
|
1842
|
+
# Remove the configured TOTP generator of a user. As only one TOTP generator per user is allowed, the user will not have TOTP as a second factor afterward.
|
1843
|
+
# @param user_id [String]
|
1844
|
+
# @param [Hash] opts the optional parameters
|
1845
|
+
# @return [Array<(UserServiceRemoveTOTPResponse, Integer, Hash)>] UserServiceRemoveTOTPResponse data, response status code and response headers
|
1846
|
+
def user_service_remove_totp_with_http_info(user_id, opts = {})
|
1847
|
+
if @api_client.config.debugging
|
1848
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_remove_totp ...'
|
1849
|
+
end
|
1850
|
+
# verify the required parameter 'user_id' is set
|
1851
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
1852
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_remove_totp"
|
1853
|
+
end
|
1854
|
+
# resource path
|
1855
|
+
local_var_path = '/v2/users/{userId}/totp'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
1856
|
+
|
1857
|
+
# query parameters
|
1858
|
+
query_params = opts[:query_params] || {}
|
1859
|
+
|
1860
|
+
# header parameters
|
1861
|
+
header_params = opts[:header_params] || {}
|
1862
|
+
# HTTP header 'Accept' (if needed)
|
1863
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
1864
|
+
|
1865
|
+
# form parameters
|
1866
|
+
form_params = opts[:form_params] || {}
|
1867
|
+
|
1868
|
+
# http body (model)
|
1869
|
+
post_body = opts[:debug_body]
|
1870
|
+
|
1871
|
+
# return_type
|
1872
|
+
return_type = opts[:debug_return_type] || 'UserServiceRemoveTOTPResponse'
|
1873
|
+
|
1874
|
+
# auth_names
|
1875
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
1876
|
+
|
1877
|
+
new_options = opts.merge(
|
1878
|
+
:operation => :"UserServiceApi.user_service_remove_totp",
|
1879
|
+
:header_params => header_params,
|
1880
|
+
:query_params => query_params,
|
1881
|
+
:form_params => form_params,
|
1882
|
+
:body => post_body,
|
1883
|
+
:auth_names => auth_names,
|
1884
|
+
:return_type => return_type
|
1885
|
+
)
|
1886
|
+
|
1887
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
1888
|
+
if @api_client.config.debugging
|
1889
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_remove_totp\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1890
|
+
end
|
1891
|
+
return data, status_code, headers
|
1892
|
+
end
|
1893
|
+
|
1894
|
+
# Remove u2f token from a user
|
1895
|
+
# Remove u2f token from a user
|
1896
|
+
# @param user_id [String]
|
1897
|
+
# @param u2f_id [String]
|
1898
|
+
# @param [Hash] opts the optional parameters
|
1899
|
+
# @return [UserServiceRemoveU2FResponse]
|
1900
|
+
def user_service_remove_u2_f(user_id, u2f_id, opts = {})
|
1901
|
+
data, _status_code, _headers = user_service_remove_u2_f_with_http_info(user_id, u2f_id, opts)
|
1902
|
+
data
|
1903
|
+
end
|
1904
|
+
|
1905
|
+
# Remove u2f token from a user
|
1906
|
+
# Remove u2f token from a user
|
1907
|
+
# @param user_id [String]
|
1908
|
+
# @param u2f_id [String]
|
1909
|
+
# @param [Hash] opts the optional parameters
|
1910
|
+
# @return [Array<(UserServiceRemoveU2FResponse, Integer, Hash)>] UserServiceRemoveU2FResponse data, response status code and response headers
|
1911
|
+
def user_service_remove_u2_f_with_http_info(user_id, u2f_id, opts = {})
|
1912
|
+
if @api_client.config.debugging
|
1913
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_remove_u2_f ...'
|
1914
|
+
end
|
1915
|
+
# verify the required parameter 'user_id' is set
|
1916
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
1917
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_remove_u2_f"
|
1918
|
+
end
|
1919
|
+
# verify the required parameter 'u2f_id' is set
|
1920
|
+
if @api_client.config.client_side_validation && u2f_id.nil?
|
1921
|
+
fail ArgumentError, "Missing the required parameter 'u2f_id' when calling UserServiceApi.user_service_remove_u2_f"
|
1922
|
+
end
|
1923
|
+
# resource path
|
1924
|
+
local_var_path = '/v2/users/{userId}/u2f/{u2fId}'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s)).sub('{' + 'u2fId' + '}', CGI.escape(u2f_id.to_s))
|
1925
|
+
|
1926
|
+
# query parameters
|
1927
|
+
query_params = opts[:query_params] || {}
|
1928
|
+
|
1929
|
+
# header parameters
|
1930
|
+
header_params = opts[:header_params] || {}
|
1931
|
+
# HTTP header 'Accept' (if needed)
|
1932
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
1933
|
+
|
1934
|
+
# form parameters
|
1935
|
+
form_params = opts[:form_params] || {}
|
1936
|
+
|
1937
|
+
# http body (model)
|
1938
|
+
post_body = opts[:debug_body]
|
1939
|
+
|
1940
|
+
# return_type
|
1941
|
+
return_type = opts[:debug_return_type] || 'UserServiceRemoveU2FResponse'
|
1942
|
+
|
1943
|
+
# auth_names
|
1944
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
1945
|
+
|
1946
|
+
new_options = opts.merge(
|
1947
|
+
:operation => :"UserServiceApi.user_service_remove_u2_f",
|
1948
|
+
:header_params => header_params,
|
1949
|
+
:query_params => query_params,
|
1950
|
+
:form_params => form_params,
|
1951
|
+
:body => post_body,
|
1952
|
+
:auth_names => auth_names,
|
1953
|
+
:return_type => return_type
|
1954
|
+
)
|
1955
|
+
|
1956
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
1957
|
+
if @api_client.config.debugging
|
1958
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_remove_u2_f\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1959
|
+
end
|
1960
|
+
return data, status_code, headers
|
1961
|
+
end
|
1962
|
+
|
1963
|
+
# Resend code to verify user email
|
1964
|
+
# Resend code to verify user email.
|
1965
|
+
# @param user_id [String]
|
1966
|
+
# @param user_service_resend_email_code_request [UserServiceResendEmailCodeRequest]
|
1967
|
+
# @param [Hash] opts the optional parameters
|
1968
|
+
# @return [UserServiceResendEmailCodeResponse]
|
1969
|
+
def user_service_resend_email_code(user_id, user_service_resend_email_code_request, opts = {})
|
1970
|
+
data, _status_code, _headers = user_service_resend_email_code_with_http_info(user_id, user_service_resend_email_code_request, opts)
|
1971
|
+
data
|
1972
|
+
end
|
1973
|
+
|
1974
|
+
# Resend code to verify user email
|
1975
|
+
# Resend code to verify user email.
|
1976
|
+
# @param user_id [String]
|
1977
|
+
# @param user_service_resend_email_code_request [UserServiceResendEmailCodeRequest]
|
1978
|
+
# @param [Hash] opts the optional parameters
|
1979
|
+
# @return [Array<(UserServiceResendEmailCodeResponse, Integer, Hash)>] UserServiceResendEmailCodeResponse data, response status code and response headers
|
1980
|
+
def user_service_resend_email_code_with_http_info(user_id, user_service_resend_email_code_request, opts = {})
|
1981
|
+
if @api_client.config.debugging
|
1982
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_resend_email_code ...'
|
1983
|
+
end
|
1984
|
+
# verify the required parameter 'user_id' is set
|
1985
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
1986
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_resend_email_code"
|
1987
|
+
end
|
1988
|
+
# verify the required parameter 'user_service_resend_email_code_request' is set
|
1989
|
+
if @api_client.config.client_side_validation && user_service_resend_email_code_request.nil?
|
1990
|
+
fail ArgumentError, "Missing the required parameter 'user_service_resend_email_code_request' when calling UserServiceApi.user_service_resend_email_code"
|
1991
|
+
end
|
1992
|
+
# resource path
|
1993
|
+
local_var_path = '/v2/users/{userId}/email/resend'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
1994
|
+
|
1995
|
+
# query parameters
|
1996
|
+
query_params = opts[:query_params] || {}
|
1997
|
+
|
1998
|
+
# header parameters
|
1999
|
+
header_params = opts[:header_params] || {}
|
2000
|
+
# HTTP header 'Accept' (if needed)
|
2001
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
2002
|
+
# HTTP header 'Content-Type'
|
2003
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
2004
|
+
if !content_type.nil?
|
2005
|
+
header_params['Content-Type'] = content_type
|
2006
|
+
end
|
2007
|
+
|
2008
|
+
# form parameters
|
2009
|
+
form_params = opts[:form_params] || {}
|
2010
|
+
|
2011
|
+
# http body (model)
|
2012
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_resend_email_code_request)
|
2013
|
+
|
2014
|
+
# return_type
|
2015
|
+
return_type = opts[:debug_return_type] || 'UserServiceResendEmailCodeResponse'
|
2016
|
+
|
2017
|
+
# auth_names
|
2018
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
2019
|
+
|
2020
|
+
new_options = opts.merge(
|
2021
|
+
:operation => :"UserServiceApi.user_service_resend_email_code",
|
2022
|
+
:header_params => header_params,
|
2023
|
+
:query_params => query_params,
|
2024
|
+
:form_params => form_params,
|
2025
|
+
:body => post_body,
|
2026
|
+
:auth_names => auth_names,
|
2027
|
+
:return_type => return_type
|
2028
|
+
)
|
2029
|
+
|
2030
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
2031
|
+
if @api_client.config.debugging
|
2032
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_resend_email_code\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2033
|
+
end
|
2034
|
+
return data, status_code, headers
|
2035
|
+
end
|
2036
|
+
|
2037
|
+
# Resend an invite code for a user
|
2038
|
+
# Resend an invite code for a user to initialize their first authentication method (password, passkeys, IdP) depending on the organization's available methods. A resend is only possible if a code has been created previously and sent to the user. If there is no code or it was directly returned, an error will be returned.
|
2039
|
+
# @param user_id [String]
|
2040
|
+
# @param [Hash] opts the optional parameters
|
2041
|
+
# @return [UserServiceResendInviteCodeResponse]
|
2042
|
+
def user_service_resend_invite_code(user_id, opts = {})
|
2043
|
+
data, _status_code, _headers = user_service_resend_invite_code_with_http_info(user_id, opts)
|
2044
|
+
data
|
2045
|
+
end
|
2046
|
+
|
2047
|
+
# Resend an invite code for a user
|
2048
|
+
# Resend an invite code for a user to initialize their first authentication method (password, passkeys, IdP) depending on the organization's available methods. A resend is only possible if a code has been created previously and sent to the user. If there is no code or it was directly returned, an error will be returned.
|
2049
|
+
# @param user_id [String]
|
2050
|
+
# @param [Hash] opts the optional parameters
|
2051
|
+
# @return [Array<(UserServiceResendInviteCodeResponse, Integer, Hash)>] UserServiceResendInviteCodeResponse data, response status code and response headers
|
2052
|
+
def user_service_resend_invite_code_with_http_info(user_id, opts = {})
|
2053
|
+
if @api_client.config.debugging
|
2054
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_resend_invite_code ...'
|
2055
|
+
end
|
2056
|
+
# verify the required parameter 'user_id' is set
|
2057
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
2058
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_resend_invite_code"
|
2059
|
+
end
|
2060
|
+
# resource path
|
2061
|
+
local_var_path = '/v2/users/{userId}/invite_code/resend'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
2062
|
+
|
2063
|
+
# query parameters
|
2064
|
+
query_params = opts[:query_params] || {}
|
2065
|
+
|
2066
|
+
# header parameters
|
2067
|
+
header_params = opts[:header_params] || {}
|
2068
|
+
# HTTP header 'Accept' (if needed)
|
2069
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
2070
|
+
|
2071
|
+
# form parameters
|
2072
|
+
form_params = opts[:form_params] || {}
|
2073
|
+
|
2074
|
+
# http body (model)
|
2075
|
+
post_body = opts[:debug_body]
|
2076
|
+
|
2077
|
+
# return_type
|
2078
|
+
return_type = opts[:debug_return_type] || 'UserServiceResendInviteCodeResponse'
|
2079
|
+
|
2080
|
+
# auth_names
|
2081
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
2082
|
+
|
2083
|
+
new_options = opts.merge(
|
2084
|
+
:operation => :"UserServiceApi.user_service_resend_invite_code",
|
2085
|
+
:header_params => header_params,
|
2086
|
+
:query_params => query_params,
|
2087
|
+
:form_params => form_params,
|
2088
|
+
:body => post_body,
|
2089
|
+
:auth_names => auth_names,
|
2090
|
+
:return_type => return_type
|
2091
|
+
)
|
2092
|
+
|
2093
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
2094
|
+
if @api_client.config.debugging
|
2095
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_resend_invite_code\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2096
|
+
end
|
2097
|
+
return data, status_code, headers
|
2098
|
+
end
|
2099
|
+
|
2100
|
+
# Resend code to verify user phone
|
2101
|
+
# Resend code to verify user phone.
|
2102
|
+
# @param user_id [String]
|
2103
|
+
# @param user_service_resend_phone_code_request [UserServiceResendPhoneCodeRequest]
|
2104
|
+
# @param [Hash] opts the optional parameters
|
2105
|
+
# @return [UserServiceResendPhoneCodeResponse]
|
2106
|
+
def user_service_resend_phone_code(user_id, user_service_resend_phone_code_request, opts = {})
|
2107
|
+
data, _status_code, _headers = user_service_resend_phone_code_with_http_info(user_id, user_service_resend_phone_code_request, opts)
|
2108
|
+
data
|
2109
|
+
end
|
2110
|
+
|
2111
|
+
# Resend code to verify user phone
|
2112
|
+
# Resend code to verify user phone.
|
2113
|
+
# @param user_id [String]
|
2114
|
+
# @param user_service_resend_phone_code_request [UserServiceResendPhoneCodeRequest]
|
2115
|
+
# @param [Hash] opts the optional parameters
|
2116
|
+
# @return [Array<(UserServiceResendPhoneCodeResponse, Integer, Hash)>] UserServiceResendPhoneCodeResponse data, response status code and response headers
|
2117
|
+
def user_service_resend_phone_code_with_http_info(user_id, user_service_resend_phone_code_request, opts = {})
|
2118
|
+
if @api_client.config.debugging
|
2119
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_resend_phone_code ...'
|
2120
|
+
end
|
2121
|
+
# verify the required parameter 'user_id' is set
|
2122
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
2123
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_resend_phone_code"
|
2124
|
+
end
|
2125
|
+
# verify the required parameter 'user_service_resend_phone_code_request' is set
|
2126
|
+
if @api_client.config.client_side_validation && user_service_resend_phone_code_request.nil?
|
2127
|
+
fail ArgumentError, "Missing the required parameter 'user_service_resend_phone_code_request' when calling UserServiceApi.user_service_resend_phone_code"
|
2128
|
+
end
|
2129
|
+
# resource path
|
2130
|
+
local_var_path = '/v2/users/{userId}/phone/resend'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
2131
|
+
|
2132
|
+
# query parameters
|
2133
|
+
query_params = opts[:query_params] || {}
|
2134
|
+
|
2135
|
+
# header parameters
|
2136
|
+
header_params = opts[:header_params] || {}
|
2137
|
+
# HTTP header 'Accept' (if needed)
|
2138
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
2139
|
+
# HTTP header 'Content-Type'
|
2140
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
2141
|
+
if !content_type.nil?
|
2142
|
+
header_params['Content-Type'] = content_type
|
2143
|
+
end
|
2144
|
+
|
2145
|
+
# form parameters
|
2146
|
+
form_params = opts[:form_params] || {}
|
2147
|
+
|
2148
|
+
# http body (model)
|
2149
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_resend_phone_code_request)
|
2150
|
+
|
2151
|
+
# return_type
|
2152
|
+
return_type = opts[:debug_return_type] || 'UserServiceResendPhoneCodeResponse'
|
2153
|
+
|
2154
|
+
# auth_names
|
2155
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
2156
|
+
|
2157
|
+
new_options = opts.merge(
|
2158
|
+
:operation => :"UserServiceApi.user_service_resend_phone_code",
|
2159
|
+
:header_params => header_params,
|
2160
|
+
:query_params => query_params,
|
2161
|
+
:form_params => form_params,
|
2162
|
+
:body => post_body,
|
2163
|
+
:auth_names => auth_names,
|
2164
|
+
:return_type => return_type
|
2165
|
+
)
|
2166
|
+
|
2167
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
2168
|
+
if @api_client.config.debugging
|
2169
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_resend_phone_code\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2170
|
+
end
|
2171
|
+
return data, status_code, headers
|
2172
|
+
end
|
2173
|
+
|
2174
|
+
# Retrieve the information returned by the identity provider
|
2175
|
+
# Retrieve the information returned by the identity provider for registration or updating an existing user with new information..
|
2176
|
+
# @param idp_intent_id [String] ID of the idp intent, previously returned on the success response of the IDP callback
|
2177
|
+
# @param user_service_retrieve_identity_provider_intent_request [UserServiceRetrieveIdentityProviderIntentRequest]
|
2178
|
+
# @param [Hash] opts the optional parameters
|
2179
|
+
# @return [UserServiceRetrieveIdentityProviderIntentResponse]
|
2180
|
+
def user_service_retrieve_identity_provider_intent(idp_intent_id, user_service_retrieve_identity_provider_intent_request, opts = {})
|
2181
|
+
data, _status_code, _headers = user_service_retrieve_identity_provider_intent_with_http_info(idp_intent_id, user_service_retrieve_identity_provider_intent_request, opts)
|
2182
|
+
data
|
2183
|
+
end
|
2184
|
+
|
2185
|
+
# Retrieve the information returned by the identity provider
|
2186
|
+
# Retrieve the information returned by the identity provider for registration or updating an existing user with new information..
|
2187
|
+
# @param idp_intent_id [String] ID of the idp intent, previously returned on the success response of the IDP callback
|
2188
|
+
# @param user_service_retrieve_identity_provider_intent_request [UserServiceRetrieveIdentityProviderIntentRequest]
|
2189
|
+
# @param [Hash] opts the optional parameters
|
2190
|
+
# @return [Array<(UserServiceRetrieveIdentityProviderIntentResponse, Integer, Hash)>] UserServiceRetrieveIdentityProviderIntentResponse data, response status code and response headers
|
2191
|
+
def user_service_retrieve_identity_provider_intent_with_http_info(idp_intent_id, user_service_retrieve_identity_provider_intent_request, opts = {})
|
2192
|
+
if @api_client.config.debugging
|
2193
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_retrieve_identity_provider_intent ...'
|
2194
|
+
end
|
2195
|
+
# verify the required parameter 'idp_intent_id' is set
|
2196
|
+
if @api_client.config.client_side_validation && idp_intent_id.nil?
|
2197
|
+
fail ArgumentError, "Missing the required parameter 'idp_intent_id' when calling UserServiceApi.user_service_retrieve_identity_provider_intent"
|
2198
|
+
end
|
2199
|
+
# verify the required parameter 'user_service_retrieve_identity_provider_intent_request' is set
|
2200
|
+
if @api_client.config.client_side_validation && user_service_retrieve_identity_provider_intent_request.nil?
|
2201
|
+
fail ArgumentError, "Missing the required parameter 'user_service_retrieve_identity_provider_intent_request' when calling UserServiceApi.user_service_retrieve_identity_provider_intent"
|
2202
|
+
end
|
2203
|
+
# resource path
|
2204
|
+
local_var_path = '/v2/idp_intents/{idpIntentId}'.sub('{' + 'idpIntentId' + '}', CGI.escape(idp_intent_id.to_s))
|
2205
|
+
|
2206
|
+
# query parameters
|
2207
|
+
query_params = opts[:query_params] || {}
|
2208
|
+
|
2209
|
+
# header parameters
|
2210
|
+
header_params = opts[:header_params] || {}
|
2211
|
+
# HTTP header 'Accept' (if needed)
|
2212
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
2213
|
+
# HTTP header 'Content-Type'
|
2214
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
2215
|
+
if !content_type.nil?
|
2216
|
+
header_params['Content-Type'] = content_type
|
2217
|
+
end
|
2218
|
+
|
2219
|
+
# form parameters
|
2220
|
+
form_params = opts[:form_params] || {}
|
2221
|
+
|
2222
|
+
# http body (model)
|
2223
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_retrieve_identity_provider_intent_request)
|
2224
|
+
|
2225
|
+
# return_type
|
2226
|
+
return_type = opts[:debug_return_type] || 'UserServiceRetrieveIdentityProviderIntentResponse'
|
2227
|
+
|
2228
|
+
# auth_names
|
2229
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
2230
|
+
|
2231
|
+
new_options = opts.merge(
|
2232
|
+
:operation => :"UserServiceApi.user_service_retrieve_identity_provider_intent",
|
2233
|
+
:header_params => header_params,
|
2234
|
+
:query_params => query_params,
|
2235
|
+
:form_params => form_params,
|
2236
|
+
:body => post_body,
|
2237
|
+
:auth_names => auth_names,
|
2238
|
+
:return_type => return_type
|
2239
|
+
)
|
2240
|
+
|
2241
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
2242
|
+
if @api_client.config.debugging
|
2243
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_retrieve_identity_provider_intent\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2244
|
+
end
|
2245
|
+
return data, status_code, headers
|
2246
|
+
end
|
2247
|
+
|
2248
|
+
# Send code to verify user email
|
2249
|
+
# Send code to verify user email.
|
2250
|
+
# @param user_id [String]
|
2251
|
+
# @param user_service_send_email_code_request [UserServiceSendEmailCodeRequest]
|
2252
|
+
# @param [Hash] opts the optional parameters
|
2253
|
+
# @return [UserServiceSendEmailCodeResponse]
|
2254
|
+
def user_service_send_email_code(user_id, user_service_send_email_code_request, opts = {})
|
2255
|
+
data, _status_code, _headers = user_service_send_email_code_with_http_info(user_id, user_service_send_email_code_request, opts)
|
2256
|
+
data
|
2257
|
+
end
|
2258
|
+
|
2259
|
+
# Send code to verify user email
|
2260
|
+
# Send code to verify user email.
|
2261
|
+
# @param user_id [String]
|
2262
|
+
# @param user_service_send_email_code_request [UserServiceSendEmailCodeRequest]
|
2263
|
+
# @param [Hash] opts the optional parameters
|
2264
|
+
# @return [Array<(UserServiceSendEmailCodeResponse, Integer, Hash)>] UserServiceSendEmailCodeResponse data, response status code and response headers
|
2265
|
+
def user_service_send_email_code_with_http_info(user_id, user_service_send_email_code_request, opts = {})
|
2266
|
+
if @api_client.config.debugging
|
2267
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_send_email_code ...'
|
2268
|
+
end
|
2269
|
+
# verify the required parameter 'user_id' is set
|
2270
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
2271
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_send_email_code"
|
2272
|
+
end
|
2273
|
+
# verify the required parameter 'user_service_send_email_code_request' is set
|
2274
|
+
if @api_client.config.client_side_validation && user_service_send_email_code_request.nil?
|
2275
|
+
fail ArgumentError, "Missing the required parameter 'user_service_send_email_code_request' when calling UserServiceApi.user_service_send_email_code"
|
2276
|
+
end
|
2277
|
+
# resource path
|
2278
|
+
local_var_path = '/v2/users/{userId}/email/send'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
2279
|
+
|
2280
|
+
# query parameters
|
2281
|
+
query_params = opts[:query_params] || {}
|
2282
|
+
|
2283
|
+
# header parameters
|
2284
|
+
header_params = opts[:header_params] || {}
|
2285
|
+
# HTTP header 'Accept' (if needed)
|
2286
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
2287
|
+
# HTTP header 'Content-Type'
|
2288
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
2289
|
+
if !content_type.nil?
|
2290
|
+
header_params['Content-Type'] = content_type
|
2291
|
+
end
|
2292
|
+
|
2293
|
+
# form parameters
|
2294
|
+
form_params = opts[:form_params] || {}
|
2295
|
+
|
2296
|
+
# http body (model)
|
2297
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_send_email_code_request)
|
2298
|
+
|
2299
|
+
# return_type
|
2300
|
+
return_type = opts[:debug_return_type] || 'UserServiceSendEmailCodeResponse'
|
2301
|
+
|
2302
|
+
# auth_names
|
2303
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
2304
|
+
|
2305
|
+
new_options = opts.merge(
|
2306
|
+
:operation => :"UserServiceApi.user_service_send_email_code",
|
2307
|
+
:header_params => header_params,
|
2308
|
+
:query_params => query_params,
|
2309
|
+
:form_params => form_params,
|
2310
|
+
:body => post_body,
|
2311
|
+
:auth_names => auth_names,
|
2312
|
+
:return_type => return_type
|
2313
|
+
)
|
2314
|
+
|
2315
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
2316
|
+
if @api_client.config.debugging
|
2317
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_send_email_code\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2318
|
+
end
|
2319
|
+
return data, status_code, headers
|
2320
|
+
end
|
2321
|
+
|
2322
|
+
# Change the user email
|
2323
|
+
# Change the email address of a user. If the state is set to not verified, a verification code will be generated, which can be either returned or sent to the user by email..
|
2324
|
+
# @param user_id [String]
|
2325
|
+
# @param user_service_set_email_request [UserServiceSetEmailRequest]
|
2326
|
+
# @param [Hash] opts the optional parameters
|
2327
|
+
# @return [UserServiceSetEmailResponse]
|
2328
|
+
def user_service_set_email(user_id, user_service_set_email_request, opts = {})
|
2329
|
+
data, _status_code, _headers = user_service_set_email_with_http_info(user_id, user_service_set_email_request, opts)
|
2330
|
+
data
|
2331
|
+
end
|
2332
|
+
|
2333
|
+
# Change the user email
|
2334
|
+
# Change the email address of a user. If the state is set to not verified, a verification code will be generated, which can be either returned or sent to the user by email..
|
2335
|
+
# @param user_id [String]
|
2336
|
+
# @param user_service_set_email_request [UserServiceSetEmailRequest]
|
2337
|
+
# @param [Hash] opts the optional parameters
|
2338
|
+
# @return [Array<(UserServiceSetEmailResponse, Integer, Hash)>] UserServiceSetEmailResponse data, response status code and response headers
|
2339
|
+
def user_service_set_email_with_http_info(user_id, user_service_set_email_request, opts = {})
|
2340
|
+
if @api_client.config.debugging
|
2341
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_set_email ...'
|
2342
|
+
end
|
2343
|
+
# verify the required parameter 'user_id' is set
|
2344
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
2345
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_set_email"
|
2346
|
+
end
|
2347
|
+
# verify the required parameter 'user_service_set_email_request' is set
|
2348
|
+
if @api_client.config.client_side_validation && user_service_set_email_request.nil?
|
2349
|
+
fail ArgumentError, "Missing the required parameter 'user_service_set_email_request' when calling UserServiceApi.user_service_set_email"
|
2350
|
+
end
|
2351
|
+
# resource path
|
2352
|
+
local_var_path = '/v2/users/{userId}/email'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
2353
|
+
|
2354
|
+
# query parameters
|
2355
|
+
query_params = opts[:query_params] || {}
|
2356
|
+
|
2357
|
+
# header parameters
|
2358
|
+
header_params = opts[:header_params] || {}
|
2359
|
+
# HTTP header 'Accept' (if needed)
|
2360
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
2361
|
+
# HTTP header 'Content-Type'
|
2362
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
2363
|
+
if !content_type.nil?
|
2364
|
+
header_params['Content-Type'] = content_type
|
2365
|
+
end
|
2366
|
+
|
2367
|
+
# form parameters
|
2368
|
+
form_params = opts[:form_params] || {}
|
2369
|
+
|
2370
|
+
# http body (model)
|
2371
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_set_email_request)
|
2372
|
+
|
2373
|
+
# return_type
|
2374
|
+
return_type = opts[:debug_return_type] || 'UserServiceSetEmailResponse'
|
2375
|
+
|
2376
|
+
# auth_names
|
2377
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
2378
|
+
|
2379
|
+
new_options = opts.merge(
|
2380
|
+
:operation => :"UserServiceApi.user_service_set_email",
|
2381
|
+
:header_params => header_params,
|
2382
|
+
:query_params => query_params,
|
2383
|
+
:form_params => form_params,
|
2384
|
+
:body => post_body,
|
2385
|
+
:auth_names => auth_names,
|
2386
|
+
:return_type => return_type
|
2387
|
+
)
|
2388
|
+
|
2389
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
2390
|
+
if @api_client.config.debugging
|
2391
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_set_email\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2392
|
+
end
|
2393
|
+
return data, status_code, headers
|
2394
|
+
end
|
2395
|
+
|
2396
|
+
# Change password
|
2397
|
+
# Change the password of a user with either a verification code or the current password..
|
2398
|
+
# @param user_id [String]
|
2399
|
+
# @param user_service_set_password_request [UserServiceSetPasswordRequest]
|
2400
|
+
# @param [Hash] opts the optional parameters
|
2401
|
+
# @return [UserServiceSetPasswordResponse]
|
2402
|
+
def user_service_set_password(user_id, user_service_set_password_request, opts = {})
|
2403
|
+
data, _status_code, _headers = user_service_set_password_with_http_info(user_id, user_service_set_password_request, opts)
|
2404
|
+
data
|
2405
|
+
end
|
2406
|
+
|
2407
|
+
# Change password
|
2408
|
+
# Change the password of a user with either a verification code or the current password..
|
2409
|
+
# @param user_id [String]
|
2410
|
+
# @param user_service_set_password_request [UserServiceSetPasswordRequest]
|
2411
|
+
# @param [Hash] opts the optional parameters
|
2412
|
+
# @return [Array<(UserServiceSetPasswordResponse, Integer, Hash)>] UserServiceSetPasswordResponse data, response status code and response headers
|
2413
|
+
def user_service_set_password_with_http_info(user_id, user_service_set_password_request, opts = {})
|
2414
|
+
if @api_client.config.debugging
|
2415
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_set_password ...'
|
2416
|
+
end
|
2417
|
+
# verify the required parameter 'user_id' is set
|
2418
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
2419
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_set_password"
|
2420
|
+
end
|
2421
|
+
# verify the required parameter 'user_service_set_password_request' is set
|
2422
|
+
if @api_client.config.client_side_validation && user_service_set_password_request.nil?
|
2423
|
+
fail ArgumentError, "Missing the required parameter 'user_service_set_password_request' when calling UserServiceApi.user_service_set_password"
|
2424
|
+
end
|
2425
|
+
# resource path
|
2426
|
+
local_var_path = '/v2/users/{userId}/password'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
2427
|
+
|
2428
|
+
# query parameters
|
2429
|
+
query_params = opts[:query_params] || {}
|
2430
|
+
|
2431
|
+
# header parameters
|
2432
|
+
header_params = opts[:header_params] || {}
|
2433
|
+
# HTTP header 'Accept' (if needed)
|
2434
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
2435
|
+
# HTTP header 'Content-Type'
|
2436
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
2437
|
+
if !content_type.nil?
|
2438
|
+
header_params['Content-Type'] = content_type
|
2439
|
+
end
|
2440
|
+
|
2441
|
+
# form parameters
|
2442
|
+
form_params = opts[:form_params] || {}
|
2443
|
+
|
2444
|
+
# http body (model)
|
2445
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_set_password_request)
|
2446
|
+
|
2447
|
+
# return_type
|
2448
|
+
return_type = opts[:debug_return_type] || 'UserServiceSetPasswordResponse'
|
2449
|
+
|
2450
|
+
# auth_names
|
2451
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
2452
|
+
|
2453
|
+
new_options = opts.merge(
|
2454
|
+
:operation => :"UserServiceApi.user_service_set_password",
|
2455
|
+
:header_params => header_params,
|
2456
|
+
:query_params => query_params,
|
2457
|
+
:form_params => form_params,
|
2458
|
+
:body => post_body,
|
2459
|
+
:auth_names => auth_names,
|
2460
|
+
:return_type => return_type
|
2461
|
+
)
|
2462
|
+
|
2463
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
2464
|
+
if @api_client.config.debugging
|
2465
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_set_password\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2466
|
+
end
|
2467
|
+
return data, status_code, headers
|
2468
|
+
end
|
2469
|
+
|
2470
|
+
# Set the user phone
|
2471
|
+
# Set the phone number of a user. If the state is set to not verified, a verification code will be generated, which can be either returned or sent to the user by sms..
|
2472
|
+
# @param user_id [String]
|
2473
|
+
# @param user_service_set_phone_request [UserServiceSetPhoneRequest]
|
2474
|
+
# @param [Hash] opts the optional parameters
|
2475
|
+
# @return [UserServiceSetPhoneResponse]
|
2476
|
+
def user_service_set_phone(user_id, user_service_set_phone_request, opts = {})
|
2477
|
+
data, _status_code, _headers = user_service_set_phone_with_http_info(user_id, user_service_set_phone_request, opts)
|
2478
|
+
data
|
2479
|
+
end
|
2480
|
+
|
2481
|
+
# Set the user phone
|
2482
|
+
# Set the phone number of a user. If the state is set to not verified, a verification code will be generated, which can be either returned or sent to the user by sms..
|
2483
|
+
# @param user_id [String]
|
2484
|
+
# @param user_service_set_phone_request [UserServiceSetPhoneRequest]
|
2485
|
+
# @param [Hash] opts the optional parameters
|
2486
|
+
# @return [Array<(UserServiceSetPhoneResponse, Integer, Hash)>] UserServiceSetPhoneResponse data, response status code and response headers
|
2487
|
+
def user_service_set_phone_with_http_info(user_id, user_service_set_phone_request, opts = {})
|
2488
|
+
if @api_client.config.debugging
|
2489
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_set_phone ...'
|
2490
|
+
end
|
2491
|
+
# verify the required parameter 'user_id' is set
|
2492
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
2493
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_set_phone"
|
2494
|
+
end
|
2495
|
+
# verify the required parameter 'user_service_set_phone_request' is set
|
2496
|
+
if @api_client.config.client_side_validation && user_service_set_phone_request.nil?
|
2497
|
+
fail ArgumentError, "Missing the required parameter 'user_service_set_phone_request' when calling UserServiceApi.user_service_set_phone"
|
2498
|
+
end
|
2499
|
+
# resource path
|
2500
|
+
local_var_path = '/v2/users/{userId}/phone'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
2501
|
+
|
2502
|
+
# query parameters
|
2503
|
+
query_params = opts[:query_params] || {}
|
2504
|
+
|
2505
|
+
# header parameters
|
2506
|
+
header_params = opts[:header_params] || {}
|
2507
|
+
# HTTP header 'Accept' (if needed)
|
2508
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
2509
|
+
# HTTP header 'Content-Type'
|
2510
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
2511
|
+
if !content_type.nil?
|
2512
|
+
header_params['Content-Type'] = content_type
|
2513
|
+
end
|
2514
|
+
|
2515
|
+
# form parameters
|
2516
|
+
form_params = opts[:form_params] || {}
|
2517
|
+
|
2518
|
+
# http body (model)
|
2519
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_set_phone_request)
|
2520
|
+
|
2521
|
+
# return_type
|
2522
|
+
return_type = opts[:debug_return_type] || 'UserServiceSetPhoneResponse'
|
2523
|
+
|
2524
|
+
# auth_names
|
2525
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
2526
|
+
|
2527
|
+
new_options = opts.merge(
|
2528
|
+
:operation => :"UserServiceApi.user_service_set_phone",
|
2529
|
+
:header_params => header_params,
|
2530
|
+
:query_params => query_params,
|
2531
|
+
:form_params => form_params,
|
2532
|
+
:body => post_body,
|
2533
|
+
:auth_names => auth_names,
|
2534
|
+
:return_type => return_type
|
2535
|
+
)
|
2536
|
+
|
2537
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
2538
|
+
if @api_client.config.debugging
|
2539
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_set_phone\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2540
|
+
end
|
2541
|
+
return data, status_code, headers
|
2542
|
+
end
|
2543
|
+
|
2544
|
+
# Start flow with an identity provider
|
2545
|
+
# Start a flow with an identity provider, for external login, registration or linking..
|
2546
|
+
# @param user_service_start_identity_provider_intent_request [UserServiceStartIdentityProviderIntentRequest]
|
2547
|
+
# @param [Hash] opts the optional parameters
|
2548
|
+
# @return [UserServiceStartIdentityProviderIntentResponse]
|
2549
|
+
def user_service_start_identity_provider_intent(user_service_start_identity_provider_intent_request, opts = {})
|
2550
|
+
data, _status_code, _headers = user_service_start_identity_provider_intent_with_http_info(user_service_start_identity_provider_intent_request, opts)
|
2551
|
+
data
|
2552
|
+
end
|
2553
|
+
|
2554
|
+
# Start flow with an identity provider
|
2555
|
+
# Start a flow with an identity provider, for external login, registration or linking..
|
2556
|
+
# @param user_service_start_identity_provider_intent_request [UserServiceStartIdentityProviderIntentRequest]
|
2557
|
+
# @param [Hash] opts the optional parameters
|
2558
|
+
# @return [Array<(UserServiceStartIdentityProviderIntentResponse, Integer, Hash)>] UserServiceStartIdentityProviderIntentResponse data, response status code and response headers
|
2559
|
+
def user_service_start_identity_provider_intent_with_http_info(user_service_start_identity_provider_intent_request, opts = {})
|
2560
|
+
if @api_client.config.debugging
|
2561
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_start_identity_provider_intent ...'
|
2562
|
+
end
|
2563
|
+
# verify the required parameter 'user_service_start_identity_provider_intent_request' is set
|
2564
|
+
if @api_client.config.client_side_validation && user_service_start_identity_provider_intent_request.nil?
|
2565
|
+
fail ArgumentError, "Missing the required parameter 'user_service_start_identity_provider_intent_request' when calling UserServiceApi.user_service_start_identity_provider_intent"
|
2566
|
+
end
|
2567
|
+
# resource path
|
2568
|
+
local_var_path = '/v2/idp_intents'
|
2569
|
+
|
2570
|
+
# query parameters
|
2571
|
+
query_params = opts[:query_params] || {}
|
2572
|
+
|
2573
|
+
# header parameters
|
2574
|
+
header_params = opts[:header_params] || {}
|
2575
|
+
# HTTP header 'Accept' (if needed)
|
2576
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
2577
|
+
# HTTP header 'Content-Type'
|
2578
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
2579
|
+
if !content_type.nil?
|
2580
|
+
header_params['Content-Type'] = content_type
|
2581
|
+
end
|
2582
|
+
|
2583
|
+
# form parameters
|
2584
|
+
form_params = opts[:form_params] || {}
|
2585
|
+
|
2586
|
+
# http body (model)
|
2587
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_start_identity_provider_intent_request)
|
2588
|
+
|
2589
|
+
# return_type
|
2590
|
+
return_type = opts[:debug_return_type] || 'UserServiceStartIdentityProviderIntentResponse'
|
2591
|
+
|
2592
|
+
# auth_names
|
2593
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
2594
|
+
|
2595
|
+
new_options = opts.merge(
|
2596
|
+
:operation => :"UserServiceApi.user_service_start_identity_provider_intent",
|
2597
|
+
:header_params => header_params,
|
2598
|
+
:query_params => query_params,
|
2599
|
+
:form_params => form_params,
|
2600
|
+
:body => post_body,
|
2601
|
+
:auth_names => auth_names,
|
2602
|
+
:return_type => return_type
|
2603
|
+
)
|
2604
|
+
|
2605
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
2606
|
+
if @api_client.config.debugging
|
2607
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_start_identity_provider_intent\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2608
|
+
end
|
2609
|
+
return data, status_code, headers
|
2610
|
+
end
|
2611
|
+
|
2612
|
+
# Unlock user
|
2613
|
+
# The state of the user will be changed to 'locked'. The user will not be able to log in anymore. The endpoint returns an error if the user is already in the state 'locked'. Use this endpoint if the user should not be able to log in temporarily because of an event that happened (wrong password, etc.)..
|
2614
|
+
# @param user_id [String]
|
2615
|
+
# @param [Hash] opts the optional parameters
|
2616
|
+
# @return [UserServiceUnlockUserResponse]
|
2617
|
+
def user_service_unlock_user(user_id, opts = {})
|
2618
|
+
data, _status_code, _headers = user_service_unlock_user_with_http_info(user_id, opts)
|
2619
|
+
data
|
2620
|
+
end
|
2621
|
+
|
2622
|
+
# Unlock user
|
2623
|
+
# The state of the user will be changed to 'locked'. The user will not be able to log in anymore. The endpoint returns an error if the user is already in the state 'locked'. Use this endpoint if the user should not be able to log in temporarily because of an event that happened (wrong password, etc.)..
|
2624
|
+
# @param user_id [String]
|
2625
|
+
# @param [Hash] opts the optional parameters
|
2626
|
+
# @return [Array<(UserServiceUnlockUserResponse, Integer, Hash)>] UserServiceUnlockUserResponse data, response status code and response headers
|
2627
|
+
def user_service_unlock_user_with_http_info(user_id, opts = {})
|
2628
|
+
if @api_client.config.debugging
|
2629
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_unlock_user ...'
|
2630
|
+
end
|
2631
|
+
# verify the required parameter 'user_id' is set
|
2632
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
2633
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_unlock_user"
|
2634
|
+
end
|
2635
|
+
# resource path
|
2636
|
+
local_var_path = '/v2/users/{userId}/unlock'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
2637
|
+
|
2638
|
+
# query parameters
|
2639
|
+
query_params = opts[:query_params] || {}
|
2640
|
+
|
2641
|
+
# header parameters
|
2642
|
+
header_params = opts[:header_params] || {}
|
2643
|
+
# HTTP header 'Accept' (if needed)
|
2644
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
2645
|
+
# HTTP header 'Content-Type'
|
2646
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
2647
|
+
if !content_type.nil?
|
2648
|
+
header_params['Content-Type'] = content_type
|
2649
|
+
end
|
2650
|
+
|
2651
|
+
# form parameters
|
2652
|
+
form_params = opts[:form_params] || {}
|
2653
|
+
|
2654
|
+
# http body (model)
|
2655
|
+
post_body = opts[:debug_body]
|
2656
|
+
|
2657
|
+
# return_type
|
2658
|
+
return_type = opts[:debug_return_type] || 'UserServiceUnlockUserResponse'
|
2659
|
+
|
2660
|
+
# auth_names
|
2661
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
2662
|
+
|
2663
|
+
new_options = opts.merge(
|
2664
|
+
:operation => :"UserServiceApi.user_service_unlock_user",
|
2665
|
+
:header_params => header_params,
|
2666
|
+
:query_params => query_params,
|
2667
|
+
:form_params => form_params,
|
2668
|
+
:body => post_body,
|
2669
|
+
:auth_names => auth_names,
|
2670
|
+
:return_type => return_type
|
2671
|
+
)
|
2672
|
+
|
2673
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
2674
|
+
if @api_client.config.debugging
|
2675
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_unlock_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2676
|
+
end
|
2677
|
+
return data, status_code, headers
|
2678
|
+
end
|
2679
|
+
|
2680
|
+
# Update User
|
2681
|
+
# Update all information from a user..
|
2682
|
+
# @param user_id [String]
|
2683
|
+
# @param user_service_update_human_user_request [UserServiceUpdateHumanUserRequest]
|
2684
|
+
# @param [Hash] opts the optional parameters
|
2685
|
+
# @return [UserServiceUpdateHumanUserResponse]
|
2686
|
+
def user_service_update_human_user(user_id, user_service_update_human_user_request, opts = {})
|
2687
|
+
data, _status_code, _headers = user_service_update_human_user_with_http_info(user_id, user_service_update_human_user_request, opts)
|
2688
|
+
data
|
2689
|
+
end
|
2690
|
+
|
2691
|
+
# Update User
|
2692
|
+
# Update all information from a user..
|
2693
|
+
# @param user_id [String]
|
2694
|
+
# @param user_service_update_human_user_request [UserServiceUpdateHumanUserRequest]
|
2695
|
+
# @param [Hash] opts the optional parameters
|
2696
|
+
# @return [Array<(UserServiceUpdateHumanUserResponse, Integer, Hash)>] UserServiceUpdateHumanUserResponse data, response status code and response headers
|
2697
|
+
def user_service_update_human_user_with_http_info(user_id, user_service_update_human_user_request, opts = {})
|
2698
|
+
if @api_client.config.debugging
|
2699
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_update_human_user ...'
|
2700
|
+
end
|
2701
|
+
# verify the required parameter 'user_id' is set
|
2702
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
2703
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_update_human_user"
|
2704
|
+
end
|
2705
|
+
# verify the required parameter 'user_service_update_human_user_request' is set
|
2706
|
+
if @api_client.config.client_side_validation && user_service_update_human_user_request.nil?
|
2707
|
+
fail ArgumentError, "Missing the required parameter 'user_service_update_human_user_request' when calling UserServiceApi.user_service_update_human_user"
|
2708
|
+
end
|
2709
|
+
# resource path
|
2710
|
+
local_var_path = '/v2/users/human/{userId}'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
2711
|
+
|
2712
|
+
# query parameters
|
2713
|
+
query_params = opts[:query_params] || {}
|
2714
|
+
|
2715
|
+
# header parameters
|
2716
|
+
header_params = opts[:header_params] || {}
|
2717
|
+
# HTTP header 'Accept' (if needed)
|
2718
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
2719
|
+
# HTTP header 'Content-Type'
|
2720
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
2721
|
+
if !content_type.nil?
|
2722
|
+
header_params['Content-Type'] = content_type
|
2723
|
+
end
|
2724
|
+
|
2725
|
+
# form parameters
|
2726
|
+
form_params = opts[:form_params] || {}
|
2727
|
+
|
2728
|
+
# http body (model)
|
2729
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_update_human_user_request)
|
2730
|
+
|
2731
|
+
# return_type
|
2732
|
+
return_type = opts[:debug_return_type] || 'UserServiceUpdateHumanUserResponse'
|
2733
|
+
|
2734
|
+
# auth_names
|
2735
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
2736
|
+
|
2737
|
+
new_options = opts.merge(
|
2738
|
+
:operation => :"UserServiceApi.user_service_update_human_user",
|
2739
|
+
:header_params => header_params,
|
2740
|
+
:query_params => query_params,
|
2741
|
+
:form_params => form_params,
|
2742
|
+
:body => post_body,
|
2743
|
+
:auth_names => auth_names,
|
2744
|
+
:return_type => return_type
|
2745
|
+
)
|
2746
|
+
|
2747
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
|
2748
|
+
if @api_client.config.debugging
|
2749
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_update_human_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2750
|
+
end
|
2751
|
+
return data, status_code, headers
|
2752
|
+
end
|
2753
|
+
|
2754
|
+
# Verify the email
|
2755
|
+
# Verify the email with the generated code.
|
2756
|
+
# @param user_id [String]
|
2757
|
+
# @param user_service_verify_email_request [UserServiceVerifyEmailRequest]
|
2758
|
+
# @param [Hash] opts the optional parameters
|
2759
|
+
# @return [UserServiceVerifyEmailResponse]
|
2760
|
+
def user_service_verify_email(user_id, user_service_verify_email_request, opts = {})
|
2761
|
+
data, _status_code, _headers = user_service_verify_email_with_http_info(user_id, user_service_verify_email_request, opts)
|
2762
|
+
data
|
2763
|
+
end
|
2764
|
+
|
2765
|
+
# Verify the email
|
2766
|
+
# Verify the email with the generated code.
|
2767
|
+
# @param user_id [String]
|
2768
|
+
# @param user_service_verify_email_request [UserServiceVerifyEmailRequest]
|
2769
|
+
# @param [Hash] opts the optional parameters
|
2770
|
+
# @return [Array<(UserServiceVerifyEmailResponse, Integer, Hash)>] UserServiceVerifyEmailResponse data, response status code and response headers
|
2771
|
+
def user_service_verify_email_with_http_info(user_id, user_service_verify_email_request, opts = {})
|
2772
|
+
if @api_client.config.debugging
|
2773
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_verify_email ...'
|
2774
|
+
end
|
2775
|
+
# verify the required parameter 'user_id' is set
|
2776
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
2777
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_verify_email"
|
2778
|
+
end
|
2779
|
+
# verify the required parameter 'user_service_verify_email_request' is set
|
2780
|
+
if @api_client.config.client_side_validation && user_service_verify_email_request.nil?
|
2781
|
+
fail ArgumentError, "Missing the required parameter 'user_service_verify_email_request' when calling UserServiceApi.user_service_verify_email"
|
2782
|
+
end
|
2783
|
+
# resource path
|
2784
|
+
local_var_path = '/v2/users/{userId}/email/verify'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
2785
|
+
|
2786
|
+
# query parameters
|
2787
|
+
query_params = opts[:query_params] || {}
|
2788
|
+
|
2789
|
+
# header parameters
|
2790
|
+
header_params = opts[:header_params] || {}
|
2791
|
+
# HTTP header 'Accept' (if needed)
|
2792
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
2793
|
+
# HTTP header 'Content-Type'
|
2794
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
2795
|
+
if !content_type.nil?
|
2796
|
+
header_params['Content-Type'] = content_type
|
2797
|
+
end
|
2798
|
+
|
2799
|
+
# form parameters
|
2800
|
+
form_params = opts[:form_params] || {}
|
2801
|
+
|
2802
|
+
# http body (model)
|
2803
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_verify_email_request)
|
2804
|
+
|
2805
|
+
# return_type
|
2806
|
+
return_type = opts[:debug_return_type] || 'UserServiceVerifyEmailResponse'
|
2807
|
+
|
2808
|
+
# auth_names
|
2809
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
2810
|
+
|
2811
|
+
new_options = opts.merge(
|
2812
|
+
:operation => :"UserServiceApi.user_service_verify_email",
|
2813
|
+
:header_params => header_params,
|
2814
|
+
:query_params => query_params,
|
2815
|
+
:form_params => form_params,
|
2816
|
+
:body => post_body,
|
2817
|
+
:auth_names => auth_names,
|
2818
|
+
:return_type => return_type
|
2819
|
+
)
|
2820
|
+
|
2821
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
2822
|
+
if @api_client.config.debugging
|
2823
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_verify_email\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2824
|
+
end
|
2825
|
+
return data, status_code, headers
|
2826
|
+
end
|
2827
|
+
|
2828
|
+
# Verify an invite code for a user
|
2829
|
+
# Verify the invite code of a user previously issued. This will set their email to a verified state and allow the user to set up their first authentication method (password, passkeys, IdP) depending on the organization's available methods.
|
2830
|
+
# @param user_id [String]
|
2831
|
+
# @param user_service_verify_invite_code_request [UserServiceVerifyInviteCodeRequest]
|
2832
|
+
# @param [Hash] opts the optional parameters
|
2833
|
+
# @return [UserServiceVerifyInviteCodeResponse]
|
2834
|
+
def user_service_verify_invite_code(user_id, user_service_verify_invite_code_request, opts = {})
|
2835
|
+
data, _status_code, _headers = user_service_verify_invite_code_with_http_info(user_id, user_service_verify_invite_code_request, opts)
|
2836
|
+
data
|
2837
|
+
end
|
2838
|
+
|
2839
|
+
# Verify an invite code for a user
|
2840
|
+
# Verify the invite code of a user previously issued. This will set their email to a verified state and allow the user to set up their first authentication method (password, passkeys, IdP) depending on the organization's available methods.
|
2841
|
+
# @param user_id [String]
|
2842
|
+
# @param user_service_verify_invite_code_request [UserServiceVerifyInviteCodeRequest]
|
2843
|
+
# @param [Hash] opts the optional parameters
|
2844
|
+
# @return [Array<(UserServiceVerifyInviteCodeResponse, Integer, Hash)>] UserServiceVerifyInviteCodeResponse data, response status code and response headers
|
2845
|
+
def user_service_verify_invite_code_with_http_info(user_id, user_service_verify_invite_code_request, opts = {})
|
2846
|
+
if @api_client.config.debugging
|
2847
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_verify_invite_code ...'
|
2848
|
+
end
|
2849
|
+
# verify the required parameter 'user_id' is set
|
2850
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
2851
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_verify_invite_code"
|
2852
|
+
end
|
2853
|
+
# verify the required parameter 'user_service_verify_invite_code_request' is set
|
2854
|
+
if @api_client.config.client_side_validation && user_service_verify_invite_code_request.nil?
|
2855
|
+
fail ArgumentError, "Missing the required parameter 'user_service_verify_invite_code_request' when calling UserServiceApi.user_service_verify_invite_code"
|
2856
|
+
end
|
2857
|
+
# resource path
|
2858
|
+
local_var_path = '/v2/users/{userId}/invite_code/verify'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
2859
|
+
|
2860
|
+
# query parameters
|
2861
|
+
query_params = opts[:query_params] || {}
|
2862
|
+
|
2863
|
+
# header parameters
|
2864
|
+
header_params = opts[:header_params] || {}
|
2865
|
+
# HTTP header 'Accept' (if needed)
|
2866
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
2867
|
+
# HTTP header 'Content-Type'
|
2868
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
2869
|
+
if !content_type.nil?
|
2870
|
+
header_params['Content-Type'] = content_type
|
2871
|
+
end
|
2872
|
+
|
2873
|
+
# form parameters
|
2874
|
+
form_params = opts[:form_params] || {}
|
2875
|
+
|
2876
|
+
# http body (model)
|
2877
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_verify_invite_code_request)
|
2878
|
+
|
2879
|
+
# return_type
|
2880
|
+
return_type = opts[:debug_return_type] || 'UserServiceVerifyInviteCodeResponse'
|
2881
|
+
|
2882
|
+
# auth_names
|
2883
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
2884
|
+
|
2885
|
+
new_options = opts.merge(
|
2886
|
+
:operation => :"UserServiceApi.user_service_verify_invite_code",
|
2887
|
+
:header_params => header_params,
|
2888
|
+
:query_params => query_params,
|
2889
|
+
:form_params => form_params,
|
2890
|
+
:body => post_body,
|
2891
|
+
:auth_names => auth_names,
|
2892
|
+
:return_type => return_type
|
2893
|
+
)
|
2894
|
+
|
2895
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
2896
|
+
if @api_client.config.debugging
|
2897
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_verify_invite_code\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2898
|
+
end
|
2899
|
+
return data, status_code, headers
|
2900
|
+
end
|
2901
|
+
|
2902
|
+
# Verify a passkey for a user
|
2903
|
+
# Verify the passkey registration with the public key credential..
|
2904
|
+
# @param user_id [String]
|
2905
|
+
# @param passkey_id [String]
|
2906
|
+
# @param user_service_verify_passkey_registration_request [UserServiceVerifyPasskeyRegistrationRequest]
|
2907
|
+
# @param [Hash] opts the optional parameters
|
2908
|
+
# @return [UserServiceVerifyPasskeyRegistrationResponse]
|
2909
|
+
def user_service_verify_passkey_registration(user_id, passkey_id, user_service_verify_passkey_registration_request, opts = {})
|
2910
|
+
data, _status_code, _headers = user_service_verify_passkey_registration_with_http_info(user_id, passkey_id, user_service_verify_passkey_registration_request, opts)
|
2911
|
+
data
|
2912
|
+
end
|
2913
|
+
|
2914
|
+
# Verify a passkey for a user
|
2915
|
+
# Verify the passkey registration with the public key credential..
|
2916
|
+
# @param user_id [String]
|
2917
|
+
# @param passkey_id [String]
|
2918
|
+
# @param user_service_verify_passkey_registration_request [UserServiceVerifyPasskeyRegistrationRequest]
|
2919
|
+
# @param [Hash] opts the optional parameters
|
2920
|
+
# @return [Array<(UserServiceVerifyPasskeyRegistrationResponse, Integer, Hash)>] UserServiceVerifyPasskeyRegistrationResponse data, response status code and response headers
|
2921
|
+
def user_service_verify_passkey_registration_with_http_info(user_id, passkey_id, user_service_verify_passkey_registration_request, opts = {})
|
2922
|
+
if @api_client.config.debugging
|
2923
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_verify_passkey_registration ...'
|
2924
|
+
end
|
2925
|
+
# verify the required parameter 'user_id' is set
|
2926
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
2927
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_verify_passkey_registration"
|
2928
|
+
end
|
2929
|
+
# verify the required parameter 'passkey_id' is set
|
2930
|
+
if @api_client.config.client_side_validation && passkey_id.nil?
|
2931
|
+
fail ArgumentError, "Missing the required parameter 'passkey_id' when calling UserServiceApi.user_service_verify_passkey_registration"
|
2932
|
+
end
|
2933
|
+
# verify the required parameter 'user_service_verify_passkey_registration_request' is set
|
2934
|
+
if @api_client.config.client_side_validation && user_service_verify_passkey_registration_request.nil?
|
2935
|
+
fail ArgumentError, "Missing the required parameter 'user_service_verify_passkey_registration_request' when calling UserServiceApi.user_service_verify_passkey_registration"
|
2936
|
+
end
|
2937
|
+
# resource path
|
2938
|
+
local_var_path = '/v2/users/{userId}/passkeys/{passkeyId}'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s)).sub('{' + 'passkeyId' + '}', CGI.escape(passkey_id.to_s))
|
2939
|
+
|
2940
|
+
# query parameters
|
2941
|
+
query_params = opts[:query_params] || {}
|
2942
|
+
|
2943
|
+
# header parameters
|
2944
|
+
header_params = opts[:header_params] || {}
|
2945
|
+
# HTTP header 'Accept' (if needed)
|
2946
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
2947
|
+
# HTTP header 'Content-Type'
|
2948
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
2949
|
+
if !content_type.nil?
|
2950
|
+
header_params['Content-Type'] = content_type
|
2951
|
+
end
|
2952
|
+
|
2953
|
+
# form parameters
|
2954
|
+
form_params = opts[:form_params] || {}
|
2955
|
+
|
2956
|
+
# http body (model)
|
2957
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_verify_passkey_registration_request)
|
2958
|
+
|
2959
|
+
# return_type
|
2960
|
+
return_type = opts[:debug_return_type] || 'UserServiceVerifyPasskeyRegistrationResponse'
|
2961
|
+
|
2962
|
+
# auth_names
|
2963
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
2964
|
+
|
2965
|
+
new_options = opts.merge(
|
2966
|
+
:operation => :"UserServiceApi.user_service_verify_passkey_registration",
|
2967
|
+
:header_params => header_params,
|
2968
|
+
:query_params => query_params,
|
2969
|
+
:form_params => form_params,
|
2970
|
+
:body => post_body,
|
2971
|
+
:auth_names => auth_names,
|
2972
|
+
:return_type => return_type
|
2973
|
+
)
|
2974
|
+
|
2975
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
2976
|
+
if @api_client.config.debugging
|
2977
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_verify_passkey_registration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2978
|
+
end
|
2979
|
+
return data, status_code, headers
|
2980
|
+
end
|
2981
|
+
|
2982
|
+
# Verify the phone
|
2983
|
+
# Verify the phone with the generated code..
|
2984
|
+
# @param user_id [String]
|
2985
|
+
# @param user_service_verify_phone_request [UserServiceVerifyPhoneRequest]
|
2986
|
+
# @param [Hash] opts the optional parameters
|
2987
|
+
# @return [UserServiceVerifyPhoneResponse]
|
2988
|
+
def user_service_verify_phone(user_id, user_service_verify_phone_request, opts = {})
|
2989
|
+
data, _status_code, _headers = user_service_verify_phone_with_http_info(user_id, user_service_verify_phone_request, opts)
|
2990
|
+
data
|
2991
|
+
end
|
2992
|
+
|
2993
|
+
# Verify the phone
|
2994
|
+
# Verify the phone with the generated code..
|
2995
|
+
# @param user_id [String]
|
2996
|
+
# @param user_service_verify_phone_request [UserServiceVerifyPhoneRequest]
|
2997
|
+
# @param [Hash] opts the optional parameters
|
2998
|
+
# @return [Array<(UserServiceVerifyPhoneResponse, Integer, Hash)>] UserServiceVerifyPhoneResponse data, response status code and response headers
|
2999
|
+
def user_service_verify_phone_with_http_info(user_id, user_service_verify_phone_request, opts = {})
|
3000
|
+
if @api_client.config.debugging
|
3001
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_verify_phone ...'
|
3002
|
+
end
|
3003
|
+
# verify the required parameter 'user_id' is set
|
3004
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
3005
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_verify_phone"
|
3006
|
+
end
|
3007
|
+
# verify the required parameter 'user_service_verify_phone_request' is set
|
3008
|
+
if @api_client.config.client_side_validation && user_service_verify_phone_request.nil?
|
3009
|
+
fail ArgumentError, "Missing the required parameter 'user_service_verify_phone_request' when calling UserServiceApi.user_service_verify_phone"
|
3010
|
+
end
|
3011
|
+
# resource path
|
3012
|
+
local_var_path = '/v2/users/{userId}/phone/verify'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
3013
|
+
|
3014
|
+
# query parameters
|
3015
|
+
query_params = opts[:query_params] || {}
|
3016
|
+
|
3017
|
+
# header parameters
|
3018
|
+
header_params = opts[:header_params] || {}
|
3019
|
+
# HTTP header 'Accept' (if needed)
|
3020
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
3021
|
+
# HTTP header 'Content-Type'
|
3022
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
3023
|
+
if !content_type.nil?
|
3024
|
+
header_params['Content-Type'] = content_type
|
3025
|
+
end
|
3026
|
+
|
3027
|
+
# form parameters
|
3028
|
+
form_params = opts[:form_params] || {}
|
3029
|
+
|
3030
|
+
# http body (model)
|
3031
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_verify_phone_request)
|
3032
|
+
|
3033
|
+
# return_type
|
3034
|
+
return_type = opts[:debug_return_type] || 'UserServiceVerifyPhoneResponse'
|
3035
|
+
|
3036
|
+
# auth_names
|
3037
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
3038
|
+
|
3039
|
+
new_options = opts.merge(
|
3040
|
+
:operation => :"UserServiceApi.user_service_verify_phone",
|
3041
|
+
:header_params => header_params,
|
3042
|
+
:query_params => query_params,
|
3043
|
+
:form_params => form_params,
|
3044
|
+
:body => post_body,
|
3045
|
+
:auth_names => auth_names,
|
3046
|
+
:return_type => return_type
|
3047
|
+
)
|
3048
|
+
|
3049
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
3050
|
+
if @api_client.config.debugging
|
3051
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_verify_phone\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
3052
|
+
end
|
3053
|
+
return data, status_code, headers
|
3054
|
+
end
|
3055
|
+
|
3056
|
+
# Verify a TOTP generator for a user
|
3057
|
+
# Verify the TOTP registration with a generated code..
|
3058
|
+
# @param user_id [String]
|
3059
|
+
# @param user_service_verify_totp_registration_request [UserServiceVerifyTOTPRegistrationRequest]
|
3060
|
+
# @param [Hash] opts the optional parameters
|
3061
|
+
# @return [UserServiceVerifyTOTPRegistrationResponse]
|
3062
|
+
def user_service_verify_totp_registration(user_id, user_service_verify_totp_registration_request, opts = {})
|
3063
|
+
data, _status_code, _headers = user_service_verify_totp_registration_with_http_info(user_id, user_service_verify_totp_registration_request, opts)
|
3064
|
+
data
|
3065
|
+
end
|
3066
|
+
|
3067
|
+
# Verify a TOTP generator for a user
|
3068
|
+
# Verify the TOTP registration with a generated code..
|
3069
|
+
# @param user_id [String]
|
3070
|
+
# @param user_service_verify_totp_registration_request [UserServiceVerifyTOTPRegistrationRequest]
|
3071
|
+
# @param [Hash] opts the optional parameters
|
3072
|
+
# @return [Array<(UserServiceVerifyTOTPRegistrationResponse, Integer, Hash)>] UserServiceVerifyTOTPRegistrationResponse data, response status code and response headers
|
3073
|
+
def user_service_verify_totp_registration_with_http_info(user_id, user_service_verify_totp_registration_request, opts = {})
|
3074
|
+
if @api_client.config.debugging
|
3075
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_verify_totp_registration ...'
|
3076
|
+
end
|
3077
|
+
# verify the required parameter 'user_id' is set
|
3078
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
3079
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_verify_totp_registration"
|
3080
|
+
end
|
3081
|
+
# verify the required parameter 'user_service_verify_totp_registration_request' is set
|
3082
|
+
if @api_client.config.client_side_validation && user_service_verify_totp_registration_request.nil?
|
3083
|
+
fail ArgumentError, "Missing the required parameter 'user_service_verify_totp_registration_request' when calling UserServiceApi.user_service_verify_totp_registration"
|
3084
|
+
end
|
3085
|
+
# resource path
|
3086
|
+
local_var_path = '/v2/users/{userId}/totp/verify'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s))
|
3087
|
+
|
3088
|
+
# query parameters
|
3089
|
+
query_params = opts[:query_params] || {}
|
3090
|
+
|
3091
|
+
# header parameters
|
3092
|
+
header_params = opts[:header_params] || {}
|
3093
|
+
# HTTP header 'Accept' (if needed)
|
3094
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
3095
|
+
# HTTP header 'Content-Type'
|
3096
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
3097
|
+
if !content_type.nil?
|
3098
|
+
header_params['Content-Type'] = content_type
|
3099
|
+
end
|
3100
|
+
|
3101
|
+
# form parameters
|
3102
|
+
form_params = opts[:form_params] || {}
|
3103
|
+
|
3104
|
+
# http body (model)
|
3105
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_verify_totp_registration_request)
|
3106
|
+
|
3107
|
+
# return_type
|
3108
|
+
return_type = opts[:debug_return_type] || 'UserServiceVerifyTOTPRegistrationResponse'
|
3109
|
+
|
3110
|
+
# auth_names
|
3111
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
3112
|
+
|
3113
|
+
new_options = opts.merge(
|
3114
|
+
:operation => :"UserServiceApi.user_service_verify_totp_registration",
|
3115
|
+
:header_params => header_params,
|
3116
|
+
:query_params => query_params,
|
3117
|
+
:form_params => form_params,
|
3118
|
+
:body => post_body,
|
3119
|
+
:auth_names => auth_names,
|
3120
|
+
:return_type => return_type
|
3121
|
+
)
|
3122
|
+
|
3123
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
3124
|
+
if @api_client.config.debugging
|
3125
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_verify_totp_registration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
3126
|
+
end
|
3127
|
+
return data, status_code, headers
|
3128
|
+
end
|
3129
|
+
|
3130
|
+
# Verify a u2f token for a user
|
3131
|
+
# Verify the u2f token registration with the public key credential..
|
3132
|
+
# @param user_id [String]
|
3133
|
+
# @param u2f_id [String]
|
3134
|
+
# @param user_service_verify_u2_f_registration_request [UserServiceVerifyU2FRegistrationRequest]
|
3135
|
+
# @param [Hash] opts the optional parameters
|
3136
|
+
# @return [UserServiceVerifyU2FRegistrationResponse]
|
3137
|
+
def user_service_verify_u2_f_registration(user_id, u2f_id, user_service_verify_u2_f_registration_request, opts = {})
|
3138
|
+
data, _status_code, _headers = user_service_verify_u2_f_registration_with_http_info(user_id, u2f_id, user_service_verify_u2_f_registration_request, opts)
|
3139
|
+
data
|
3140
|
+
end
|
3141
|
+
|
3142
|
+
# Verify a u2f token for a user
|
3143
|
+
# Verify the u2f token registration with the public key credential..
|
3144
|
+
# @param user_id [String]
|
3145
|
+
# @param u2f_id [String]
|
3146
|
+
# @param user_service_verify_u2_f_registration_request [UserServiceVerifyU2FRegistrationRequest]
|
3147
|
+
# @param [Hash] opts the optional parameters
|
3148
|
+
# @return [Array<(UserServiceVerifyU2FRegistrationResponse, Integer, Hash)>] UserServiceVerifyU2FRegistrationResponse data, response status code and response headers
|
3149
|
+
def user_service_verify_u2_f_registration_with_http_info(user_id, u2f_id, user_service_verify_u2_f_registration_request, opts = {})
|
3150
|
+
if @api_client.config.debugging
|
3151
|
+
@api_client.config.logger.debug 'Calling API: UserServiceApi.user_service_verify_u2_f_registration ...'
|
3152
|
+
end
|
3153
|
+
# verify the required parameter 'user_id' is set
|
3154
|
+
if @api_client.config.client_side_validation && user_id.nil?
|
3155
|
+
fail ArgumentError, "Missing the required parameter 'user_id' when calling UserServiceApi.user_service_verify_u2_f_registration"
|
3156
|
+
end
|
3157
|
+
# verify the required parameter 'u2f_id' is set
|
3158
|
+
if @api_client.config.client_side_validation && u2f_id.nil?
|
3159
|
+
fail ArgumentError, "Missing the required parameter 'u2f_id' when calling UserServiceApi.user_service_verify_u2_f_registration"
|
3160
|
+
end
|
3161
|
+
# verify the required parameter 'user_service_verify_u2_f_registration_request' is set
|
3162
|
+
if @api_client.config.client_side_validation && user_service_verify_u2_f_registration_request.nil?
|
3163
|
+
fail ArgumentError, "Missing the required parameter 'user_service_verify_u2_f_registration_request' when calling UserServiceApi.user_service_verify_u2_f_registration"
|
3164
|
+
end
|
3165
|
+
# resource path
|
3166
|
+
local_var_path = '/v2/users/{userId}/u2f/{u2fId}'.sub('{' + 'userId' + '}', CGI.escape(user_id.to_s)).sub('{' + 'u2fId' + '}', CGI.escape(u2f_id.to_s))
|
3167
|
+
|
3168
|
+
# query parameters
|
3169
|
+
query_params = opts[:query_params] || {}
|
3170
|
+
|
3171
|
+
# header parameters
|
3172
|
+
header_params = opts[:header_params] || {}
|
3173
|
+
# HTTP header 'Accept' (if needed)
|
3174
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
3175
|
+
# HTTP header 'Content-Type'
|
3176
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
3177
|
+
if !content_type.nil?
|
3178
|
+
header_params['Content-Type'] = content_type
|
3179
|
+
end
|
3180
|
+
|
3181
|
+
# form parameters
|
3182
|
+
form_params = opts[:form_params] || {}
|
3183
|
+
|
3184
|
+
# http body (model)
|
3185
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(user_service_verify_u2_f_registration_request)
|
3186
|
+
|
3187
|
+
# return_type
|
3188
|
+
return_type = opts[:debug_return_type] || 'UserServiceVerifyU2FRegistrationResponse'
|
3189
|
+
|
3190
|
+
# auth_names
|
3191
|
+
auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
|
3192
|
+
|
3193
|
+
new_options = opts.merge(
|
3194
|
+
:operation => :"UserServiceApi.user_service_verify_u2_f_registration",
|
3195
|
+
:header_params => header_params,
|
3196
|
+
:query_params => query_params,
|
3197
|
+
:form_params => form_params,
|
3198
|
+
:body => post_body,
|
3199
|
+
:auth_names => auth_names,
|
3200
|
+
:return_type => return_type
|
3201
|
+
)
|
3202
|
+
|
3203
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
3204
|
+
if @api_client.config.debugging
|
3205
|
+
@api_client.config.logger.debug "API called: UserServiceApi#user_service_verify_u2_f_registration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
3206
|
+
end
|
3207
|
+
return data, status_code, headers
|
3208
|
+
end
|
3209
|
+
end
|
3210
|
+
end
|