workos 10.5.0 → 10.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/release-please.yml +3 -3
- data/.last-synced-sha +1 -1
- data/.oagen-manifest.json +415 -33
- data/.release-please-manifest.json +1 -1
- data/CHANGELOG.md +196 -0
- data/Gemfile.lock +2 -2
- data/README.md +2 -2
- data/lib/workos/agents/list_metadata.rb +22 -0
- data/lib/workos/api_keys/api_key_data_integration_vended_credential.rb +28 -0
- data/lib/workos/audit_logs.rb +2 -2
- data/lib/workos/authorization/patch_group_role_assignments.rb +22 -0
- data/lib/workos/authorization.rb +26 -0
- data/lib/workos/base_client.rb +3 -0
- data/lib/workos/client_api.rb +3 -3
- data/lib/workos/connect/connect_application.rb +3 -0
- data/lib/workos/connect/create_oauth_application.rb +3 -0
- data/lib/workos/connect/update_oauth_application.rb +5 -2
- data/lib/workos/connect.rb +6 -0
- data/lib/workos/directory_sync/directory_user_with_groups.rb +1 -1
- data/lib/workos/directory_sync.rb +160 -0
- data/lib/workos/events.rb +3 -11
- data/lib/workos/feature_flags/flag_created_data.rb +1 -46
- data/lib/workos/feature_flags/flag_deleted_data.rb +1 -1
- data/lib/workos/feature_flags/flag_rule.rb +49 -0
- data/lib/workos/feature_flags/flag_rule_updated_data.rb +1 -1
- data/lib/workos/feature_flags/flag_target.rb +52 -0
- data/lib/workos/feature_flags/flag_target_with_rule_id.rb +46 -0
- data/lib/workos/feature_flags/flag_target_with_value_type.rb +49 -0
- data/lib/workos/feature_flags/flag_updated_context_previous_attribute.rb +1 -12
- data/lib/workos/feature_flags/flag_updated_context_previous_attribute_data.rb +1 -28
- data/lib/workos/feature_flags/flag_updated_data.rb +1 -1
- data/lib/workos/groups/patch_group_memberships.rb +22 -0
- data/lib/workos/groups.rb +28 -0
- data/lib/workos/inflections.rb +30 -0
- data/lib/workos/organizations/it_contact_list_list_metadata.rb +22 -0
- data/lib/workos/organizations/organization_authentication_methods_required_oauth_error_body.rb +22 -0
- data/lib/workos/organizations/organization_connected_account_import_error_body.rb +22 -0
- data/lib/workos/organizations/organization_membership_not_found_oauth_error_body.rb +22 -0
- data/lib/workos/organizations/organization_not_found_oauth_error_body.rb +22 -0
- data/lib/workos/organizations/organization_selection_required_error_body.rb +22 -0
- data/lib/workos/organizations/organization_selection_required_error_body_with_organization.rb +7 -0
- data/lib/workos/organizations/organization_selection_required_error_body_with_organizations.rb +25 -0
- data/lib/workos/pipes/connected_account.rb +5 -2
- data/lib/workos/pipes/connected_account_input.rb +3 -0
- data/lib/workos/pipes/{connected_account_write_response_warning.rb → connected_account_warning.rb} +1 -1
- data/lib/workos/pipes/create_connected_account.rb +6 -0
- data/lib/workos/pipes/create_organization_connected_account.rb +6 -0
- data/lib/workos/pipes/data_integration_authorize_url_response.rb +9 -2
- data/lib/workos/pipes/data_integration_finish_connection_response.rb +18 -0
- data/lib/workos/pipes/data_integration_vended_credential.rb +5 -5
- data/lib/workos/pipes/data_integrations_finish_connection_request.rb +25 -0
- data/lib/workos/pipes/data_integrations_get_data_integration_authorize_url_request.rb +14 -2
- data/lib/workos/pipes/data_integrations_list_response_data_connected_account.rb +4 -1
- data/lib/workos/pipes/data_integrations_list_response_data_connected_account_warning.rb +7 -0
- data/lib/workos/pipes/data_integrations_upsert_api_key_request.rb +8 -2
- data/lib/workos/pipes/data_integrations_upsert_client_credentials_request.rb +8 -2
- data/lib/workos/pipes/organization_connected_account.rb +3 -0
- data/lib/workos/pipes.rb +80 -27
- data/lib/workos/pipes_provider.rb +12 -0
- data/lib/workos/session.rb +12 -0
- data/lib/workos/shared/access_denied_oauth_error_body.rb +22 -0
- data/lib/workos/shared/account_selection_required_error_body.rb +7 -0
- data/lib/workos/shared/agent_registration_claim_completed_data.rb +3 -0
- data/lib/workos/shared/already_claimed_error_body.rb +22 -0
- data/lib/workos/shared/application_consent_required_error_body.rb +22 -0
- data/lib/workos/shared/auth_method_mismatch_error_body.rb +7 -0
- data/lib/workos/shared/authorization_pending_oauth_error_body.rb +22 -0
- data/lib/workos/shared/authorization_url_not_found_error_body.rb +22 -0
- data/lib/workos/shared/authorization_url_request_error_body.rb +22 -0
- data/lib/workos/shared/client_credentials_data_integration_vended_credential.rb +40 -0
- data/lib/workos/shared/code_challenge_not_found_error_body.rb +22 -0
- data/lib/workos/shared/connect_application_oauth.rb +3 -0
- data/lib/workos/shared/connected_account_limit_reached_error_body.rb +22 -0
- data/lib/workos/shared/daily_quota_exceeded_error_body.rb +22 -0
- data/lib/workos/shared/data_integration_access_token_response_with_access_token.rb +22 -0
- data/lib/workos/shared/data_integration_access_token_response_with_access_token_access_token.rb +7 -0
- data/lib/workos/shared/data_integration_access_token_response_with_error.rb +22 -0
- data/lib/workos/shared/data_integration_credentials_response_with_credential.rb +22 -0
- data/lib/workos/shared/data_integration_credentials_response_with_error.rb +22 -0
- data/lib/workos/shared/entity_not_found_error_body.rb +22 -0
- data/lib/workos/shared/error_body.rb +7 -0
- data/lib/workos/shared/error_body_with_code.rb +22 -0
- data/lib/workos/shared/error_body_with_code_errors.rb +25 -0
- data/lib/workos/shared/error_body_with_code_field_error.rb +22 -0
- data/lib/workos/shared/error_body_with_code_field_errors.rb +22 -0
- data/lib/workos/shared/error_body_with_code_instance_path_error.rb +18 -0
- data/lib/workos/shared/error_body_with_code_instance_path_errors.rb +25 -0
- data/lib/workos/shared/error_body_with_code_status_code.rb +25 -0
- data/lib/workos/shared/error_body_with_constraints_property_error.rb +22 -0
- data/lib/workos/shared/error_body_with_constraints_property_errors.rb +22 -0
- data/lib/workos/shared/error_body_with_error.rb +22 -0
- data/lib/workos/shared/error_body_with_error_message_list.rb +22 -0
- data/lib/workos/shared/error_body_with_message_or_message_list.rb +18 -0
- data/lib/workos/shared/expired_token_oauth_error_body.rb +22 -0
- data/lib/workos/shared/external_auth_session_already_completed_error_body.rb +22 -0
- data/lib/workos/shared/external_id_already_used_error_body.rb +22 -0
- data/lib/workos/shared/extra_attributes_required_oauth_error_body.rb +22 -0
- data/lib/workos/shared/feature_flags_flag_created.rb +34 -0
- data/lib/workos/shared/feature_flags_flag_created_context.rb +22 -0
- data/lib/workos/shared/feature_flags_flag_created_context_actor.rb +25 -0
- data/lib/workos/shared/feature_flags_flag_created_data.rb +52 -0
- data/lib/workos/shared/feature_flags_flag_created_data_owner.rb +7 -0
- data/lib/workos/shared/feature_flags_flag_deleted.rb +34 -0
- data/lib/workos/shared/feature_flags_flag_deleted_context.rb +22 -0
- data/lib/workos/shared/feature_flags_flag_deleted_context_actor.rb +25 -0
- data/lib/workos/shared/feature_flags_flag_deleted_data.rb +7 -0
- data/lib/workos/shared/feature_flags_flag_deleted_data_owner.rb +7 -0
- data/lib/workos/shared/feature_flags_flag_rule_created.rb +34 -0
- data/lib/workos/shared/feature_flags_flag_rule_created_context.rb +22 -0
- data/lib/workos/shared/feature_flags_flag_rule_created_context_actor.rb +25 -0
- data/lib/workos/shared/feature_flags_flag_rule_deleted.rb +34 -0
- data/lib/workos/shared/feature_flags_flag_rule_deleted_context.rb +22 -0
- data/lib/workos/shared/feature_flags_flag_rule_deleted_context_actor.rb +25 -0
- data/lib/workos/shared/feature_flags_flag_rule_updated.rb +34 -0
- data/lib/workos/shared/feature_flags_flag_rule_updated_context.rb +25 -0
- data/lib/workos/shared/feature_flags_flag_rule_updated_context_actor.rb +25 -0
- data/lib/workos/shared/feature_flags_flag_rule_updated_context_previous_attribute.rb +18 -0
- data/lib/workos/shared/feature_flags_flag_rule_updated_context_previous_attribute_data.rb +18 -0
- data/lib/workos/shared/feature_flags_flag_target_created.rb +34 -0
- data/lib/workos/shared/feature_flags_flag_target_created_context.rb +22 -0
- data/lib/workos/shared/feature_flags_flag_target_created_context_actor.rb +25 -0
- data/lib/workos/shared/feature_flags_flag_target_deleted.rb +34 -0
- data/lib/workos/shared/feature_flags_flag_target_deleted_context.rb +22 -0
- data/lib/workos/shared/feature_flags_flag_target_deleted_context_actor.rb +25 -0
- data/lib/workos/shared/feature_flags_flag_updated.rb +34 -0
- data/lib/workos/shared/feature_flags_flag_updated_context.rb +25 -0
- data/lib/workos/shared/feature_flags_flag_updated_context_actor.rb +25 -0
- data/lib/workos/shared/feature_flags_flag_updated_context_previous_attribute.rb +18 -0
- data/lib/workos/shared/feature_flags_flag_updated_context_previous_attribute_data.rb +34 -0
- data/lib/workos/shared/feature_flags_flag_updated_context_previous_attribute_data_owner.rb +7 -0
- data/lib/workos/shared/feature_flags_flag_updated_data.rb +7 -0
- data/lib/workos/shared/feature_flags_flag_updated_data_owner.rb +7 -0
- data/lib/workos/shared/idp_metadata_fetch_failed_error_body.rb +22 -0
- data/lib/workos/shared/invalid_client_oauth_error_body.rb +22 -0
- data/lib/workos/shared/invalid_connection_oauth_error_body.rb +22 -0
- data/lib/workos/shared/invalid_credentials_error_body.rb +22 -0
- data/lib/workos/shared/invalid_email_error_body.rb +22 -0
- data/lib/workos/shared/invalid_grant_oauth_error_body.rb +22 -0
- data/lib/workos/shared/invalid_idp_sso_url_error_body.rb +22 -0
- data/lib/workos/shared/invalid_link_authorization_code_oauth_error_body.rb +22 -0
- data/lib/workos/shared/invalid_locale_error_body.rb +22 -0
- data/lib/workos/shared/invalid_metadata_error_body.rb +22 -0
- data/lib/workos/shared/invalid_one_time_code_error_body.rb +22 -0
- data/lib/workos/shared/invalid_organization_id_error_body.rb +22 -0
- data/lib/workos/shared/invalid_password_hash_error_body.rb +22 -0
- data/lib/workos/shared/invalid_pending_authentication_token_error_body.rb +22 -0
- data/lib/workos/shared/invalid_profile_oauth_error_body.rb +22 -0
- data/lib/workos/shared/invalid_refresh_token_error_body.rb +22 -0
- data/lib/workos/shared/invalid_request_oauth_error_body.rb +22 -0
- data/lib/workos/shared/invalid_request_parameters_error_body.rb +22 -0
- data/lib/workos/shared/invalid_request_parameters_error_body_with_errors.rb +25 -0
- data/lib/workos/shared/invalid_role_error_body.rb +22 -0
- data/lib/workos/shared/invalid_url_error_body.rb +22 -0
- data/lib/workos/shared/mfa_challenge_error_body.rb +22 -0
- data/lib/workos/shared/mfa_enrollment_error_body.rb +22 -0
- data/lib/workos/shared/mfa_enrollment_oauth_error_body.rb +22 -0
- data/lib/workos/shared/multiple_roles_not_enabled_error_body.rb +22 -0
- data/lib/workos/shared/must_use_sso_for_selected_organization_message_error_body.rb +18 -0
- data/lib/workos/shared/oauth_data_integration_vended_credential.rb +40 -0
- data/lib/workos/shared/oauth_error_body.rb +22 -0
- data/lib/workos/shared/one_time_code_expired_error_body.rb +22 -0
- data/lib/workos/shared/one_time_code_previously_used_error_body.rb +22 -0
- data/lib/workos/shared/one_time_code_too_many_attempts_error_body.rb +22 -0
- data/lib/workos/shared/passkey_progressive_enrollment_error_body.rb +22 -0
- data/lib/workos/shared/phone_number_required_error_body.rb +22 -0
- data/lib/workos/shared/pkce_not_supported_oauth_error_body.rb +22 -0
- data/lib/workos/shared/policy_denied_error_body.rb +25 -0
- data/lib/workos/shared/radar_challenge_error_body.rb +22 -0
- data/lib/workos/shared/radar_sign_up_challenge_error_body.rb +22 -0
- data/lib/workos/shared/radar_sms_sign_in_challenge_error_body.rb +22 -0
- data/lib/workos/shared/rate_limit_exceeded_error_body_with_retry_after.rb +25 -0
- data/lib/workos/shared/sign_up_not_allowed_oauth_error_body.rb +22 -0
- data/lib/workos/shared/slow_down_oauth_error_body.rb +22 -0
- data/lib/workos/shared/sms_challenge_quota_reached_error_body.rb +22 -0
- data/lib/workos/shared/sms_challenge_rate_limited_error_body.rb +22 -0
- data/lib/workos/shared/sso_required_oauth_error_body_with_connection_ids_list_email.rb +31 -0
- data/lib/workos/shared/sub_resource_scoped_role_not_allowed_error_body_with_role_slug.rb +25 -0
- data/lib/workos/shared/token_too_big_oauth_error_body.rb +22 -0
- data/lib/workos/shared/too_many_failed_verification_attempts_error_body_with_retry_after.rb +25 -0
- data/lib/workos/shared/too_many_requests_oauth_error_body.rb +22 -0
- data/lib/workos/shared/unauthorized_client_oauth_error_body.rb +22 -0
- data/lib/workos/shared/unauthorized_error_body.rb +18 -0
- data/lib/workos/shared/update_audit_logs_retention_with_retention_period.rb +18 -0
- data/lib/workos/shared/update_audit_logs_retention_with_retention_period_in_days.rb +26 -0
- data/lib/workos/shared/update_user_organization_membership_with_role_slug.rb +18 -0
- data/lib/workos/shared/update_user_organization_membership_with_role_slugs.rb +18 -0
- data/lib/workos/shared/verification_id_required_error_body.rb +22 -0
- data/lib/workos/sso/connection_could_not_be_verified_error_body.rb +22 -0
- data/lib/workos/sso/connection_creation_conflict_error_body.rb +22 -0
- data/lib/workos/sso/connection_creation_not_found_error_body.rb +22 -0
- data/lib/workos/sso/connection_finish_error_body.rb +22 -0
- data/lib/workos/sso/connection_type_not_updatable_error_body.rb +22 -0
- data/lib/workos/sso.rb +6 -2
- data/lib/workos/types/authorization_url_not_found_error_body_code.rb +14 -0
- data/lib/workos/types/authorization_url_request_error_body_code.rb +14 -0
- data/lib/workos/types/connection_creation_conflict_error_body_code.rb +13 -0
- data/lib/workos/types/connection_creation_not_found_error_body_code.rb +13 -0
- data/lib/workos/types/connection_finish_error_body_code.rb +29 -0
- data/lib/workos/types/connections_state.rb +14 -0
- data/lib/workos/types/create_data_integration_ownership.rb +5 -1
- data/lib/workos/types/create_magic_code_and_return_locale.rb +101 -0
- data/lib/workos/types/{connected_account_write_response_auth_method.rb → create_password_reset_token_locale.rb} +1 -1
- data/lib/workos/types/create_user_invite_options_locale.rb +1 -93
- data/lib/workos/types/create_webhook_endpoint_events.rb +9 -1
- data/lib/workos/types/data_integration_access_token_response_with_error_error.rb +9 -0
- data/lib/workos/types/data_integration_credentials_response_with_error_error.rb +9 -0
- data/lib/workos/types/data_integration_ownership.rb +1 -1
- data/lib/workos/types/{connected_account_write_response_connection_role.rb → data_integration_vended_credential_auth_method.rb} +1 -1
- data/lib/workos/types/data_integrations_create_api_key_connection_request_connection_owner.rb +1 -1
- data/lib/workos/types/data_integrations_create_client_credentials_connection_request_connection_owner.rb +1 -1
- data/lib/workos/types/data_integrations_get_data_integration_authorize_url_request_connection_intent.rb +13 -0
- data/lib/workos/types/data_integrations_get_data_integration_authorize_url_request_connection_owner.rb +1 -1
- data/lib/workos/types/data_integrations_get_user_token_request_connection_owner.rb +1 -1
- data/lib/workos/types/data_integrations_list_response_data_connection_owner.rb +1 -1
- data/lib/workos/types/data_integrations_upsert_api_key_request_connection_owner.rb +1 -1
- data/lib/workos/types/data_integrations_upsert_client_credentials_request_connection_owner.rb +1 -1
- data/lib/workos/types/data_integrations_vend_credentials_request_connection_owner.rb +1 -1
- data/lib/workos/types/error_body_code.rb +182 -0
- data/lib/workos/types/feature_flags_flag_created_context_actor_source.rb +9 -0
- data/lib/workos/types/feature_flags_flag_deleted_context_actor_source.rb +9 -0
- data/lib/workos/types/feature_flags_flag_rule_created_context_actor_source.rb +9 -0
- data/lib/workos/types/feature_flags_flag_rule_deleted_context_actor_source.rb +9 -0
- data/lib/workos/types/feature_flags_flag_rule_updated_context_actor_source.rb +9 -0
- data/lib/workos/types/feature_flags_flag_target_created_context_actor_source.rb +9 -0
- data/lib/workos/types/feature_flags_flag_target_deleted_context_actor_source.rb +9 -0
- data/lib/workos/types/feature_flags_flag_updated_context_actor_source.rb +9 -0
- data/lib/workos/types/organization_connected_account_import_error_body_code.rb +14 -0
- data/lib/workos/types/pipes_ownership.rb +1 -1
- data/lib/workos/types/{connected_account_write_response_state.rb → pipes_provider_ownership.rb} +1 -1
- data/lib/workos/types/resend_user_invite_options_locale.rb +1 -1
- data/lib/workos/types/resource_export_completed_data_resource_type.rb +3 -1
- data/lib/workos/types/send_email_change_locale.rb +9 -0
- data/lib/workos/types/send_verification_email_locale.rb +9 -0
- data/lib/workos/types/update_audit_logs_retention_with_retention_period_retention_period.rb +9 -0
- data/lib/workos/types/user_connected_account_import_error_body_code.rb +15 -0
- data/lib/workos/types/widget_session_token_scopes.rb +3 -1
- data/lib/workos/user_management/action_denied_error_body.rb +22 -0
- data/lib/workos/user_management/authentication_email_verification_failed_data_error.rb +5 -2
- data/lib/workos/user_management/authentication_method_not_allowed_error_body.rb +22 -0
- data/lib/workos/user_management/authentication_method_not_allowed_oauth_error_body.rb +22 -0
- data/lib/workos/user_management/authentication_radar_risk_detected_data.rb +5 -2
- data/lib/workos/user_management/create_magic_code_and_return.rb +5 -2
- data/lib/workos/user_management/create_password_reset_token.rb +16 -1
- data/lib/workos/user_management/email_already_in_use_error_body.rb +22 -0
- data/lib/workos/user_management/email_already_verified_error_body.rb +22 -0
- data/lib/workos/user_management/email_change_not_allowed_error_body.rb +22 -0
- data/lib/workos/user_management/email_completion_required_error_body_with_email_completion_token.rb +25 -0
- data/lib/workos/user_management/email_domain_not_deliverable_error_body.rb +22 -0
- data/lib/workos/user_management/email_not_available_error_body.rb +22 -0
- data/lib/workos/user_management/email_password_auth_disabled_error_body.rb +22 -0
- data/lib/workos/user_management/email_verification_required_error_body.rb +22 -0
- data/lib/workos/user_management/invitation_cannot_be_used_for_email_oauth_error_body.rb +22 -0
- data/lib/workos/user_management/invitation_invalid_oauth_error_body.rb +22 -0
- data/lib/workos/user_management/password_and_password_hash_provided_error_body.rb +22 -0
- data/lib/workos/user_management/password_and_password_hash_type_provided_error_body.rb +22 -0
- data/lib/workos/user_management/password_salt_position_requires_password_hash_error_body.rb +22 -0
- data/lib/workos/user_management/password_strength_error_error_body_with_errors.rb +25 -0
- data/lib/workos/user_management/send_email_change.rb +6 -2
- data/lib/workos/user_management/send_verification_email.rb +18 -0
- data/lib/workos/user_management/user_connected_account_import_error_body.rb +22 -0
- data/lib/workos/user_management/user_consent_options_not_supported_error_body.rb +22 -0
- data/lib/workos/user_management/user_creation_error_error_body_with_errors.rb +25 -0
- data/lib/workos/user_management/user_mismatch_error_body.rb +22 -0
- data/lib/workos/user_management/waitlist_list_response.rb +25 -0
- data/lib/workos/user_management/waitlist_list_response_list_metadata.rb +7 -0
- data/lib/workos/user_management.rb +25 -10
- data/lib/workos/version.rb +1 -1
- data/rbi/workos/access_denied_oauth_error_body.rbi +30 -0
- data/rbi/workos/account_selection_required_error_body.rbi +9 -0
- data/rbi/workos/{connected_account_write_response_warning.rbi → action_denied_error_body.rbi} +1 -1
- data/rbi/workos/admin_portal.rbi +2 -2
- data/rbi/workos/agent_blueprint_invocable_by.rbi +1 -22
- data/rbi/workos/agent_blueprint_updated_data_invocable_by.rbi +1 -22
- data/rbi/workos/agent_blueprint_updated_data_session_setting.rbi +1 -28
- data/rbi/workos/agent_blueprints_create_request_session_setting.rbi +1 -28
- data/rbi/workos/agent_blueprints_update_request_invocable_by.rbi +1 -22
- data/rbi/workos/agent_registration_claim_completed_data.rbi +6 -0
- data/rbi/workos/agent_registration_expired_data.rbi +1 -16
- data/rbi/workos/agent_registration_refreshed_data.rbi +1 -16
- data/rbi/workos/agent_registration_revoked_data.rbi +1 -16
- data/rbi/workos/agents.rbi +20 -20
- data/rbi/workos/already_claimed_error_body.rbi +30 -0
- data/rbi/workos/api_key_data_integration_vended_credential.rbi +42 -0
- data/rbi/workos/api_key_owner.rbi +1 -22
- data/rbi/workos/api_key_revoked_data.rbi +1 -70
- data/rbi/workos/api_key_revoked_data_owner.rbi +1 -22
- data/rbi/workos/api_key_updated_data_owner.rbi +1 -22
- data/rbi/workos/api_keys.rbi +5 -5
- data/rbi/workos/application_consent_required_error_body.rbi +30 -0
- data/rbi/workos/audit_log_event_target.rbi +1 -34
- data/rbi/workos/audit_log_schema_actor_input.rbi +1 -16
- data/rbi/workos/audit_log_schema_target_input.rbi +1 -22
- data/rbi/workos/audit_logs.rbi +10 -10
- data/rbi/workos/auth_method_mismatch_error_body.rbi +9 -0
- data/rbi/workos/authentication_email_verification_failed_data_error.rbi +6 -0
- data/rbi/workos/authentication_factor_sms.rbi +1 -16
- data/rbi/workos/authentication_magic_auth_failed_data_error.rbi +1 -22
- data/rbi/workos/authentication_method_not_allowed_error_body.rbi +30 -0
- data/rbi/workos/authentication_method_not_allowed_oauth_error_body.rbi +30 -0
- data/rbi/workos/authentication_mfa_failed_data_error.rbi +1 -22
- data/rbi/workos/authentication_oauth_failed_data_error.rbi +1 -22
- data/rbi/workos/authentication_passkey_failed_data_error.rbi +1 -22
- data/rbi/workos/authentication_password_failed_data_error.rbi +1 -22
- data/rbi/workos/authentication_radar_risk_detected_data.rbi +6 -0
- data/rbi/workos/authentication_sso_failed_data_error.rbi +1 -22
- data/rbi/workos/authentication_sso_started_data_sso.rbi +1 -28
- data/rbi/workos/authentication_sso_succeeded_data_sso.rbi +1 -28
- data/rbi/workos/authentication_sso_timed_out_data_error.rbi +1 -22
- data/rbi/workos/authentication_sso_timed_out_data_sso.rbi +1 -28
- data/rbi/workos/authorization.rbi +57 -45
- data/rbi/workos/authorization_pending_oauth_error_body.rbi +30 -0
- data/rbi/workos/authorization_url_not_found_error_body.rbi +30 -0
- data/rbi/workos/authorization_url_request_error_body.rbi +30 -0
- data/rbi/workos/claim_view_response_organization.rbi +1 -22
- data/rbi/workos/client_api.rbi +1 -1
- data/rbi/workos/client_credentials_data_integration_vended_credential.rbi +66 -0
- data/rbi/workos/code_challenge_not_found_error_body.rbi +30 -0
- data/rbi/workos/confirm_email_change.rbi +1 -16
- data/rbi/workos/connect.rbi +12 -10
- data/rbi/workos/connect_application.rbi +42 -0
- data/rbi/workos/connect_application_oauth.rbi +6 -0
- data/rbi/workos/connect_application_redirect_uri.rbi +30 -0
- data/rbi/workos/connected_account.rbi +6 -0
- data/rbi/workos/connected_account_input.rbi +6 -0
- data/rbi/workos/connected_account_limit_reached_error_body.rbi +30 -0
- data/rbi/workos/connected_account_warning.rbi +30 -0
- data/rbi/workos/connection_could_not_be_verified_error_body.rbi +30 -0
- data/rbi/workos/connection_creation_conflict_error_body.rbi +30 -0
- data/rbi/workos/connection_creation_not_found_error_body.rbi +30 -0
- data/rbi/workos/connection_deactivated_data_domain.rbi +1 -28
- data/rbi/workos/connection_domain.rbi +1 -28
- data/rbi/workos/connection_finish_error_body.rbi +30 -0
- data/rbi/workos/connection_saml_certificate_renewed_data_connection.rbi +1 -22
- data/rbi/workos/connection_type_not_updatable_error_body.rbi +30 -0
- data/rbi/workos/create_connected_account.rbi +12 -0
- data/rbi/workos/create_group_role_assignment.rbi +1 -34
- data/rbi/workos/create_magic_code_and_return.rbi +6 -0
- data/rbi/workos/create_oauth_application.rbi +6 -0
- data/rbi/workos/create_organization_connected_account.rbi +12 -0
- data/rbi/workos/create_password_reset_token.rbi +6 -0
- data/rbi/workos/create_role.rbi +1 -34
- data/rbi/workos/daily_quota_exceeded_error_body.rbi +30 -0
- data/rbi/workos/data_integration_access_token_response_with_access_token.rbi +30 -0
- data/rbi/workos/data_integration_access_token_response_with_access_token_access_token.rbi +9 -0
- data/rbi/workos/data_integration_access_token_response_with_error.rbi +30 -0
- data/rbi/workos/data_integration_authorize_url_response.rbi +12 -0
- data/rbi/workos/data_integration_credentials_response_with_credential.rbi +30 -0
- data/rbi/workos/data_integration_credentials_response_with_error.rbi +30 -0
- data/rbi/workos/data_integration_finish_connection_response.rbi +24 -0
- data/rbi/workos/data_integration_vended_credential.rbi +6 -6
- data/rbi/workos/data_integrations_finish_connection_request.rbi +36 -0
- data/rbi/workos/data_integrations_get_data_integration_authorize_url_request.rbi +24 -0
- data/rbi/workos/data_integrations_list_response_data_connected_account.rbi +6 -0
- data/rbi/workos/data_integrations_list_response_data_connected_account_warning.rbi +9 -0
- data/rbi/workos/data_integrations_upsert_api_key_request.rbi +12 -0
- data/rbi/workos/data_integrations_upsert_client_credentials_request.rbi +12 -0
- data/rbi/workos/delete_group_role_assignments_by_criteria.rbi +1 -34
- data/rbi/workos/directory_sync.rbi +54 -8
- data/rbi/workos/directory_user_with_groups_email.rbi +1 -28
- data/rbi/workos/dsync_group_user_removed_data.rbi +1 -28
- data/rbi/workos/dsync_token_revoked_data.rbi +1 -46
- data/rbi/workos/dsync_user_updated_data_email.rbi +1 -28
- data/rbi/workos/email_already_in_use_error_body.rbi +30 -0
- data/rbi/workos/email_already_verified_error_body.rbi +30 -0
- data/rbi/workos/email_change_not_allowed_error_body.rbi +30 -0
- data/rbi/workos/email_completion_required_error_body_with_email_completion_token.rbi +36 -0
- data/rbi/workos/email_domain_not_deliverable_error_body.rbi +30 -0
- data/rbi/workos/email_not_available_error_body.rbi +30 -0
- data/rbi/workos/email_password_auth_disabled_error_body.rbi +30 -0
- data/rbi/workos/email_verification_required_error_body.rbi +30 -0
- data/rbi/workos/entity_not_found_error_body.rbi +30 -0
- data/rbi/workos/error_body.rbi +9 -0
- data/rbi/workos/error_body_with_code.rbi +30 -0
- data/rbi/workos/error_body_with_code_errors.rbi +36 -0
- data/rbi/workos/error_body_with_code_field_error.rbi +30 -0
- data/rbi/workos/error_body_with_code_field_errors.rbi +30 -0
- data/rbi/workos/error_body_with_code_instance_path_error.rbi +24 -0
- data/rbi/workos/error_body_with_code_instance_path_errors.rbi +36 -0
- data/rbi/workos/error_body_with_code_status_code.rbi +36 -0
- data/rbi/workos/error_body_with_constraints_property_error.rbi +30 -0
- data/rbi/workos/error_body_with_constraints_property_errors.rbi +30 -0
- data/rbi/workos/error_body_with_error.rbi +30 -0
- data/rbi/workos/error_body_with_error_message_list.rbi +30 -0
- data/rbi/workos/error_body_with_message_or_message_list.rbi +24 -0
- data/rbi/workos/events.rbi +1 -3
- data/rbi/workos/expired_token_oauth_error_body.rbi +30 -0
- data/rbi/workos/external_auth_session_already_completed_error_body.rbi +30 -0
- data/rbi/workos/external_id_already_used_error_body.rbi +30 -0
- data/rbi/workos/extra_attributes_required_oauth_error_body.rbi +30 -0
- data/rbi/workos/feature_flags.rbi +8 -8
- data/rbi/workos/feature_flags_flag_created.rbi +54 -0
- data/rbi/workos/feature_flags_flag_created_context.rbi +30 -0
- data/rbi/workos/feature_flags_flag_created_context_actor.rbi +36 -0
- data/rbi/workos/feature_flags_flag_created_data.rbi +90 -0
- data/rbi/workos/feature_flags_flag_created_data_owner.rbi +9 -0
- data/rbi/workos/feature_flags_flag_deleted.rbi +54 -0
- data/rbi/workos/feature_flags_flag_deleted_context.rbi +30 -0
- data/rbi/workos/feature_flags_flag_deleted_context_actor.rbi +36 -0
- data/rbi/workos/feature_flags_flag_deleted_data.rbi +9 -0
- data/rbi/workos/feature_flags_flag_deleted_data_owner.rbi +9 -0
- data/rbi/workos/feature_flags_flag_rule_created.rbi +54 -0
- data/rbi/workos/feature_flags_flag_rule_created_context.rbi +30 -0
- data/rbi/workos/feature_flags_flag_rule_created_context_actor.rbi +36 -0
- data/rbi/workos/feature_flags_flag_rule_deleted.rbi +54 -0
- data/rbi/workos/feature_flags_flag_rule_deleted_context.rbi +30 -0
- data/rbi/workos/feature_flags_flag_rule_deleted_context_actor.rbi +36 -0
- data/rbi/workos/feature_flags_flag_rule_updated.rbi +54 -0
- data/rbi/workos/feature_flags_flag_rule_updated_context.rbi +36 -0
- data/rbi/workos/feature_flags_flag_rule_updated_context_actor.rbi +36 -0
- data/rbi/workos/feature_flags_flag_rule_updated_context_previous_attribute.rbi +24 -0
- data/rbi/workos/feature_flags_flag_rule_updated_context_previous_attribute_data.rbi +24 -0
- data/rbi/workos/feature_flags_flag_target_created.rbi +54 -0
- data/rbi/workos/feature_flags_flag_target_created_context.rbi +30 -0
- data/rbi/workos/feature_flags_flag_target_created_context_actor.rbi +36 -0
- data/rbi/workos/feature_flags_flag_target_deleted.rbi +54 -0
- data/rbi/workos/feature_flags_flag_target_deleted_context.rbi +30 -0
- data/rbi/workos/feature_flags_flag_target_deleted_context_actor.rbi +36 -0
- data/rbi/workos/feature_flags_flag_updated.rbi +54 -0
- data/rbi/workos/feature_flags_flag_updated_context.rbi +36 -0
- data/rbi/workos/feature_flags_flag_updated_context_actor.rbi +36 -0
- data/rbi/workos/feature_flags_flag_updated_context_previous_attribute.rbi +24 -0
- data/rbi/workos/feature_flags_flag_updated_context_previous_attribute_data.rbi +54 -0
- data/rbi/workos/feature_flags_flag_updated_context_previous_attribute_data_owner.rbi +9 -0
- data/rbi/workos/feature_flags_flag_updated_data.rbi +9 -0
- data/rbi/workos/feature_flags_flag_updated_data_owner.rbi +9 -0
- data/rbi/workos/flag.rbi +1 -76
- data/rbi/workos/flag_created_data.rbi +1 -82
- data/rbi/workos/flag_created_data_owner.rbi +1 -28
- data/rbi/workos/flag_deleted_data.rbi +1 -82
- data/rbi/workos/flag_deleted_data_owner.rbi +1 -28
- data/rbi/workos/flag_owner.rbi +1 -28
- data/rbi/workos/flag_rule.rbi +84 -0
- data/rbi/workos/flag_rule_updated_context_configured_target_organization.rbi +1 -22
- data/rbi/workos/flag_rule_updated_context_previous_attribute_context_configured_target.rbi +1 -22
- data/rbi/workos/flag_rule_updated_context_previous_attribute_context_configured_target_organization.rbi +1 -22
- data/rbi/workos/flag_rule_updated_context_previous_attribute_context_configured_target_user.rbi +1 -22
- data/rbi/workos/flag_rule_updated_data.rbi +1 -82
- data/rbi/workos/flag_rule_updated_data_owner.rbi +1 -28
- data/rbi/workos/flag_target.rbi +90 -0
- data/rbi/workos/flag_target_with_rule_id.rbi +78 -0
- data/rbi/workos/flag_target_with_value_type.rbi +84 -0
- data/rbi/workos/flag_updated_context_previous_attribute.rbi +1 -16
- data/rbi/workos/flag_updated_context_previous_attribute_data.rbi +1 -46
- data/rbi/workos/flag_updated_context_previous_attribute_data_owner.rbi +1 -28
- data/rbi/workos/flag_updated_data.rbi +1 -82
- data/rbi/workos/flag_updated_data_owner.rbi +1 -28
- data/rbi/workos/group_member_removed_data.rbi +1 -22
- data/rbi/workos/group_role_assignment_list.rbi +36 -0
- data/rbi/workos/groups.rbi +19 -8
- data/rbi/workos/idp_metadata_fetch_failed_error_body.rbi +30 -0
- data/rbi/workos/invalid_client_oauth_error_body.rbi +30 -0
- data/rbi/workos/invalid_connection_oauth_error_body.rbi +30 -0
- data/rbi/workos/invalid_credentials_error_body.rbi +30 -0
- data/rbi/workos/invalid_email_error_body.rbi +30 -0
- data/rbi/workos/invalid_grant_oauth_error_body.rbi +30 -0
- data/rbi/workos/invalid_idp_sso_url_error_body.rbi +30 -0
- data/rbi/workos/invalid_link_authorization_code_oauth_error_body.rbi +30 -0
- data/rbi/workos/invalid_locale_error_body.rbi +30 -0
- data/rbi/workos/invalid_metadata_error_body.rbi +30 -0
- data/rbi/workos/invalid_one_time_code_error_body.rbi +30 -0
- data/rbi/workos/invalid_organization_id_error_body.rbi +30 -0
- data/rbi/workos/invalid_password_hash_error_body.rbi +30 -0
- data/rbi/workos/invalid_pending_authentication_token_error_body.rbi +30 -0
- data/rbi/workos/invalid_profile_oauth_error_body.rbi +30 -0
- data/rbi/workos/invalid_refresh_token_error_body.rbi +30 -0
- data/rbi/workos/invalid_request_oauth_error_body.rbi +30 -0
- data/rbi/workos/invalid_request_parameters_error_body.rbi +30 -0
- data/rbi/workos/invalid_request_parameters_error_body_with_errors.rbi +36 -0
- data/rbi/workos/invalid_role_error_body.rbi +30 -0
- data/rbi/workos/invalid_url_error_body.rbi +30 -0
- data/rbi/workos/invitation_cannot_be_used_for_email_oauth_error_body.rbi +30 -0
- data/rbi/workos/invitation_invalid_oauth_error_body.rbi +30 -0
- data/rbi/workos/it_contact_list.rbi +36 -0
- data/rbi/workos/it_contact_list_list_metadata.rbi +30 -0
- data/rbi/workos/list_metadata.rbi +30 -0
- data/rbi/workos/mfa_challenge_error_body.rbi +30 -0
- data/rbi/workos/mfa_enrollment_error_body.rbi +30 -0
- data/rbi/workos/mfa_enrollment_oauth_error_body.rbi +30 -0
- data/rbi/workos/multi_factor_auth.rbi +7 -7
- data/rbi/workos/multiple_roles_not_enabled_error_body.rbi +30 -0
- data/rbi/workos/must_use_sso_for_selected_organization_message_error_body.rbi +24 -0
- data/rbi/workos/oauth_data_integration_vended_credential.rbi +66 -0
- data/rbi/workos/oauth_error_body.rbi +30 -0
- data/rbi/workos/one_time_code_expired_error_body.rbi +30 -0
- data/rbi/workos/one_time_code_previously_used_error_body.rbi +30 -0
- data/rbi/workos/one_time_code_too_many_attempts_error_body.rbi +30 -0
- data/rbi/workos/organization_api_key_owner.rbi +1 -22
- data/rbi/workos/organization_api_key_with_value_owner.rbi +1 -22
- data/rbi/workos/organization_authentication_methods_required_oauth_error_body.rbi +30 -0
- data/rbi/workos/organization_connected_account.rbi +6 -0
- data/rbi/workos/organization_connected_account_import_error_body.rbi +30 -0
- data/rbi/workos/organization_domains.rbi +4 -4
- data/rbi/workos/organization_membership_not_found_oauth_error_body.rbi +30 -0
- data/rbi/workos/organization_membership_service.rbi +8 -8
- data/rbi/workos/organization_not_found_oauth_error_body.rbi +30 -0
- data/rbi/workos/organization_role_deleted_data.rbi +1 -64
- data/rbi/workos/organization_role_updated_data.rbi +1 -64
- data/rbi/workos/organization_selection_required_error_body.rbi +30 -0
- data/rbi/workos/organization_selection_required_error_body_with_organization.rbi +9 -0
- data/rbi/workos/organization_selection_required_error_body_with_organizations.rbi +36 -0
- data/rbi/workos/organizations.rbi +13 -13
- data/rbi/workos/passkey_progressive_enrollment_error_body.rbi +30 -0
- data/rbi/workos/password_and_password_hash_provided_error_body.rbi +30 -0
- data/rbi/workos/password_and_password_hash_type_provided_error_body.rbi +30 -0
- data/rbi/workos/password_reset_succeeded_data.rbi +1 -46
- data/rbi/workos/password_salt_position_requires_password_hash_error_body.rbi +30 -0
- data/rbi/workos/password_strength_error_error_body_with_errors.rbi +36 -0
- data/rbi/workos/patch_connection_standard_attributes.rbi +1 -46
- data/rbi/workos/patch_group_memberships.rbi +30 -0
- data/rbi/workos/patch_group_role_assignments.rbi +30 -0
- data/rbi/workos/permission.rbi +1 -64
- data/rbi/workos/permission_created_data.rbi +1 -64
- data/rbi/workos/permission_deleted_data.rbi +1 -64
- data/rbi/workos/permission_updated_data.rbi +1 -64
- data/rbi/workos/phone_number_required_error_body.rbi +30 -0
- data/rbi/workos/pipes.rbi +57 -33
- data/rbi/workos/pipes_account_connection_connection_failed_data.rbi +1 -76
- data/rbi/workos/pipes_connected_account_connection_failed_data.rbi +1 -76
- data/rbi/workos/pipes_provider.rbi +4 -2
- data/rbi/workos/pkce_not_supported_oauth_error_body.rbi +30 -0
- data/rbi/workos/platform_teams.rbi +2 -2
- data/rbi/workos/policy_denied_error_body.rbi +36 -0
- data/rbi/workos/radar.rbi +4 -4
- data/rbi/workos/radar_challenge_error_body.rbi +30 -0
- data/rbi/workos/radar_sign_up_challenge_error_body.rbi +30 -0
- data/rbi/workos/radar_sms_sign_in_challenge_error_body.rbi +30 -0
- data/rbi/workos/radar_standalone_update_radar_list_request.rbi +1 -16
- data/rbi/workos/rate_limit_exceeded_error_body_with_retry_after.rbi +36 -0
- data/rbi/workos/remove_role.rbi +1 -34
- data/rbi/workos/replace_group_role_assignment_entry.rbi +1 -34
- data/rbi/workos/role_deleted_data.rbi +1 -46
- data/rbi/workos/role_updated_data.rbi +1 -46
- data/rbi/workos/send_email_change.rbi +6 -0
- data/rbi/workos/send_verification_email.rbi +24 -0
- data/rbi/workos/send_verification_email_response.rbi +1 -16
- data/rbi/workos/session_created_data_impersonator.rbi +1 -22
- data/rbi/workos/session_revoked_data_impersonator.rbi +1 -22
- data/rbi/workos/sign_up_not_allowed_oauth_error_body.rbi +30 -0
- data/rbi/workos/slim_role.rbi +1 -16
- data/rbi/workos/slow_down_oauth_error_body.rbi +30 -0
- data/rbi/workos/sms_challenge_quota_reached_error_body.rbi +30 -0
- data/rbi/workos/sms_challenge_rate_limited_error_body.rbi +30 -0
- data/rbi/workos/sso.rbi +19 -18
- data/rbi/workos/sso_required_oauth_error_body_with_connection_ids_list_email.rbi +48 -0
- data/rbi/workos/sso_token_response_oauth_token.rbi +1 -40
- data/rbi/workos/sub_resource_scoped_role_not_allowed_error_body_with_role_slug.rbi +36 -0
- data/rbi/workos/token_too_big_oauth_error_body.rbi +30 -0
- data/rbi/workos/too_many_failed_verification_attempts_error_body_with_retry_after.rbi +36 -0
- data/rbi/workos/too_many_requests_oauth_error_body.rbi +30 -0
- data/rbi/workos/unauthorized_client_oauth_error_body.rbi +30 -0
- data/rbi/workos/unauthorized_error_body.rbi +24 -0
- data/rbi/workos/update_audit_logs_retention_with_retention_period.rbi +24 -0
- data/rbi/workos/update_audit_logs_retention_with_retention_period_in_days.rbi +24 -0
- data/rbi/workos/update_group.rbi +1 -22
- data/rbi/workos/update_oauth_application.rbi +6 -0
- data/rbi/workos/update_organization_role.rbi +1 -22
- data/rbi/workos/update_role.rbi +1 -22
- data/rbi/workos/update_user_organization_membership_with_role_slug.rbi +24 -0
- data/rbi/workos/update_user_organization_membership_with_role_slugs.rbi +24 -0
- data/rbi/workos/user.rbi +1 -94
- data/rbi/workos/user_api_key_owner.rbi +1 -28
- data/rbi/workos/user_api_key_revoked_data_owner.rbi +1 -28
- data/rbi/workos/user_api_key_updated_data_owner.rbi +1 -28
- data/rbi/workos/user_api_key_with_value_owner.rbi +1 -28
- data/rbi/workos/user_connected_account_import_error_body.rbi +30 -0
- data/rbi/workos/user_consent_options_not_supported_error_body.rbi +30 -0
- data/rbi/workos/user_creation_error_error_body_with_errors.rbi +36 -0
- data/rbi/workos/user_management.rbi +77 -61
- data/rbi/workos/user_mismatch_error_body.rbi +30 -0
- data/rbi/workos/user_role_assignment_resource.rbi +1 -28
- data/rbi/workos/user_role_assignment_source_group.rbi +1 -22
- data/rbi/workos/user_sessions_impersonator.rbi +1 -22
- data/rbi/workos/vault.rbi +11 -11
- data/rbi/workos/verification_id_required_error_body.rbi +30 -0
- data/rbi/workos/verify_email_address.rbi +1 -16
- data/rbi/workos/verify_email_response.rbi +1 -16
- data/rbi/workos/version_list_response.rbi +30 -0
- data/rbi/workos/waitlist_list_response.rbi +36 -0
- data/rbi/workos/waitlist_list_response_list_metadata.rbi +9 -0
- data/rbi/workos/webhooks.rbi +4 -4
- data/rbi/workos/widget_session_token_response.rbi +1 -16
- data/rbi/workos/widgets.rbi +1 -1
- data/test/workos/test_agents_model_round_trip.rb +11 -0
- data/test/workos/test_api_keys_model_round_trip.rb +14 -0
- data/test/workos/test_authorization.rb +8 -0
- data/test/workos/test_authorization_model_round_trip.rb +23 -0
- data/test/workos/test_base_client.rb +4 -3
- data/test/workos/test_connect_model_round_trip.rb +3 -1
- data/test/workos/test_directory_sync.rb +32 -0
- data/test/workos/test_directory_sync_model_round_trip.rb +11 -11
- data/test/workos/test_feature_flags_model_round_trip.rb +107 -0
- data/test/workos/test_groups.rb +8 -0
- data/test/workos/test_groups_model_round_trip.rb +11 -0
- data/test/workos/test_organizations_model_round_trip.rb +111 -0
- data/test/workos/test_pipes.rb +8 -0
- data/test/workos/test_pipes_model_round_trip.rb +101 -201
- data/test/workos/test_session.rb +46 -1
- data/test/workos/test_shared_model_round_trip.rb +2046 -425
- data/test/workos/test_sso_model_round_trip.rb +60 -0
- data/test/workos/test_user_management_model_round_trip.rb +315 -12
- data/test/workos/test_vault_model_round_trip.rb +30 -0
- metadata +380 -26
- data/lib/workos/pipes/add_data_integrations_get_data_integration_authorize_url_request.rb +0 -37
- data/lib/workos/pipes/connected_account_write_response.rb +0 -73
- data/lib/workos/pipes/data_integrations_upsert_api_key_request_2.rb +0 -37
- data/lib/workos/pipes/data_integrations_upsert_client_credentials_request_2.rb +0 -43
- data/lib/workos/pipes/reauthorize_data_integrations_get_data_integration_authorize_url_request.rb +0 -40
- data/lib/workos/pipes/reauthorize_data_integrations_upsert_api_key_request.rb +0 -40
- data/lib/workos/pipes/reauthorize_data_integrations_upsert_client_credentials_request.rb +0 -46
- data/lib/workos/types/add_data_integrations_get_data_integration_authorize_url_request_connection_owner.rb +0 -13
- data/lib/workos/types/data_integrations_upsert_api_key_request_2_connection_owner.rb +0 -9
- data/lib/workos/types/data_integrations_upsert_client_credentials_request_2_connection_owner.rb +0 -9
- data/lib/workos/types/reauthorize_data_integrations_get_data_integration_authorize_url_request_connection_owner.rb +0 -9
- data/lib/workos/types/reauthorize_data_integrations_upsert_api_key_request_connection_owner.rb +0 -9
- data/lib/workos/types/reauthorize_data_integrations_upsert_client_credentials_request_connection_owner.rb +0 -9
- data/rbi/workos/add_data_integrations_get_data_integration_authorize_url_request.rbi +0 -60
- data/rbi/workos/connected_account_write_response.rbi +0 -132
- data/rbi/workos/data_integrations_upsert_api_key_request_2.rbi +0 -60
- data/rbi/workos/data_integrations_upsert_client_credentials_request_2.rbi +0 -72
- data/rbi/workos/reauthorize_data_integrations_get_data_integration_authorize_url_request.rbi +0 -66
- data/rbi/workos/reauthorize_data_integrations_upsert_api_key_request.rbi +0 -66
- data/rbi/workos/reauthorize_data_integrations_upsert_client_credentials_request.rbi +0 -78
data/lib/workos/pipes.rb
CHANGED
|
@@ -108,6 +108,35 @@ module WorkOS
|
|
|
108
108
|
result
|
|
109
109
|
end
|
|
110
110
|
|
|
111
|
+
# Finish connection
|
|
112
|
+
# @param connect_code [String] The `connect_code` WorkOS added to `return_to` when the user finished authorizing. It can be used once and expires 90 seconds after the redirect.
|
|
113
|
+
# @param code_verifier [String] The code verifier `code_challenge` was derived from: 43 to 128 characters from `A-Z`, `a-z`, `0-9`, `-`, `.`, `_` and `~`. A wrong verifier uses up the `connect_code`, and the user has to connect again.
|
|
114
|
+
# @param state [String, nil] The `state` WorkOS added to `return_to` alongside `connect_code`. Optional; it is only used to correlate the request in logs.
|
|
115
|
+
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
116
|
+
# @return [WorkOS::DataIntegrationFinishConnectionResponse]
|
|
117
|
+
def finish_connection(
|
|
118
|
+
connect_code:,
|
|
119
|
+
code_verifier:,
|
|
120
|
+
state: nil,
|
|
121
|
+
request_options: {}
|
|
122
|
+
)
|
|
123
|
+
body = {
|
|
124
|
+
"connect_code" => connect_code,
|
|
125
|
+
"code_verifier" => code_verifier,
|
|
126
|
+
"state" => state
|
|
127
|
+
}.compact
|
|
128
|
+
response = @client.request(
|
|
129
|
+
method: :post,
|
|
130
|
+
path: "/data-integrations/finish",
|
|
131
|
+
auth: true,
|
|
132
|
+
body: body,
|
|
133
|
+
request_options: request_options
|
|
134
|
+
)
|
|
135
|
+
result = WorkOS::DataIntegrationFinishConnectionResponse.new(response.body)
|
|
136
|
+
result.last_response = WorkOS::Types::ApiResponse.new(http_status: response.code.to_i, http_headers: response.each_header.to_h, request_id: response["x-request-id"])
|
|
137
|
+
result
|
|
138
|
+
end
|
|
139
|
+
|
|
111
140
|
# Get a data integration
|
|
112
141
|
# @param slug [String] The slug identifier of the data integration.
|
|
113
142
|
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
@@ -192,9 +221,9 @@ module WorkOS
|
|
|
192
221
|
# @param organization_id [String, nil] An [Organization](https://workos.com/docs/reference/organization) identifier. Optional parameter to scope the connection to a specific organization. Required when `connection_owner` is `organization`.
|
|
193
222
|
# @param connection_owner [WorkOS::Types::DataIntegrationsCreateApiKeyConnectionRequestConnectionOwner, nil] Whose connection to create or rotate. `user` (the default) addresses the connection owned by `user_id`. `organization` addresses the connection shared by every member of `organization_id`; `user_id` then identifies the member performing the request and must be an active member of the organization.
|
|
194
223
|
# @param secret [String] The API key secret to store for this integration.
|
|
195
|
-
# @param connection_intent [String] Must be `add`: this endpoint only creates another connection. The first connection for an owner shape fills the compatibility slot; later connections are standard.
|
|
224
|
+
# @param connection_intent [String] Must be `add`: this endpoint only creates another connection. The first connection for an owner shape fills the compatibility slot; later connections are standard.
|
|
196
225
|
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
197
|
-
# @return [WorkOS::
|
|
226
|
+
# @return [WorkOS::ConnectedAccount]
|
|
198
227
|
def create_data_integration_api_key(
|
|
199
228
|
slug:,
|
|
200
229
|
user_id:,
|
|
@@ -222,7 +251,7 @@ module WorkOS
|
|
|
222
251
|
body: body,
|
|
223
252
|
request_options: request_options
|
|
224
253
|
)
|
|
225
|
-
result = WorkOS::
|
|
254
|
+
result = WorkOS::ConnectedAccount.new(response.body)
|
|
226
255
|
result.last_response = WorkOS::Types::ApiResponse.new(http_status: response.code.to_i, http_headers: response.each_header.to_h, request_id: response["x-request-id"])
|
|
227
256
|
result
|
|
228
257
|
end
|
|
@@ -235,10 +264,10 @@ module WorkOS
|
|
|
235
264
|
# @param organization_id [String, nil] An [Organization](https://workos.com/docs/reference/organization) identifier. Optional parameter to scope the connection to a specific organization. Required when `connection_owner` is `organization`.
|
|
236
265
|
# @param connection_owner [WorkOS::Types::DataIntegrationsUpsertApiKeyRequestConnectionOwner, nil] Whose connection to create or rotate. `user` (the default) addresses the connection owned by `user_id`. `organization` addresses the connection shared by every member of `organization_id`; `user_id` then identifies the member performing the request and must be an active member of the organization.
|
|
237
266
|
# @param secret [String] The API key secret to store for this integration.
|
|
238
|
-
# @param connection_intent [String, nil]
|
|
239
|
-
# @param connected_account_id [String, nil] The exact connected account to reauthorize. Required with `connection_intent: reauthorize
|
|
267
|
+
# @param connection_intent [String, nil] Send `reauthorize` with `connected_account_id` to reauthorize one exact connection. Omit it to use the compatibility connection; creating another connection lives on the POST route.
|
|
268
|
+
# @param connected_account_id [String, nil] The exact connected account to reauthorize. Required with `connection_intent: reauthorize`; it may also be sent on its own to reauthorize that connection.
|
|
240
269
|
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
241
|
-
# @return [WorkOS::
|
|
270
|
+
# @return [WorkOS::ConnectedAccount]
|
|
242
271
|
def update_data_integration_api_key(
|
|
243
272
|
slug:,
|
|
244
273
|
user_id:,
|
|
@@ -268,7 +297,7 @@ module WorkOS
|
|
|
268
297
|
body: body,
|
|
269
298
|
request_options: request_options
|
|
270
299
|
)
|
|
271
|
-
result = WorkOS::
|
|
300
|
+
result = WorkOS::ConnectedAccount.new(response.body)
|
|
272
301
|
result.last_response = WorkOS::Types::ApiResponse.new(http_status: response.code.to_i, http_headers: response.each_header.to_h, request_id: response["x-request-id"])
|
|
273
302
|
result
|
|
274
303
|
end
|
|
@@ -279,10 +308,12 @@ module WorkOS
|
|
|
279
308
|
# @param user_id [String] The ID of the user to authorize. When `connection_owner` is `organization`, this is the user authorizing on behalf of the organization; they must be an active member of the organization and do not become the owner of the resulting connected account.
|
|
280
309
|
# @param organization_id [String, nil] An organization ID to scope the authorization to a specific organization. Required when `connection_owner` is `organization`.
|
|
281
310
|
# @param connection_owner [WorkOS::Types::DataIntegrationsGetDataIntegrationAuthorizeUrlRequestConnectionOwner, nil] Who will own the connected account. `user` (the default) connects the user's own account. `organization` connects the organization's shared account and requires `organization_id`.
|
|
282
|
-
# @param return_to [String, nil] The URL to redirect the user to after authorization.
|
|
311
|
+
# @param return_to [String, nil] The URL to redirect the user to after authorization. Required with `code_challenge`, and must then exactly match a redirect URI registered on one of the environment's applications. Loopback URLs match on any port; wildcard redirect URIs are not honored, and a `return_to` with a query string or fragment never matches.
|
|
312
|
+
# @param code_challenge [String, nil] A PKCE-style code challenge: the base64url-encoded SHA-256 of a `code_verifier` your app keeps. When set, the connection isn't saved when the user finishes authorizing. Instead, the user is redirected to `return_to` with a `connect_code` and `state`, and your app must call [Finish connection](https://workos.com/docs/reference/pipes/connected-account/finish-connection) with the `connect_code` and `code_verifier` within 90 seconds to save it.
|
|
313
|
+
# @param code_challenge_method [String, nil] The method used to derive `code_challenge`. Only `S256` is supported, and it is the default. Requires `code_challenge`.
|
|
283
314
|
# @param config [Hash{String => String}, nil] Connect-time config values for the provider-declared `installation`-scope fields (e.g. a Zendesk `subdomain`), keyed by the config field. Only fields the provider declares may be supplied, and required fields must be provided unless already pinned on the integration.
|
|
284
|
-
# @param connection_intent [
|
|
285
|
-
# @param connected_account_id [String, nil] The exact connected account to reauthorize. Required with `connection_intent: reauthorize
|
|
315
|
+
# @param connection_intent [WorkOS::Types::DataIntegrationsGetDataIntegrationAuthorizeUrlRequestConnectionIntent, nil] Which connection the request targets. Omit it to use the compatibility connection. Send `add` to create another connection: the first connection for an owner shape fills the compatibility slot, and later connections are standard. Send `reauthorize` with `connected_account_id` to reauthorize one exact connection.
|
|
316
|
+
# @param connected_account_id [String, nil] The exact connected account to reauthorize. Required with `connection_intent: reauthorize` and not accepted otherwise.
|
|
286
317
|
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
287
318
|
# @return [WorkOS::DataIntegrationAuthorizeUrlResponse]
|
|
288
319
|
def authorize_data_integration(
|
|
@@ -292,6 +323,8 @@ module WorkOS
|
|
|
292
323
|
organization_id: nil,
|
|
293
324
|
connection_owner: nil,
|
|
294
325
|
return_to: nil,
|
|
326
|
+
code_challenge: nil,
|
|
327
|
+
code_challenge_method: nil,
|
|
295
328
|
config: nil,
|
|
296
329
|
connection_intent: nil,
|
|
297
330
|
connected_account_id: nil,
|
|
@@ -302,6 +335,8 @@ module WorkOS
|
|
|
302
335
|
"organization_id" => organization_id,
|
|
303
336
|
"connection_owner" => connection_owner,
|
|
304
337
|
"return_to" => return_to,
|
|
338
|
+
"code_challenge" => code_challenge,
|
|
339
|
+
"code_challenge_method" => code_challenge_method,
|
|
305
340
|
"config" => config,
|
|
306
341
|
"connection_intent" => connection_intent,
|
|
307
342
|
"connected_account_id" => connected_account_id
|
|
@@ -329,9 +364,9 @@ module WorkOS
|
|
|
329
364
|
# @param client_id [String] The OAuth client ID to store for this integration.
|
|
330
365
|
# @param client_secret [String] The OAuth client secret to store for this integration.
|
|
331
366
|
# @param config [Hash{String => String}, nil] Provider-specific configuration values collected for this installation, keyed by the provider's config field descriptors.
|
|
332
|
-
# @param connection_intent [String] Must be `add`: this endpoint only creates another connection. The first connection for an owner shape fills the compatibility slot; later connections are standard.
|
|
367
|
+
# @param connection_intent [String] Must be `add`: this endpoint only creates another connection. The first connection for an owner shape fills the compatibility slot; later connections are standard.
|
|
333
368
|
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
334
|
-
# @return [WorkOS::
|
|
369
|
+
# @return [WorkOS::ConnectedAccount]
|
|
335
370
|
def create_data_integration_client_credential(
|
|
336
371
|
slug:,
|
|
337
372
|
user_id:,
|
|
@@ -363,7 +398,7 @@ module WorkOS
|
|
|
363
398
|
body: body,
|
|
364
399
|
request_options: request_options
|
|
365
400
|
)
|
|
366
|
-
result = WorkOS::
|
|
401
|
+
result = WorkOS::ConnectedAccount.new(response.body)
|
|
367
402
|
result.last_response = WorkOS::Types::ApiResponse.new(http_status: response.code.to_i, http_headers: response.each_header.to_h, request_id: response["x-request-id"])
|
|
368
403
|
result
|
|
369
404
|
end
|
|
@@ -378,10 +413,10 @@ module WorkOS
|
|
|
378
413
|
# @param client_id [String] The OAuth client ID to store for this integration.
|
|
379
414
|
# @param client_secret [String] The OAuth client secret to store for this integration.
|
|
380
415
|
# @param config [Hash{String => String}, nil] Provider-specific configuration values collected for this installation, keyed by the provider's config field descriptors.
|
|
381
|
-
# @param connection_intent [String, nil]
|
|
382
|
-
# @param connected_account_id [String, nil] The exact connected account to reauthorize. Required with `connection_intent: reauthorize
|
|
416
|
+
# @param connection_intent [String, nil] Send `reauthorize` with `connected_account_id` to reauthorize one exact connection. Omit it to use the compatibility connection; creating another connection lives on the POST route.
|
|
417
|
+
# @param connected_account_id [String, nil] The exact connected account to reauthorize. Required with `connection_intent: reauthorize`; it may also be sent on its own to reauthorize that connection.
|
|
383
418
|
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
384
|
-
# @return [WorkOS::
|
|
419
|
+
# @return [WorkOS::ConnectedAccount]
|
|
385
420
|
def update_data_integration_client_credentials(
|
|
386
421
|
slug:,
|
|
387
422
|
user_id:,
|
|
@@ -415,7 +450,7 @@ module WorkOS
|
|
|
415
450
|
body: body,
|
|
416
451
|
request_options: request_options
|
|
417
452
|
)
|
|
418
|
-
result = WorkOS::
|
|
453
|
+
result = WorkOS::ConnectedAccount.new(response.body)
|
|
419
454
|
result.last_response = WorkOS::Types::ApiResponse.new(http_status: response.code.to_i, http_headers: response.each_header.to_h, request_id: response["x-request-id"])
|
|
420
455
|
result
|
|
421
456
|
end
|
|
@@ -605,36 +640,42 @@ module WorkOS
|
|
|
605
640
|
# @param slug [String] The slug identifier of the provider (e.g., `github`, `slack`, `notion`).
|
|
606
641
|
# @param account_display_name [String, nil] A mutable, non-unique connection label; null clears it. Not an account identifier.
|
|
607
642
|
# @param account_identifier [String, nil] A developer-attested account identifier; null clears it.
|
|
643
|
+
# @param config [Hash{String => String}, nil] Installation-scoped provider configuration for this connection, such as Salesforce salesforce_host. Imports apply supplied values over installation-scoped integration pins and inherit other config from the credential source. Credential-bearing imports must satisfy required configuration even when config is omitted or {}. On update, a supplied object replaces installation-scoped values; omitted config preserves the stored snapshot. Stored integration-scoped values remain bound to the OAuth client and cannot be overridden or replaced with current integration pins. Replacements must satisfy required configuration; {} and empty-string values clear installation-scoped values only when the result is valid. Provider defaults count toward completeness but are resolved at read time, not stored. Only tokenless needs_reauthorization placeholders may remain incomplete; attaching their first tokens validates configuration even when config is omitted. Unrelated updates do not revalidate unchanged configuration. Clearing salesforce_host falls back to login.salesforce.com, which may not work for sandbox or My Domain-only connections.
|
|
608
644
|
# @param access_token [String, nil] The OAuth access token for the connected account.
|
|
609
645
|
# @param refresh_token [String, nil] The OAuth refresh token for the connected account.
|
|
610
646
|
# @param expires_at [String, nil] The ISO-8601 timestamp when the access token expires. Required when `access_token` is provided for tokens that expire.
|
|
611
647
|
# @param scopes [Array<String>, nil] The OAuth scopes granted for this connection.
|
|
612
648
|
# @param state [WorkOS::Types::CreateOrganizationConnectedAccountState, nil] Explicitly set the state of the connected account. When omitted, the state is derived from the token combination provided.
|
|
613
649
|
# @param user_id [String] The [User](https://workos.com/docs/reference/authkit/user) identifier of the organization member on whose behalf the connected account is being imported or updated. The user must be an active member of the organization.
|
|
614
|
-
# @param
|
|
650
|
+
# @param metadata [Hash{String => Object}, nil] Provider token-response metadata to preserve during import, such as Salesforce instance_url. Only allowlisted, non-sensitive scalar fields from this provider are accepted, including nested fields. Provider refresh responses can update these values. Not accepted on update.
|
|
651
|
+
# @param connection_intent [String, nil] Set to `add` to create another connected account. Omit this field for permanent compatibility behavior.
|
|
615
652
|
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
616
|
-
# @return [WorkOS::
|
|
653
|
+
# @return [WorkOS::ConnectedAccount]
|
|
617
654
|
def create_organization_connected_account(
|
|
618
655
|
organization_id:,
|
|
619
656
|
slug:,
|
|
620
657
|
user_id:,
|
|
621
658
|
account_display_name: WorkOS::OMIT,
|
|
622
659
|
account_identifier: WorkOS::OMIT,
|
|
660
|
+
config: nil,
|
|
623
661
|
access_token: nil,
|
|
624
662
|
refresh_token: nil,
|
|
625
663
|
expires_at: nil,
|
|
626
664
|
scopes: nil,
|
|
627
665
|
state: nil,
|
|
666
|
+
metadata: nil,
|
|
628
667
|
connection_intent: nil,
|
|
629
668
|
request_options: {}
|
|
630
669
|
)
|
|
631
670
|
body = {
|
|
671
|
+
"config" => config,
|
|
632
672
|
"access_token" => access_token,
|
|
633
673
|
"refresh_token" => refresh_token,
|
|
634
674
|
"expires_at" => expires_at,
|
|
635
675
|
"scopes" => scopes,
|
|
636
676
|
"state" => state,
|
|
637
677
|
"user_id" => user_id,
|
|
678
|
+
"metadata" => metadata,
|
|
638
679
|
"connection_intent" => connection_intent
|
|
639
680
|
}.compact
|
|
640
681
|
body["account_display_name"] = account_display_name unless account_display_name.equal?(WorkOS::OMIT)
|
|
@@ -646,7 +687,7 @@ module WorkOS
|
|
|
646
687
|
body: body,
|
|
647
688
|
request_options: request_options
|
|
648
689
|
)
|
|
649
|
-
result = WorkOS::
|
|
690
|
+
result = WorkOS::ConnectedAccount.new(response.body)
|
|
650
691
|
result.last_response = WorkOS::Types::ApiResponse.new(http_status: response.code.to_i, http_headers: response.each_header.to_h, request_id: response["x-request-id"])
|
|
651
692
|
result
|
|
652
693
|
end
|
|
@@ -656,6 +697,7 @@ module WorkOS
|
|
|
656
697
|
# @param slug [String] The slug identifier of the provider (e.g., `github`, `slack`, `notion`).
|
|
657
698
|
# @param account_display_name [String, nil] A mutable, non-unique connection label; null clears it. Not an account identifier.
|
|
658
699
|
# @param account_identifier [String, nil] A developer-attested account identifier; null clears it.
|
|
700
|
+
# @param config [Hash{String => String}, nil] Installation-scoped provider configuration for this connection, such as Salesforce salesforce_host. Imports apply supplied values over installation-scoped integration pins and inherit other config from the credential source. Credential-bearing imports must satisfy required configuration even when config is omitted or {}. On update, a supplied object replaces installation-scoped values; omitted config preserves the stored snapshot. Stored integration-scoped values remain bound to the OAuth client and cannot be overridden or replaced with current integration pins. Replacements must satisfy required configuration; {} and empty-string values clear installation-scoped values only when the result is valid. Provider defaults count toward completeness but are resolved at read time, not stored. Only tokenless needs_reauthorization placeholders may remain incomplete; attaching their first tokens validates configuration even when config is omitted. Unrelated updates do not revalidate unchanged configuration. Clearing salesforce_host falls back to login.salesforce.com, which may not work for sandbox or My Domain-only connections.
|
|
659
701
|
# @param access_token [String, nil] The OAuth access token for the connected account.
|
|
660
702
|
# @param refresh_token [String, nil] The OAuth refresh token for the connected account.
|
|
661
703
|
# @param expires_at [String, nil] The ISO-8601 timestamp when the access token expires. Required when `access_token` is provided for tokens that expire.
|
|
@@ -666,13 +708,14 @@ module WorkOS
|
|
|
666
708
|
# @param connected_account_id [String, nil] A [connected account](https://workos.com/docs/reference/pipes/connected-account) identifier. Use this to select the connection to update.
|
|
667
709
|
# @param connection_intent [String, nil] Set to `reauthorize` with `connected_account_id` to update one exact connection. The intent may be omitted when supplying an ID. Omit both for permanent compatibility behavior.
|
|
668
710
|
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
669
|
-
# @return [WorkOS::
|
|
711
|
+
# @return [WorkOS::ConnectedAccount]
|
|
670
712
|
def update_organization_connected_account(
|
|
671
713
|
organization_id:,
|
|
672
714
|
slug:,
|
|
673
715
|
user_id:,
|
|
674
716
|
account_display_name: WorkOS::OMIT,
|
|
675
717
|
account_identifier: WorkOS::OMIT,
|
|
718
|
+
config: nil,
|
|
676
719
|
access_token: nil,
|
|
677
720
|
refresh_token: nil,
|
|
678
721
|
expires_at: nil,
|
|
@@ -689,6 +732,7 @@ module WorkOS
|
|
|
689
732
|
"connection_intent" => connection_intent
|
|
690
733
|
}.compact
|
|
691
734
|
body = {
|
|
735
|
+
"config" => config,
|
|
692
736
|
"access_token" => access_token,
|
|
693
737
|
"refresh_token" => refresh_token,
|
|
694
738
|
"expires_at" => expires_at,
|
|
@@ -706,7 +750,7 @@ module WorkOS
|
|
|
706
750
|
body: body,
|
|
707
751
|
request_options: request_options
|
|
708
752
|
)
|
|
709
|
-
result = WorkOS::
|
|
753
|
+
result = WorkOS::ConnectedAccount.new(response.body)
|
|
710
754
|
result.last_response = WorkOS::Types::ApiResponse.new(http_status: response.code.to_i, http_headers: response.each_header.to_h, request_id: response["x-request-id"])
|
|
711
755
|
result
|
|
712
756
|
end
|
|
@@ -802,25 +846,29 @@ module WorkOS
|
|
|
802
846
|
# @param slug [String] The slug identifier of the provider (e.g., `github`, `slack`, `notion`).
|
|
803
847
|
# @param account_display_name [String, nil] A mutable, non-unique connection label; null clears it. Not an account identifier.
|
|
804
848
|
# @param account_identifier [String, nil] A developer-attested account identifier; null clears it.
|
|
849
|
+
# @param config [Hash{String => String}, nil] Installation-scoped provider configuration for this connection, such as Salesforce salesforce_host. Imports apply supplied values over installation-scoped integration pins and inherit other config from the credential source. Credential-bearing imports must satisfy required configuration even when config is omitted or {}. On update, a supplied object replaces installation-scoped values; omitted config preserves the stored snapshot. Stored integration-scoped values remain bound to the OAuth client and cannot be overridden or replaced with current integration pins. Replacements must satisfy required configuration; {} and empty-string values clear installation-scoped values only when the result is valid. Provider defaults count toward completeness but are resolved at read time, not stored. Only tokenless needs_reauthorization placeholders may remain incomplete; attaching their first tokens validates configuration even when config is omitted. Unrelated updates do not revalidate unchanged configuration. Clearing salesforce_host falls back to login.salesforce.com, which may not work for sandbox or My Domain-only connections.
|
|
805
850
|
# @param access_token [String, nil] The OAuth access token for the connected account.
|
|
806
851
|
# @param refresh_token [String, nil] The OAuth refresh token for the connected account.
|
|
807
852
|
# @param expires_at [String, nil] The ISO-8601 timestamp when the access token expires. Required when `access_token` is provided for tokens that expire.
|
|
808
853
|
# @param scopes [Array<String>, nil] The OAuth scopes granted for this connection.
|
|
809
854
|
# @param state [WorkOS::Types::CreateConnectedAccountState, nil] Explicitly set the state of the connected account. When omitted, the state is derived from the token combination provided.
|
|
810
|
-
# @param
|
|
855
|
+
# @param metadata [Hash{String => Object}, nil] Provider token-response metadata to preserve during import, such as Salesforce instance_url. Only allowlisted, non-sensitive scalar fields from this provider are accepted, including nested fields. Provider refresh responses can update these values. Not accepted on update.
|
|
856
|
+
# @param connection_intent [String, nil] Set to `add` to create another connected account. Omit this field for permanent compatibility behavior.
|
|
811
857
|
# @param organization_id [String, nil] An [Organization](https://workos.com/docs/reference/organization) identifier. Optional parameter if the connection is scoped to an organization.
|
|
812
858
|
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
813
|
-
# @return [WorkOS::
|
|
859
|
+
# @return [WorkOS::ConnectedAccount]
|
|
814
860
|
def create_user_connected_account(
|
|
815
861
|
user_id:,
|
|
816
862
|
slug:,
|
|
817
863
|
account_display_name: WorkOS::OMIT,
|
|
818
864
|
account_identifier: WorkOS::OMIT,
|
|
865
|
+
config: nil,
|
|
819
866
|
access_token: nil,
|
|
820
867
|
refresh_token: nil,
|
|
821
868
|
expires_at: nil,
|
|
822
869
|
scopes: nil,
|
|
823
870
|
state: nil,
|
|
871
|
+
metadata: nil,
|
|
824
872
|
connection_intent: nil,
|
|
825
873
|
organization_id: nil,
|
|
826
874
|
request_options: {}
|
|
@@ -829,11 +877,13 @@ module WorkOS
|
|
|
829
877
|
"organization_id" => organization_id
|
|
830
878
|
}.compact
|
|
831
879
|
body = {
|
|
880
|
+
"config" => config,
|
|
832
881
|
"access_token" => access_token,
|
|
833
882
|
"refresh_token" => refresh_token,
|
|
834
883
|
"expires_at" => expires_at,
|
|
835
884
|
"scopes" => scopes,
|
|
836
885
|
"state" => state,
|
|
886
|
+
"metadata" => metadata,
|
|
837
887
|
"connection_intent" => connection_intent
|
|
838
888
|
}.compact
|
|
839
889
|
body["account_display_name"] = account_display_name unless account_display_name.equal?(WorkOS::OMIT)
|
|
@@ -846,7 +896,7 @@ module WorkOS
|
|
|
846
896
|
body: body,
|
|
847
897
|
request_options: request_options
|
|
848
898
|
)
|
|
849
|
-
result = WorkOS::
|
|
899
|
+
result = WorkOS::ConnectedAccount.new(response.body)
|
|
850
900
|
result.last_response = WorkOS::Types::ApiResponse.new(http_status: response.code.to_i, http_headers: response.each_header.to_h, request_id: response["x-request-id"])
|
|
851
901
|
result
|
|
852
902
|
end
|
|
@@ -856,6 +906,7 @@ module WorkOS
|
|
|
856
906
|
# @param slug [String] The slug identifier of the provider (e.g., `github`, `slack`, `notion`).
|
|
857
907
|
# @param account_display_name [String, nil] A mutable, non-unique connection label; null clears it. Not an account identifier.
|
|
858
908
|
# @param account_identifier [String, nil] A developer-attested account identifier; null clears it.
|
|
909
|
+
# @param config [Hash{String => String}, nil] Installation-scoped provider configuration for this connection, such as Salesforce salesforce_host. Imports apply supplied values over installation-scoped integration pins and inherit other config from the credential source. Credential-bearing imports must satisfy required configuration even when config is omitted or {}. On update, a supplied object replaces installation-scoped values; omitted config preserves the stored snapshot. Stored integration-scoped values remain bound to the OAuth client and cannot be overridden or replaced with current integration pins. Replacements must satisfy required configuration; {} and empty-string values clear installation-scoped values only when the result is valid. Provider defaults count toward completeness but are resolved at read time, not stored. Only tokenless needs_reauthorization placeholders may remain incomplete; attaching their first tokens validates configuration even when config is omitted. Unrelated updates do not revalidate unchanged configuration. Clearing salesforce_host falls back to login.salesforce.com, which may not work for sandbox or My Domain-only connections.
|
|
859
910
|
# @param access_token [String, nil] The OAuth access token for the connected account.
|
|
860
911
|
# @param refresh_token [String, nil] The OAuth refresh token for the connected account.
|
|
861
912
|
# @param expires_at [String, nil] The ISO-8601 timestamp when the access token expires. Required when `access_token` is provided for tokens that expire.
|
|
@@ -866,12 +917,13 @@ module WorkOS
|
|
|
866
917
|
# @param connected_account_id [String, nil] A [connected account](https://workos.com/docs/reference/pipes/connected-account) identifier. Use this to select the connection to update.
|
|
867
918
|
# @param connection_intent [String, nil] Set to `reauthorize` with `connected_account_id` to update one exact connection. The intent may be omitted when supplying an ID. Omit both for permanent compatibility behavior.
|
|
868
919
|
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
869
|
-
# @return [WorkOS::
|
|
920
|
+
# @return [WorkOS::ConnectedAccount]
|
|
870
921
|
def update_user_connected_account(
|
|
871
922
|
user_id:,
|
|
872
923
|
slug:,
|
|
873
924
|
account_display_name: WorkOS::OMIT,
|
|
874
925
|
account_identifier: WorkOS::OMIT,
|
|
926
|
+
config: nil,
|
|
875
927
|
access_token: nil,
|
|
876
928
|
refresh_token: nil,
|
|
877
929
|
expires_at: nil,
|
|
@@ -890,6 +942,7 @@ module WorkOS
|
|
|
890
942
|
"connection_intent" => connection_intent
|
|
891
943
|
}.compact
|
|
892
944
|
body = {
|
|
945
|
+
"config" => config,
|
|
893
946
|
"access_token" => access_token,
|
|
894
947
|
"refresh_token" => refresh_token,
|
|
895
948
|
"expires_at" => expires_at,
|
|
@@ -906,7 +959,7 @@ module WorkOS
|
|
|
906
959
|
body: body,
|
|
907
960
|
request_options: request_options
|
|
908
961
|
)
|
|
909
|
-
result = WorkOS::
|
|
962
|
+
result = WorkOS::ConnectedAccount.new(response.body)
|
|
910
963
|
result.last_response = WorkOS::Types::ApiResponse.new(http_status: response.code.to_i, http_headers: response.each_header.to_h, request_id: response["x-request-id"])
|
|
911
964
|
result
|
|
912
965
|
end
|
|
@@ -12,16 +12,22 @@ module WorkOS
|
|
|
12
12
|
|
|
13
13
|
# List providers for an organization
|
|
14
14
|
# @param organization_id [String] An [Organization](https://workos.com/docs/reference/organization) identifier to list provider configurations for.
|
|
15
|
+
# @param ownership [WorkOS::Types::PipesProviderOwnership, nil] Select the provider configuration for `user` connections or `organization` shared connections. Defaults to `user`; never falls back to the other ownership.
|
|
15
16
|
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
16
17
|
# @return [WorkOS::DataIntegrationConfigurationListResponse]
|
|
17
18
|
def list_organization_data_integration_configurations(
|
|
18
19
|
organization_id:,
|
|
20
|
+
ownership: "user",
|
|
19
21
|
request_options: {}
|
|
20
22
|
)
|
|
23
|
+
params = {
|
|
24
|
+
"ownership" => ownership
|
|
25
|
+
}.compact
|
|
21
26
|
response = @client.request(
|
|
22
27
|
method: :get,
|
|
23
28
|
path: "/organizations/#{WorkOS::Util.encode_path(organization_id)}/data_integration_configurations",
|
|
24
29
|
auth: true,
|
|
30
|
+
params: params,
|
|
25
31
|
request_options: request_options
|
|
26
32
|
)
|
|
27
33
|
result = WorkOS::DataIntegrationConfigurationListResponse.new(response.body)
|
|
@@ -37,6 +43,7 @@ module WorkOS
|
|
|
37
43
|
# @param client_id [String, nil] The OAuth client ID of the organization's own application. Must be provided together with `client_secret`, and only for providers whose credentials are supplied by the organization.
|
|
38
44
|
# @param client_secret [String, nil] The OAuth client secret of the organization's own application. Must be provided together with `client_id`.
|
|
39
45
|
# @param config [Hash{String => String}, nil] Provider-specific config values to set for the organization, keyed by config field. Only fields the provider declares are accepted, and each value must match that field's pattern. Accepted only for providers whose credentials are organization-managed; for shared or custom credential providers, config belongs on the integration itself (via the data-integrations API) and supplying it here is rejected.
|
|
46
|
+
# @param ownership [WorkOS::Types::PipesProviderOwnership, nil] Select the provider configuration for `user` connections or `organization` shared connections. Defaults to `user`; never falls back to the other ownership.
|
|
40
47
|
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
41
48
|
# @return [WorkOS::DataIntegrationConfigurationResponse]
|
|
42
49
|
def update_organization_data_integration_configuration(
|
|
@@ -47,8 +54,12 @@ module WorkOS
|
|
|
47
54
|
client_id: nil,
|
|
48
55
|
client_secret: nil,
|
|
49
56
|
config: nil,
|
|
57
|
+
ownership: "user",
|
|
50
58
|
request_options: {}
|
|
51
59
|
)
|
|
60
|
+
params = {
|
|
61
|
+
"ownership" => ownership
|
|
62
|
+
}.compact
|
|
52
63
|
body = {
|
|
53
64
|
"enabled" => enabled,
|
|
54
65
|
"client_id" => client_id,
|
|
@@ -60,6 +71,7 @@ module WorkOS
|
|
|
60
71
|
method: :put,
|
|
61
72
|
path: "/organizations/#{WorkOS::Util.encode_path(organization_id)}/data_integration_configurations/#{WorkOS::Util.encode_path(slug)}",
|
|
62
73
|
auth: true,
|
|
74
|
+
params: params,
|
|
63
75
|
body: body,
|
|
64
76
|
request_options: request_options
|
|
65
77
|
)
|
data/lib/workos/session.rb
CHANGED
|
@@ -64,6 +64,7 @@ module WorkOS
|
|
|
64
64
|
rescue JWT::DecodeError
|
|
65
65
|
return SessionManager::AuthError.new(authenticated: false, reason: SessionManager::INVALID_JWT)
|
|
66
66
|
end
|
|
67
|
+
return SessionManager::AuthError.new(authenticated: false, reason: SessionManager::INVALID_JWT) unless user_access_token?(decoded)
|
|
67
68
|
|
|
68
69
|
is_expired = decoded["exp"].nil? || decoded["exp"] < Time.now.to_i
|
|
69
70
|
|
|
@@ -163,5 +164,16 @@ module WorkOS
|
|
|
163
164
|
uri.query = URI.encode_www_form(params)
|
|
164
165
|
uri.to_s
|
|
165
166
|
end
|
|
167
|
+
|
|
168
|
+
private
|
|
169
|
+
|
|
170
|
+
# Other token types signed by the same environment key (agent and widget
|
|
171
|
+
# tokens) must not authenticate a session cookie.
|
|
172
|
+
def user_access_token?(claims)
|
|
173
|
+
claims["sid"].is_a?(String) &&
|
|
174
|
+
claims["auth_time"].is_a?(Numeric) &&
|
|
175
|
+
[nil, "user"].include?(claims["sub_profile"]) &&
|
|
176
|
+
claims["sub_type"].nil?
|
|
177
|
+
end
|
|
166
178
|
end
|
|
167
179
|
end
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
module WorkOS
|
|
6
|
+
class AccessDeniedOAuthErrorBody < WorkOS::Types::BaseModel
|
|
7
|
+
HASH_ATTRS = {
|
|
8
|
+
error: :error,
|
|
9
|
+
error_description: :error_description
|
|
10
|
+
}.freeze
|
|
11
|
+
|
|
12
|
+
attr_accessor \
|
|
13
|
+
:error,
|
|
14
|
+
:error_description
|
|
15
|
+
|
|
16
|
+
def initialize(json)
|
|
17
|
+
hash = self.class.normalize(json)
|
|
18
|
+
@error = hash[:error]
|
|
19
|
+
@error_description = hash[:error_description]
|
|
20
|
+
end
|
|
21
|
+
end
|
|
22
|
+
end
|
|
@@ -8,6 +8,7 @@ module WorkOS
|
|
|
8
8
|
object: :object,
|
|
9
9
|
id: :id,
|
|
10
10
|
agent_registration_id: :agent_registration_id,
|
|
11
|
+
organization_id: :organization_id,
|
|
11
12
|
completed_by_attempt_id: :completed_by_attempt_id,
|
|
12
13
|
claimed_by: :claimed_by,
|
|
13
14
|
completed_at: :completed_at,
|
|
@@ -19,6 +20,7 @@ module WorkOS
|
|
|
19
20
|
:object,
|
|
20
21
|
:id,
|
|
21
22
|
:agent_registration_id,
|
|
23
|
+
:organization_id,
|
|
22
24
|
:completed_by_attempt_id,
|
|
23
25
|
:claimed_by,
|
|
24
26
|
:completed_at,
|
|
@@ -30,6 +32,7 @@ module WorkOS
|
|
|
30
32
|
@object = hash[:object]
|
|
31
33
|
@id = hash[:id]
|
|
32
34
|
@agent_registration_id = hash[:agent_registration_id]
|
|
35
|
+
@organization_id = hash[:organization_id]
|
|
33
36
|
@completed_by_attempt_id = hash[:completed_by_attempt_id]
|
|
34
37
|
@claimed_by = hash[:claimed_by] ? WorkOS::AgentRegistrationClaimCompletedDataClaimedBy.new(hash[:claimed_by]) : nil
|
|
35
38
|
@completed_at = hash[:completed_at]
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
module WorkOS
|
|
6
|
+
class AlreadyClaimedErrorBody < WorkOS::Types::BaseModel
|
|
7
|
+
HASH_ATTRS = {
|
|
8
|
+
code: :code,
|
|
9
|
+
message: :message
|
|
10
|
+
}.freeze
|
|
11
|
+
|
|
12
|
+
attr_accessor \
|
|
13
|
+
:code,
|
|
14
|
+
:message
|
|
15
|
+
|
|
16
|
+
def initialize(json)
|
|
17
|
+
hash = self.class.normalize(json)
|
|
18
|
+
@code = hash[:code]
|
|
19
|
+
@message = hash[:message]
|
|
20
|
+
end
|
|
21
|
+
end
|
|
22
|
+
end
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
module WorkOS
|
|
6
|
+
class ApplicationConsentRequiredErrorBody < WorkOS::Types::BaseModel
|
|
7
|
+
HASH_ATTRS = {
|
|
8
|
+
code: :code,
|
|
9
|
+
message: :message
|
|
10
|
+
}.freeze
|
|
11
|
+
|
|
12
|
+
attr_accessor \
|
|
13
|
+
:code,
|
|
14
|
+
:message
|
|
15
|
+
|
|
16
|
+
def initialize(json)
|
|
17
|
+
hash = self.class.normalize(json)
|
|
18
|
+
@code = hash[:code]
|
|
19
|
+
@message = hash[:message]
|
|
20
|
+
end
|
|
21
|
+
end
|
|
22
|
+
end
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
module WorkOS
|
|
6
|
+
class AuthorizationPendingOAuthErrorBody < WorkOS::Types::BaseModel
|
|
7
|
+
HASH_ATTRS = {
|
|
8
|
+
error: :error,
|
|
9
|
+
error_description: :error_description
|
|
10
|
+
}.freeze
|
|
11
|
+
|
|
12
|
+
attr_accessor \
|
|
13
|
+
:error,
|
|
14
|
+
:error_description
|
|
15
|
+
|
|
16
|
+
def initialize(json)
|
|
17
|
+
hash = self.class.normalize(json)
|
|
18
|
+
@error = hash[:error]
|
|
19
|
+
@error_description = hash[:error_description]
|
|
20
|
+
end
|
|
21
|
+
end
|
|
22
|
+
end
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
module WorkOS
|
|
6
|
+
class AuthorizationUrlNotFoundErrorBody < WorkOS::Types::BaseModel
|
|
7
|
+
HASH_ATTRS = {
|
|
8
|
+
code: :code,
|
|
9
|
+
message: :message
|
|
10
|
+
}.freeze
|
|
11
|
+
|
|
12
|
+
attr_accessor \
|
|
13
|
+
:code,
|
|
14
|
+
:message
|
|
15
|
+
|
|
16
|
+
def initialize(json)
|
|
17
|
+
hash = self.class.normalize(json)
|
|
18
|
+
@code = hash[:code]
|
|
19
|
+
@message = hash[:message]
|
|
20
|
+
end
|
|
21
|
+
end
|
|
22
|
+
end
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
module WorkOS
|
|
6
|
+
class AuthorizationUrlRequestErrorBody < WorkOS::Types::BaseModel
|
|
7
|
+
HASH_ATTRS = {
|
|
8
|
+
code: :code,
|
|
9
|
+
message: :message
|
|
10
|
+
}.freeze
|
|
11
|
+
|
|
12
|
+
attr_accessor \
|
|
13
|
+
:code,
|
|
14
|
+
:message
|
|
15
|
+
|
|
16
|
+
def initialize(json)
|
|
17
|
+
hash = self.class.normalize(json)
|
|
18
|
+
@code = hash[:code]
|
|
19
|
+
@message = hash[:message]
|
|
20
|
+
end
|
|
21
|
+
end
|
|
22
|
+
end
|