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
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 539eb378884e0e11bcba3e5010f7a9434aef1c34fafea15bb077c1e7ba07c704
|
4
|
+
data.tar.gz: 5d5669db9142cc2be91970d73c4ee0174914b5f3a4ca4f461cae87c887049314
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 2261d6d3f71d293c59c21829dcbafa90665dcbc766fbd10df4dc3002ce5b15a3a4c9e67ff9a3062cc3f6c15a955dda774df52e021987fe8a449f1b847c108d37
|
7
|
+
data.tar.gz: 239e1564293e966c06d72d3755a856a4b253afaddd960bc2c804fbd7dde560e4be3074a09cc54803dda96625acf60e9eb6dad19410806758d0374704bd8d479f
|
data/LICENSE
ADDED
@@ -0,0 +1,201 @@
|
|
1
|
+
Apache License
|
2
|
+
Version 2.0, January 2004
|
3
|
+
http://www.apache.org/licenses/
|
4
|
+
|
5
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
6
|
+
|
7
|
+
1. Definitions.
|
8
|
+
|
9
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
10
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
11
|
+
|
12
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
13
|
+
the copyright owner that is granting the License.
|
14
|
+
|
15
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
16
|
+
other entities that control, are controlled by, or are under common
|
17
|
+
control with that entity. For the purposes of this definition,
|
18
|
+
"control" means (i) the power, direct or indirect, to cause the
|
19
|
+
direction or management of such entity, whether by contract or
|
20
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
21
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
22
|
+
|
23
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
24
|
+
exercising permissions granted by this License.
|
25
|
+
|
26
|
+
"Source" form shall mean the preferred form for making modifications,
|
27
|
+
including but not limited to software source code, documentation
|
28
|
+
source, and configuration files.
|
29
|
+
|
30
|
+
"Object" form shall mean any form resulting from mechanical
|
31
|
+
transformation or translation of a Source form, including but
|
32
|
+
not limited to compiled object code, generated documentation,
|
33
|
+
and conversions to other media types.
|
34
|
+
|
35
|
+
"Work" shall mean the work of authorship, whether in Source or
|
36
|
+
Object form, made available under the License, as indicated by a
|
37
|
+
copyright notice that is included in or attached to the work
|
38
|
+
(an example is provided in the Appendix below).
|
39
|
+
|
40
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
41
|
+
form, that is based on (or derived from) the Work and for which the
|
42
|
+
editorial revisions, annotations, elaborations, or other modifications
|
43
|
+
represent, as a whole, an original work of authorship. For the purposes
|
44
|
+
of this License, Derivative Works shall not include works that remain
|
45
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
46
|
+
the Work and Derivative Works thereof.
|
47
|
+
|
48
|
+
"Contribution" shall mean any work of authorship, including
|
49
|
+
the original version of the Work and any modifications or additions
|
50
|
+
to that Work or Derivative Works thereof, that is intentionally
|
51
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
52
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
53
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
54
|
+
means any form of electronic, verbal, or written communication sent
|
55
|
+
to the Licensor or its representatives, including but not limited to
|
56
|
+
communication on electronic mailing lists, source code control systems,
|
57
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
58
|
+
Licensor for the purpose of discussing and improving the Work, but
|
59
|
+
excluding communication that is conspicuously marked or otherwise
|
60
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
61
|
+
|
62
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
63
|
+
on behalf of whom a Contribution has been received by Licensor and
|
64
|
+
subsequently incorporated within the Work.
|
65
|
+
|
66
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
67
|
+
this License, each Contributor hereby grants to You a perpetual,
|
68
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
69
|
+
copyright license to reproduce, prepare Derivative Works of,
|
70
|
+
publicly display, publicly perform, sublicense, and distribute the
|
71
|
+
Work and such Derivative Works in Source or Object form.
|
72
|
+
|
73
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
74
|
+
this License, each Contributor hereby grants to You a perpetual,
|
75
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
76
|
+
(except as stated in this section) patent license to make, have made,
|
77
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
78
|
+
where such license applies only to those patent claims licensable
|
79
|
+
by such Contributor that are necessarily infringed by their
|
80
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
81
|
+
with the Work to which such Contribution(s) was submitted. If You
|
82
|
+
institute patent litigation against any entity (including a
|
83
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
84
|
+
or a Contribution incorporated within the Work constitutes direct
|
85
|
+
or contributory patent infringement, then any patent licenses
|
86
|
+
granted to You under this License for that Work shall terminate
|
87
|
+
as of the date such litigation is filed.
|
88
|
+
|
89
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
90
|
+
Work or Derivative Works thereof in any medium, with or without
|
91
|
+
modifications, and in Source or Object form, provided that You
|
92
|
+
meet the following conditions:
|
93
|
+
|
94
|
+
(a) You must give any other recipients of the Work or
|
95
|
+
Derivative Works a copy of this License; and
|
96
|
+
|
97
|
+
(b) You must cause any modified files to carry prominent notices
|
98
|
+
stating that You changed the files; and
|
99
|
+
|
100
|
+
(c) You must retain, in the Source form of any Derivative Works
|
101
|
+
that You distribute, all copyright, patent, trademark, and
|
102
|
+
attribution notices from the Source form of the Work,
|
103
|
+
excluding those notices that do not pertain to any part of
|
104
|
+
the Derivative Works; and
|
105
|
+
|
106
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
107
|
+
distribution, then any Derivative Works that You distribute must
|
108
|
+
include a readable copy of the attribution notices contained
|
109
|
+
within such NOTICE file, excluding those notices that do not
|
110
|
+
pertain to any part of the Derivative Works, in at least one
|
111
|
+
of the following places: within a NOTICE text file distributed
|
112
|
+
as part of the Derivative Works; within the Source form or
|
113
|
+
documentation, if provided along with the Derivative Works; or,
|
114
|
+
within a display generated by the Derivative Works, if and
|
115
|
+
wherever such third-party notices normally appear. The contents
|
116
|
+
of the NOTICE file are for informational purposes only and
|
117
|
+
do not modify the License. You may add Your own attribution
|
118
|
+
notices within Derivative Works that You distribute, alongside
|
119
|
+
or as an addendum to the NOTICE text from the Work, provided
|
120
|
+
that such additional attribution notices cannot be construed
|
121
|
+
as modifying the License.
|
122
|
+
|
123
|
+
You may add Your own copyright statement to Your modifications and
|
124
|
+
may provide additional or different license terms and conditions
|
125
|
+
for use, reproduction, or distribution of Your modifications, or
|
126
|
+
for any such Derivative Works as a whole, provided Your use,
|
127
|
+
reproduction, and distribution of the Work otherwise complies with
|
128
|
+
the conditions stated in this License.
|
129
|
+
|
130
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
131
|
+
any Contribution intentionally submitted for inclusion in the Work
|
132
|
+
by You to the Licensor shall be under the terms and conditions of
|
133
|
+
this License, without any additional terms or conditions.
|
134
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
135
|
+
the terms of any separate license agreement you may have executed
|
136
|
+
with Licensor regarding such Contributions.
|
137
|
+
|
138
|
+
6. Trademarks. This License does not grant permission to use the trade
|
139
|
+
names, trademarks, service marks, or product names of the Licensor,
|
140
|
+
except as required for reasonable and customary use in describing the
|
141
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
142
|
+
|
143
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
144
|
+
agreed to in writing, Licensor provides the Work (and each
|
145
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
146
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
147
|
+
implied, including, without limitation, any warranties or conditions
|
148
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
149
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
150
|
+
appropriateness of using or redistributing the Work and assume any
|
151
|
+
risks associated with Your exercise of permissions under this License.
|
152
|
+
|
153
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
154
|
+
whether in tort (including negligence), contract, or otherwise,
|
155
|
+
unless required by applicable law (such as deliberate and grossly
|
156
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
157
|
+
liable to You for damages, including any direct, indirect, special,
|
158
|
+
incidental, or consequential damages of any character arising as a
|
159
|
+
result of this License or out of the use or inability to use the
|
160
|
+
Work (including but not limited to damages for loss of goodwill,
|
161
|
+
work stoppage, computer failure or malfunction, or any and all
|
162
|
+
other commercial damages or losses), even if such Contributor
|
163
|
+
has been advised of the possibility of such damages.
|
164
|
+
|
165
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
166
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
167
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
168
|
+
or other liability obligations and/or rights consistent with this
|
169
|
+
License. However, in accepting such obligations, You may act only
|
170
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
171
|
+
of any other Contributor, and only if You agree to indemnify,
|
172
|
+
defend, and hold each Contributor harmless for any liability
|
173
|
+
incurred by, or claims asserted against, such Contributor by reason
|
174
|
+
of your accepting any such warranty or additional liability.
|
175
|
+
|
176
|
+
END OF TERMS AND CONDITIONS
|
177
|
+
|
178
|
+
APPENDIX: How to apply the Apache License to your work.
|
179
|
+
|
180
|
+
To apply the Apache License to your work, attach the following
|
181
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
182
|
+
replaced with your own identifying information. (Don't include
|
183
|
+
the brackets!) The text should be enclosed in the appropriate
|
184
|
+
comment syntax for the file format. We also recommend that a
|
185
|
+
file or class name and description of purpose be included on the
|
186
|
+
same "printed page" as the copyright notice for easier
|
187
|
+
identification within third-party archives.
|
188
|
+
|
189
|
+
Copyright [yyyy] [name of copyright owner]
|
190
|
+
|
191
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
192
|
+
you may not use this file except in compliance with the License.
|
193
|
+
You may obtain a copy of the License at
|
194
|
+
|
195
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
196
|
+
|
197
|
+
Unless required by applicable law or agreed to in writing, software
|
198
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
199
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
200
|
+
See the License for the specific language governing permissions and
|
201
|
+
limitations under the License.
|
data/README.md
ADDED
@@ -0,0 +1,248 @@
|
|
1
|
+
# Ruby SDK for Zitadel
|
2
|
+
|
3
|
+
This is the Zitadel Ruby SDK, designed to provide a convenient and idiomatic
|
4
|
+
way to interact with the Zitadel APIs in Ruby. The SDK provides a seamless
|
5
|
+
wrapping of the Zitadel API, making it easy to authenticate service users and
|
6
|
+
perform API operations.
|
7
|
+
|
8
|
+
The SDK enables efficient integration with the Zitadel API, allowing you to
|
9
|
+
manage resources and execute actions. However, it's important to note that
|
10
|
+
this SDK is tailored for service users and is not intended for user
|
11
|
+
authentication scenarios. It does not support authentication mechanisms
|
12
|
+
like OAuth2, OIDC, or SAML for client applications, including web, mobile,
|
13
|
+
or other environments. For these types of user authentication, you should
|
14
|
+
use other libraries that are designed for the specific platform and
|
15
|
+
authentication method.
|
16
|
+
|
17
|
+
**Disclaimer**: This SDK is not suitable for implementing user authentication.
|
18
|
+
It does not handle authentication for client applications using OAuth2, OIDC,
|
19
|
+
or SAML and should not be used for scenarios requiring such functionality.
|
20
|
+
For those use cases, consider using other solutions that are designed for
|
21
|
+
user authentication across various platforms like web, mobile, or other
|
22
|
+
client environments.
|
23
|
+
|
24
|
+
## Getting Started
|
25
|
+
|
26
|
+
### Sign up for Zitadel
|
27
|
+
|
28
|
+
To use this SDK, you need a Zitadel account. Sign up at the official
|
29
|
+
Zitadel website and obtain the necessary credentials to access the API.
|
30
|
+
|
31
|
+
### Minimum Requirements
|
32
|
+
|
33
|
+
Ensure you have Ruby 3 or higher installed.
|
34
|
+
|
35
|
+
## Using the SDK
|
36
|
+
|
37
|
+
### Installation
|
38
|
+
|
39
|
+
Install the SDK by running one of the following commands:
|
40
|
+
|
41
|
+
```
|
42
|
+
gem install zitadel_client
|
43
|
+
```
|
44
|
+
|
45
|
+
If you're using Bundler use,
|
46
|
+
|
47
|
+
```
|
48
|
+
bundle add zitadel_client
|
49
|
+
```
|
50
|
+
|
51
|
+
## Authentication Methods
|
52
|
+
|
53
|
+
Your SDK offers three ways to authenticate with Zitadel. Each method has its
|
54
|
+
own benefits—choose the one that fits your situation best.
|
55
|
+
|
56
|
+
#### 1. Private Key JWT Authentication
|
57
|
+
|
58
|
+
**What is it?**
|
59
|
+
You use a JSON Web Token (JWT) that you sign with a private key stored in a
|
60
|
+
JSON file. This process creates a secure token.
|
61
|
+
|
62
|
+
**When should you use it?**
|
63
|
+
|
64
|
+
- **Best for production:** It offers strong security.
|
65
|
+
- **Advanced control:** You can adjust token settings like expiration.
|
66
|
+
|
67
|
+
**How do you use it?**
|
68
|
+
|
69
|
+
1. Save your private key in a JSON file.
|
70
|
+
2. Use the provided method to create an authenticator.
|
71
|
+
|
72
|
+
**Example:**
|
73
|
+
|
74
|
+
```ruby
|
75
|
+
require 'zitadel_client'
|
76
|
+
require 'securerandom'
|
77
|
+
|
78
|
+
client = ZitadelClient::Zitadel.with_private_key("https://example.us1.zitadel.cloud", "path/to/jwt-key.json")
|
79
|
+
|
80
|
+
begin
|
81
|
+
response = client.users.user_service_add_human_user(
|
82
|
+
ZitadelClient::UserServiceAddHumanUserRequest.new(
|
83
|
+
username: SecureRandom.hex,
|
84
|
+
profile: ZitadelClient::UserServiceSetHumanProfile.new(
|
85
|
+
given_name: 'John',
|
86
|
+
family_name: 'Doe'
|
87
|
+
),
|
88
|
+
email: ZitadelClient::UserServiceSetHumanEmail.new(
|
89
|
+
email: "john.doe@example.com"
|
90
|
+
)
|
91
|
+
)
|
92
|
+
)
|
93
|
+
puts "User created: #{response}"
|
94
|
+
rescue StandardError => e
|
95
|
+
puts "Error: #{e.message}"
|
96
|
+
end
|
97
|
+
```
|
98
|
+
|
99
|
+
#### 2. Client Credentials Grant
|
100
|
+
|
101
|
+
**What is it?**
|
102
|
+
This method uses a client ID and client secret to get a secure access token,
|
103
|
+
which is then used to authenticate.
|
104
|
+
|
105
|
+
**When should you use it?**
|
106
|
+
|
107
|
+
- **Simple and straightforward:** Good for server-to-server communication.
|
108
|
+
- **Trusted environments:** Use it when both servers are owned or trusted.
|
109
|
+
|
110
|
+
**How do you use it?**
|
111
|
+
|
112
|
+
1. Provide your client ID and client secret.
|
113
|
+
2. Use the provided method to create an authenticator.
|
114
|
+
|
115
|
+
**Example:**
|
116
|
+
|
117
|
+
```ruby
|
118
|
+
require 'zitadel_client'
|
119
|
+
require 'securerandom'
|
120
|
+
|
121
|
+
client = ZitadelClient::Zitadel.with_client_credentials("https://example.us1.zitadel.cloud", "id", "secret")
|
122
|
+
|
123
|
+
begin
|
124
|
+
response = client.users.user_service_add_human_user(
|
125
|
+
ZitadelClient::UserServiceAddHumanUserRequest.new(
|
126
|
+
username: SecureRandom.hex,
|
127
|
+
profile: ZitadelClient::UserServiceSetHumanProfile.new(
|
128
|
+
given_name: 'John',
|
129
|
+
family_name: 'Doe'
|
130
|
+
),
|
131
|
+
email: ZitadelClient::UserServiceSetHumanEmail.new(
|
132
|
+
email: "john.doe@example.com"
|
133
|
+
)
|
134
|
+
)
|
135
|
+
)
|
136
|
+
puts "User created: #{response}"
|
137
|
+
rescue StandardError => e
|
138
|
+
puts "Error: #{e.message}"
|
139
|
+
end
|
140
|
+
```
|
141
|
+
|
142
|
+
#### 3. Personal Access Tokens (PATs)
|
143
|
+
|
144
|
+
**What is it?**
|
145
|
+
A Personal Access Token (PAT) is a pre-generated token that you can use to
|
146
|
+
authenticate without exchanging credentials every time.
|
147
|
+
|
148
|
+
**When should you use it?**
|
149
|
+
|
150
|
+
- **Easy to use:** Great for development or testing scenarios.
|
151
|
+
- **Quick setup:** No need for dynamic token generation.
|
152
|
+
|
153
|
+
**How do you use it?**
|
154
|
+
|
155
|
+
1. Obtain a valid personal access token from your account.
|
156
|
+
2. Use the provided method to create an authenticator.
|
157
|
+
|
158
|
+
**Example:**
|
159
|
+
|
160
|
+
```ruby
|
161
|
+
require 'zitadel_client'
|
162
|
+
require 'securerandom'
|
163
|
+
|
164
|
+
client = ZitadelClient::Zitadel.with_access_token("https://example.us1.zitadel.cloud", "token")
|
165
|
+
|
166
|
+
begin
|
167
|
+
response = client.users.user_service_add_human_user(
|
168
|
+
ZitadelClient::UserServiceAddHumanUserRequest.new(
|
169
|
+
username: SecureRandom.hex,
|
170
|
+
profile: ZitadelClient::UserServiceSetHumanProfile.new(
|
171
|
+
given_name: 'John',
|
172
|
+
family_name: 'Doe'
|
173
|
+
),
|
174
|
+
email: ZitadelClient::UserServiceSetHumanEmail.new(
|
175
|
+
email: "john.doe@example.com"
|
176
|
+
)
|
177
|
+
)
|
178
|
+
)
|
179
|
+
puts "User created: #{response}"
|
180
|
+
rescue StandardError => e
|
181
|
+
puts "Error: #{e.message}"
|
182
|
+
end
|
183
|
+
```
|
184
|
+
|
185
|
+
---
|
186
|
+
|
187
|
+
Choose the authentication method that best suits your needs based on your
|
188
|
+
environment and security requirements. For more details, please refer to the
|
189
|
+
[Zitadel documentation on authenticating service users](https://zitadel.com/docs/guides/integrate/service-users/authenticate-service-users).
|
190
|
+
|
191
|
+
### Debugging
|
192
|
+
|
193
|
+
The SDK supports debug logging, which can be enabled for troubleshooting
|
194
|
+
and debugging purposes. You can enable debug logging by setting the `debug`
|
195
|
+
flag to `true` when initializing the `Zitadel` client, like this:
|
196
|
+
|
197
|
+
```ruby
|
198
|
+
zitadel = zitadel.Zitadel("your-zitadel-base-url", 'your-valid-token', lambda config: config.debug = True)
|
199
|
+
```
|
200
|
+
|
201
|
+
When enabled, the SDK will log additional information, such as HTTP request
|
202
|
+
and response details, which can be useful for identifying issues in the
|
203
|
+
integration or troubleshooting unexpected behavior.
|
204
|
+
|
205
|
+
## Design and Dependencies
|
206
|
+
|
207
|
+
This SDK is designed to be lean and efficient, focusing on providing a
|
208
|
+
streamlined way to interact with the Zitadel API. It relies on the commonly used
|
209
|
+
urllib3 HTTP transport for making requests, which ensures that
|
210
|
+
the SDK integrates well with other libraries and provides flexibility
|
211
|
+
in terms of request handling and error management.
|
212
|
+
|
213
|
+
## Versioning
|
214
|
+
|
215
|
+
This SDK follows [Semantic Versioning](https://semver.org/). You can refer to
|
216
|
+
the releases for details on the changes between versions.
|
217
|
+
|
218
|
+
## Contributing
|
219
|
+
|
220
|
+
This repository is autogenerated. We do not accept direct contributions.
|
221
|
+
Instead, please open an issue for any bugs or feature requests.
|
222
|
+
|
223
|
+
## Reporting Issues
|
224
|
+
|
225
|
+
If you encounter any issues or have suggestions for improvements, please
|
226
|
+
open an issue in the [issue tracker](https://github.com/zitadel/client-ruby/issues).
|
227
|
+
When reporting an issue, please provide the following information to help
|
228
|
+
us address it more effectively:
|
229
|
+
|
230
|
+
- A detailed description of the problem or feature request
|
231
|
+
- Steps to reproduce the issue (if applicable)
|
232
|
+
- Any relevant error messages or logs
|
233
|
+
- Environment details (e.g., OS version, relevant configurations)
|
234
|
+
|
235
|
+
## Support
|
236
|
+
|
237
|
+
If you need help setting up or configuring the SDK (or anything
|
238
|
+
Zitadel), please head over to the [Zitadel Community on Discord](https://zitadel.com/chat).
|
239
|
+
|
240
|
+
There are many helpful people in our Discord community who are ready to
|
241
|
+
assist you.
|
242
|
+
|
243
|
+
Cloud and enterprise customers can additionally reach us privately via our
|
244
|
+
[support communication channels](https://zitadel.com/docs/legal/service-description/support-services).
|
245
|
+
|
246
|
+
## License
|
247
|
+
|
248
|
+
This SDK is distributed under the Apache 2.0 License.
|
data/lib/patch.rb
ADDED
@@ -0,0 +1,26 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module OAuth2
|
4
|
+
module Strategy
|
5
|
+
# rubocop:disable Style/Documentation
|
6
|
+
module AssertionPatch
|
7
|
+
private
|
8
|
+
|
9
|
+
# noinspection RbsMissingTypeSignature
|
10
|
+
def build_assertion(claims, opts)
|
11
|
+
unless opts.is_a?(Hash) && opts.key?(:algorithm) && opts.key?(:key)
|
12
|
+
raise ArgumentError,
|
13
|
+
'encoding_opts must include :algorithm and :key'
|
14
|
+
end
|
15
|
+
|
16
|
+
headers = opts[:kid] ? { kid: opts[:kid] } : {}
|
17
|
+
JWT.encode(claims, opts[:key], opts[:algorithm], headers)
|
18
|
+
end
|
19
|
+
end
|
20
|
+
# rubocop:enable Style/Documentation
|
21
|
+
|
22
|
+
class Assertion < Base
|
23
|
+
prepend AssertionPatch
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
File without changes
|